mirror of
https://github.com/chibicitiberiu/rainmeter-studio.git
synced 2024-02-24 04:33:31 +00:00
Additional change for r852,r856. Improved reading the network statistics from Rainmeter.stats.
Some cosmetic changes.
This commit is contained in:
@ -744,6 +744,13 @@ int CConfigParser::ReadInt(LPCTSTR section, LPCTSTR key, int defValue)
|
||||
return (m_LastDefaultUsed) ? defValue : (int)ParseDouble(result, defValue, true);
|
||||
}
|
||||
|
||||
unsigned int CConfigParser::ReadUInt(LPCTSTR section, LPCTSTR key, unsigned int defValue)
|
||||
{
|
||||
const std::wstring& result = ReadString(section, key, L"");
|
||||
|
||||
return (m_LastDefaultUsed) ? defValue : (unsigned int)ParseDouble(result, defValue, true);
|
||||
}
|
||||
|
||||
// Works as ReadFloat except if the value is surrounded by parenthesis in which case it tries to evaluate the formula
|
||||
double CConfigParser::ReadFormula(LPCTSTR section, LPCTSTR key, double defValue)
|
||||
{
|
||||
@ -1056,7 +1063,7 @@ void CConfigParser::ReadIniFile(const std::vector<std::wstring>& iniFileMappings
|
||||
while (true)
|
||||
{
|
||||
items[0] = 0;
|
||||
DWORD res = GetPrivateProfileString(NULL, NULL, NULL, items, itemsSize, iniRead.c_str());
|
||||
DWORD res = GetPrivateProfileSectionNames(items, itemsSize, iniRead.c_str());
|
||||
if (res == 0) // File not found
|
||||
{
|
||||
delete [] items;
|
||||
|
Reference in New Issue
Block a user