mirror of
https://github.com/chibicitiberiu/rainmeter-studio.git
synced 2024-02-24 04:33:31 +00:00
WebParser: Tweaks
This commit is contained in:
parent
9e730bc7cf
commit
39c6c62abd
@ -725,18 +725,12 @@ PLUGIN_EXPORT void Reload(void* data, void* rm, double* maxValue)
|
|||||||
if (end == std::wstring::npos) break;
|
if (end == std::wstring::npos) break;
|
||||||
|
|
||||||
std::wstring var = L"[";
|
std::wstring var = L"[";
|
||||||
var += url.substr(si + 1, end - si);
|
var.append(url, si + 1, end - si);
|
||||||
|
|
||||||
const std::wstring result = RmReplaceVariables(rm, var.c_str());
|
const WCHAR* result = RmReplaceVariables(rm, var.c_str());
|
||||||
if (result != var)
|
const size_t resultLength = wcslen(result);
|
||||||
{
|
url.replace(start, end - start + 1, result, resultLength);
|
||||||
url.replace(start, end - start + 1, result);
|
start += resultLength;
|
||||||
start += result.length();
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
start = end;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
measure->url = url;
|
measure->url = url;
|
||||||
|
Loading…
Reference in New Issue
Block a user