summaryrefslogtreecommitdiff
path: root/src/mir_app
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2016-12-04 19:04:41 +0300
committerGeorge Hazan <ghazan@miranda.im>2016-12-04 19:04:55 +0300
commitb6c0516b0535f9f4dc14cd4c6ea506762d56cf3e (patch)
tree960dfb2c07ccef5439b6e89ca09a3588d1170bb0 /src/mir_app
parentf49a3ebbe5c0f420ce328b5db3c1723cd0af4ed0 (diff)
small fixes
Diffstat (limited to 'src/mir_app')
-rw-r--r--src/mir_app/src/srmm_toolbar.cpp10
1 files changed, 4 insertions, 6 deletions
diff --git a/src/mir_app/src/srmm_toolbar.cpp b/src/mir_app/src/srmm_toolbar.cpp
index caf9335836..e3e93a29b2 100644
--- a/src/mir_app/src/srmm_toolbar.cpp
+++ b/src/mir_app/src/srmm_toolbar.cpp
@@ -158,16 +158,15 @@ MIR_APP_DLL(int) Srmm_GetButtonState(HWND hwndDlg, BBButton *bbdi)
return 1;
DWORD tempCID = 0;
- bool realbutton = false;
bbdi->bbbFlags = 0;
for (int i = 0; i < arButtonsList.getCount(); i++) {
CustomButtonData *cbd = arButtonsList[i];
if (!mir_strcmp(cbd->m_pszModuleName, bbdi->pszModuleName) && (cbd->m_dwButtonOrigID == bbdi->dwButtonID)) {
- realbutton = true;
tempCID = cbd->m_dwButtonCID;
+ break;
}
}
- if (!realbutton)
+ if (!tempCID)
return 1;
HWND hwndBtn = GetDlgItem(hwndDlg, tempCID);
@@ -180,16 +179,15 @@ MIR_APP_DLL(int) Srmm_SetButtonState(MCONTACT hContact, BBButton *bbdi)
if (hContact == NULL || bbdi == NULL)
return 1;
- bool realbutton = false;
DWORD tempCID = 0;
for (int i = 0; i < arButtonsList.getCount(); i++) {
CustomButtonData *cbd = arButtonsList[i];
if (!mir_strcmp(cbd->m_pszModuleName, bbdi->pszModuleName) && (cbd->m_dwButtonOrigID == bbdi->dwButtonID)) {
- realbutton = true;
tempCID = cbd->m_dwButtonCID;
+ break;
}
}
- if (!realbutton)
+ if (!tempCID)
return 1;
HWND hwndDlg = WindowList_Find(NULL, hContact);