summaryrefslogtreecommitdiff
path: root/src/modules/clist/genmenuopt.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2014-01-21 20:04:48 +0000
committerGeorge Hazan <george.hazan@gmail.com>2014-01-21 20:04:48 +0000
commitd154673f93ad95197bce8cadb995daa5bc39f5d8 (patch)
tree191522aa88f9f845a9c27b1ddb86116b87033c4b /src/modules/clist/genmenuopt.cpp
parentbe50a70bfd8b3f3daf0c3351fdce6e2fea515bd7 (diff)
minor code cleaning
git-svn-id: http://svn.miranda-ng.org/main/trunk@7820 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'src/modules/clist/genmenuopt.cpp')
-rw-r--r--src/modules/clist/genmenuopt.cpp20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/modules/clist/genmenuopt.cpp b/src/modules/clist/genmenuopt.cpp
index 6511c2d2b5..d21c7c7fd5 100644
--- a/src/modules/clist/genmenuopt.cpp
+++ b/src/modules/clist/genmenuopt.cpp
@@ -70,7 +70,7 @@ static BOOL GetCurrentMenuObjectID(HWND hwndDlg, int* result)
static int SaveTree(HWND hwndDlg)
{
int MenuObjectId;
- if ( !GetCurrentMenuObjectID(hwndDlg, &MenuObjectId))
+ if (!GetCurrentMenuObjectID(hwndDlg, &MenuObjectId))
return 0;
HWND hTree = GetDlgItem(hwndDlg, IDC_MENUITEMS);
@@ -255,7 +255,7 @@ static int BuildTree(HWND hwndDlg, int MenuObjectId, BOOL bReread)
DBVARIANT dbv;
mir_snprintf(buf, SIZEOF(buf), "%s_name", menuItemName);
- if ( !db_get_ts(NULL, MenuNameItems, buf, &dbv)) {
+ if (!db_get_ts(NULL, MenuNameItems, buf, &dbv)) {
PD->name = mir_tstrdup(dbv.ptszVal);
db_free(&dbv);
}
@@ -348,7 +348,7 @@ static HTREEITEM MoveItemAbove(HWND hTreeWnd, HTREEITEM hItem, HTREEITEM hInsert
TVITEM tvi = { 0 };
tvi.mask = TVIF_HANDLE | TVIF_PARAM;
tvi.hItem = hItem;
- if ( !SendMessage(hTreeWnd, TVM_GETITEM, 0, (LPARAM)&tvi))
+ if (!SendMessage(hTreeWnd, TVM_GETITEM, 0, (LPARAM)&tvi))
return NULL;
if (hItem && hInsertAfter) {
TVINSERTSTRUCT tvis;
@@ -362,9 +362,9 @@ static HTREEITEM MoveItemAbove(HWND hTreeWnd, HTREEITEM hItem, HTREEITEM hInsert
tvis.item.cchTextMax = sizeof(name);
tvis.item.hItem = hItem;
tvis.item.iImage = tvis.item.iSelectedImage = ((MenuItemOptData*)tvi.lParam)->bShow;
- if ( !SendMessage(hTreeWnd, TVM_GETITEM, 0, (LPARAM)&tvis.item))
+ if (!SendMessage(hTreeWnd, TVM_GETITEM, 0, (LPARAM)&tvis.item))
return NULL;
- if ( !TreeView_DeleteItem(hTreeWnd, hItem))
+ if (!TreeView_DeleteItem(hTreeWnd, hItem))
return NULL;
tvis.hParent = NULL;
tvis.hInsertAfter = hInsertAfter;
@@ -391,7 +391,7 @@ LRESULT CALLBACK LBTNDOWNProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam
tvi.hItem = hti.hItem;
TreeView_GetItem(tvw, &tvi);
- if ( !((MenuItemOptData *)tvi.lParam)->bIsSelected) { /* is not Selected*/
+ if (!((MenuItemOptData *)tvi.lParam)->bIsSelected) { /* is not Selected*/
// reset all selection except current
HTREEITEM hit;
hit = TreeView_GetRoot(tvw);
@@ -738,7 +738,7 @@ static INT_PTR CALLBACK GenMenuOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARA
break;
case WM_MOUSEMOVE:
- if ( !dat || !dat->dragging) break;
+ if (!dat || !dat->dragging) break;
{
TVHITTESTINFO hti;
@@ -751,7 +751,7 @@ static INT_PTR CALLBACK GenMenuOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARA
HTREEITEM it = hti.hItem;
hti.pt.y -= TreeView_GetItemHeight( GetDlgItem(hwndDlg, IDC_MENUITEMS))/2;
TreeView_HitTest( GetDlgItem(hwndDlg, IDC_MENUITEMS), &hti);
- if ( !(hti.flags&TVHT_ABOVE))
+ if (!(hti.flags&TVHT_ABOVE))
TreeView_SetInsertMark( GetDlgItem(hwndDlg, IDC_MENUITEMS), hti.hItem, 1);
else
TreeView_SetInsertMark( GetDlgItem(hwndDlg, IDC_MENUITEMS), it, 0);
@@ -765,7 +765,7 @@ static INT_PTR CALLBACK GenMenuOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARA
break;
case WM_LBUTTONUP:
- if ( !dat->dragging)
+ if (!dat->dragging)
break;
TreeView_SetInsertMark( GetDlgItem(hwndDlg, IDC_MENUITEMS), NULL, 0);
@@ -814,7 +814,7 @@ static INT_PTR CALLBACK GenMenuOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARA
for (i=0; i<uSic; i++) {
if (insertAfter) insertAfter = MoveItemAbove(tvw, pSIT[i], insertAfter);
else break;
- if ( !i) FirstItem = insertAfter;
+ if (!i) FirstItem = insertAfter;
}
}
// free pointers...