mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 01:55:19 +00:00
[STOBJECT][MMSYS][POWERCFG] Store the "Show x icon in the taskbar" setting for the hotplug, power and volume icons.
CORE-12365 CORE-12972 CORE-15234
This commit is contained in:
parent
a7ddabcc12
commit
8fb2a2dd12
2 changed files with 7 additions and 4 deletions
|
@ -365,7 +365,7 @@ SaveData(HWND hwndDlg)
|
|||
|
||||
bShowIcon = (IsDlgButtonChecked(hwndDlg, IDC_ICON_IN_TASKBAR) == BST_CHECKED);
|
||||
|
||||
SetSystrayVolumeIconState(!bShowIcon);
|
||||
SetSystrayVolumeIconState(bShowIcon);
|
||||
}
|
||||
|
||||
VOID
|
||||
|
|
|
@ -301,17 +301,20 @@ Adv_InitDialog(VOID)
|
|||
BOOLEAN bSuspend = FALSE;
|
||||
BOOLEAN bHibernate;
|
||||
BOOLEAN bShutdown;
|
||||
BOOL bEnabled;
|
||||
|
||||
SYSTEM_POWER_CAPABILITIES spc;
|
||||
|
||||
if (GetSystrayPowerIconState())
|
||||
bEnabled = GetSystrayPowerIconState();
|
||||
|
||||
if (bEnabled)
|
||||
gGPP.user.GlobalFlags |= EnableSysTrayBatteryMeter;
|
||||
else
|
||||
gGPP.user.GlobalFlags &= ~EnableSysTrayBatteryMeter;
|
||||
|
||||
CheckDlgButton(hAdv,
|
||||
IDC_SYSTRAYBATTERYMETER,
|
||||
gGPP.user.GlobalFlags & EnableSysTrayBatteryMeter ? BST_CHECKED : BST_UNCHECKED);
|
||||
bEnabled ? BST_CHECKED : BST_UNCHECKED);
|
||||
CheckDlgButton(hAdv,
|
||||
IDC_PASSWORDLOGON,
|
||||
gGPP.user.GlobalFlags & EnablePasswordLogon ? BST_CHECKED : BST_UNCHECKED);
|
||||
|
@ -501,7 +504,7 @@ Adv_SaveData(HWND hwndDlg)
|
|||
MessageBox(hwndDlg, L"WriteGlobalPwrPolicy failed", NULL, MB_OK);
|
||||
}
|
||||
|
||||
SetSystrayPowerIconState(!bSystrayBatteryMeter);
|
||||
SetSystrayPowerIconState(bSystrayBatteryMeter);
|
||||
|
||||
Adv_InitDialog();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue