mirror of
https://github.com/chibicitiberiu/rainmeter-studio.git
synced 2024-02-24 04:33:31 +00:00
ConfigParser: Implement ReadBool
This may break backwards compatibility in some cases. For example, the FreeDiskSpace measure treated only `Type=1` as true and `Type={0, 2, 3, ...}` as false. Now `Type=0` is false and everything else is true like with most other boolean options.
This commit is contained in:
@ -363,7 +363,7 @@ void TrayWindow::ReadOptions(ConfigParser& parser)
|
||||
m_MeterType = TRAY_METER_TYPE_NONE;
|
||||
|
||||
// Read tray settings
|
||||
m_IconEnabled = 0!=parser.ReadInt(L"Rainmeter", L"TrayIcon", 1);
|
||||
m_IconEnabled = parser.ReadBool(L"Rainmeter", L"TrayIcon", true);
|
||||
if (m_IconEnabled)
|
||||
{
|
||||
const std::wstring& measureName = parser.ReadString(L"TrayMeasure", L"Measure", L"");
|
||||
|
Reference in New Issue
Block a user