From 81af1660759b655e0e65bf2f955ef50e87975a13 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Sun, 30 Jul 2017 21:40:51 +0300 Subject: minor code cleaning --- plugins/DbEditorPP/src/main.cpp | 6 ++---- plugins/MenuItemEx/src/main.cpp | 3 +-- plugins/SmileyAdd/src/smileyroutines.cpp | 1 - plugins/TabSRMM/src/msgdialog.cpp | 7 +------ 4 files changed, 4 insertions(+), 13 deletions(-) (limited to 'plugins') diff --git a/plugins/DbEditorPP/src/main.cpp b/plugins/DbEditorPP/src/main.cpp index 0ec3a08be8..fe31957c25 100644 --- a/plugins/DbEditorPP/src/main.cpp +++ b/plugins/DbEditorPP/src/main.cpp @@ -130,13 +130,11 @@ int ModulesLoaded(WPARAM, LPARAM) hUserMenu = Menu_AddContactMenuItem(&mi); // Register hotkeys - _A2T text(modFullname); HOTKEYDESC hkd = {}; - hkd.dwFlags = HKD_UNICODE; hkd.pszName = "hk_dbepp_open"; hkd.pszService = "DBEditorpp/MenuCommand"; - hkd.szDescription.w = LPGENW("Open Database Editor"); - hkd.szSection.w = text; + hkd.szSection.a = modFullname; + hkd.szDescription.a = LPGEN("Open Database Editor"); hkd.DefHotKey = HOTKEYCODE(HOTKEYF_SHIFT | HOTKEYF_EXT, 'D'); Hotkey_Register(&hkd); diff --git a/plugins/MenuItemEx/src/main.cpp b/plugins/MenuItemEx/src/main.cpp index c8534b46bb..2872e57272 100644 --- a/plugins/MenuItemEx/src/main.cpp +++ b/plugins/MenuItemEx/src/main.cpp @@ -908,8 +908,7 @@ static void TabsrmmButtonsModify(MCONTACT hContact) { if (!DirectoryExists(hContact)) { - BBButton bbd = { 0 }; - bbd.dwButtonID = 0; + BBButton bbd = {}; bbd.pszModuleName = MODULENAME; bbd.bbbFlags = BBSF_DISABLED | BBSF_HIDDEN; Srmm_SetButtonState(hContact, &bbd); diff --git a/plugins/SmileyAdd/src/smileyroutines.cpp b/plugins/SmileyAdd/src/smileyroutines.cpp index a56be87b9f..b893fca9fa 100644 --- a/plugins/SmileyAdd/src/smileyroutines.cpp +++ b/plugins/SmileyAdd/src/smileyroutines.cpp @@ -21,7 +21,6 @@ along with this program. If not, see . #include -ISmileyBase* CreateSmileyObject(SmileyType *sml); ISmileyBase* CreateAniSmileyObject(SmileyType *sml, COLORREF clr, bool ishpp); bool g_HiddenTextSupported = true; diff --git a/plugins/TabSRMM/src/msgdialog.cpp b/plugins/TabSRMM/src/msgdialog.cpp index 29b8826dd0..298fc77b1b 100644 --- a/plugins/TabSRMM/src/msgdialog.cpp +++ b/plugins/TabSRMM/src/msgdialog.cpp @@ -1535,12 +1535,6 @@ int CSrmmWindow::OnFilter(MSGFILTER *pFilter) bool isCtrl, isShift, isAlt; KbdState(isShift, isCtrl, isAlt); - MSG message; - message.hwnd = m_hwnd; - message.message = msg; - message.lParam = lp; - message.wParam = wp; - if (msg == WM_SYSKEYUP) { if (wp == VK_MENU) if (!m_bkeyProcessed && !(GetKeyState(VK_CONTROL) & 0x8000) && !(GetKeyState(VK_SHIFT) & 0x8000) && !(lp & (1 << 24))) @@ -1550,6 +1544,7 @@ int CSrmmWindow::OnFilter(MSGFILTER *pFilter) } if ((msg == WM_KEYDOWN || msg == WM_SYSKEYDOWN) && !(GetKeyState(VK_RMENU) & 0x8000)) { + MSG message = { m_hwnd, msg, wp, lp }; LRESULT mim_hotkey_check = Hotkey_Check(&message, TABSRMM_HK_SECTION_IM); if (mim_hotkey_check) m_bkeyProcessed = true; -- cgit v1.2.3