diff options
Diffstat (limited to 'plugins/AutoShutdown')
-rw-r--r-- | plugins/AutoShutdown/src/options.cpp | 19 | ||||
-rw-r--r-- | plugins/AutoShutdown/src/settingsdlg.cpp | 14 | ||||
-rw-r--r-- | plugins/AutoShutdown/src/utils.cpp | 6 |
3 files changed, 19 insertions, 20 deletions
diff --git a/plugins/AutoShutdown/src/options.cpp b/plugins/AutoShutdown/src/options.cpp index 007b7668b6..0db48e2a6f 100644 --- a/plugins/AutoShutdown/src/options.cpp +++ b/plugins/AutoShutdown/src/options.cpp @@ -103,18 +103,17 @@ static INT_PTR CALLBACK ShutdownOptDlgProc(HWND hwndDlg,UINT msg,WPARAM wParam,L return FALSE;
}
-static int ShutdownOptInit(WPARAM wParam,LPARAM lParam)
+static int ShutdownOptInit(WPARAM wParam, LPARAM lParam)
{
- OPTIONSDIALOGPAGE odp;
- ZeroMemory(&odp,sizeof(odp));
+ OPTIONSDIALOGPAGE odp = {0};
odp.cbSize=sizeof(odp);
- odp.hInstance=hInst;
- odp.pszTemplate=MAKEINTRESOURCEA(IDD_OPT_SHUTDOWN);
- odp.position=900000002;
- odp.ptszGroup=_T("Events"); /* autotranslated */
- odp.ptszTitle=_T("Automatic Shutdown"); /* autotranslated */
- odp.ptszTab=_T("Automatic Shutdown"); /* autotranslated, can be made a tab */
- odp.flags=ODPF_BOLDGROUPS|ODPF_TCHAR;
+ odp.hInstance = hInst;
+ odp.pszTemplate = MAKEINTRESOURCEA(IDD_OPT_SHUTDOWN);
+ odp.position = 900000002;
+ odp.ptszGroup = LPGENT("Events"); /* autotranslated */
+ odp.ptszTitle = LPGENT("Automatic Shutdown"); /* autotranslated */
+ odp.ptszTab = LPGENT("Automatic Shutdown"); /* autotranslated, can be made a tab */
+ odp.flags = ODPF_BOLDGROUPS | ODPF_TCHAR;
odp.pfnDlgProc = ShutdownOptDlgProc;
Options_AddPage(wParam, &odp);
return 0;
diff --git a/plugins/AutoShutdown/src/settingsdlg.cpp b/plugins/AutoShutdown/src/settingsdlg.cpp index 36910dfdf7..723909da7e 100644 --- a/plugins/AutoShutdown/src/settingsdlg.cpp +++ b/plugins/AutoShutdown/src/settingsdlg.cpp @@ -443,20 +443,20 @@ void SetShutdownMenuItem(BOOL fActive) CLISTMENUITEM mi = { sizeof(mi) };
mi.position = 2001090000;
mi.icolibItem = fActive ? iconList[1].hIcolib : iconList[2].hIcolib;
- mi.ptszName = fActive?_T("Stop automatic &shutdown"):_T("Automatic &shutdown..."); /* autotranslated */
+ mi.ptszName = fActive ? LPGENT("Stop automatic &shutdown") : LPGENT("Automatic &shutdown..."); /* autotranslated */
mi.pszService = "AutoShutdown/MenuCommand";
- mi.flags = CMIF_TCHAR|CMIF_ICONFROMICOLIB;
+ mi.flags = CMIF_TCHAR | CMIF_ICONFROMICOLIB;
if (hMainMenuItem != NULL) {
- mi.flags |= CMIM_NAME|CMIM_ICON;
- CallService(MS_CLIST_MODIFYMENUITEM,(WPARAM)hMainMenuItem,(LPARAM)&mi);
+ mi.flags |= CMIM_NAME | CMIM_ICON;
+ CallService(MS_CLIST_MODIFYMENUITEM, (WPARAM)hMainMenuItem, (LPARAM)&mi);
}
else hMainMenuItem = Menu_AddMainMenuItem(&mi);
/* tray menu */
mi.position = 899999;
- if(hTrayMenuItem!=NULL) {
- mi.flags|=CMIM_NAME|CMIM_ICON;
- CallService(MS_CLIST_MODIFYMENUITEM,(WPARAM)hTrayMenuItem,(LPARAM)&mi);
+ if(hTrayMenuItem != NULL) {
+ mi.flags |= CMIM_NAME | CMIM_ICON;
+ CallService(MS_CLIST_MODIFYMENUITEM, (WPARAM)hTrayMenuItem, (LPARAM)&mi);
}
else hTrayMenuItem = Menu_AddTrayMenuItem(&mi);
diff --git a/plugins/AutoShutdown/src/utils.cpp b/plugins/AutoShutdown/src/utils.cpp index 90e3356cfe..2bd70e83bc 100644 --- a/plugins/AutoShutdown/src/utils.cpp +++ b/plugins/AutoShutdown/src/utils.cpp @@ -321,10 +321,10 @@ void AddHotkey() hkd.cbSize = sizeof(hkd);
hkd.dwFlags = HKD_TCHAR;
hkd.pszName = "AutoShutdown_Toggle";
- hkd.ptszDescription = _T("Toggle Automatic Shutdown");
- hkd.ptszSection = _T("Main");
+ hkd.ptszDescription = LPGENT("Toggle Automatic Shutdown");
+ hkd.ptszSection = LPGENT("Main");
hkd.pszService = "AutoShutdown/MenuCommand";
- hkd.DefHotKey = HOTKEYCODE(HOTKEYF_CONTROL|HOTKEYF_SHIFT, 'T') | HKF_MIRANDA_LOCAL;
+ hkd.DefHotKey = HOTKEYCODE(HOTKEYF_CONTROL | HOTKEYF_SHIFT, 'T') | HKF_MIRANDA_LOCAL;
hkd.lParam = FALSE;
Hotkey_Register(&hkd);
}
|