diff options
Diffstat (limited to 'plugins/Clist_modern')
-rw-r--r-- | plugins/Clist_modern/modern_tbbutton.cpp | 37 | ||||
-rw-r--r-- | plugins/Clist_modern/modern_toolbar.cpp | 2 | ||||
-rw-r--r-- | plugins/Clist_modern/modern_viewmodebar.cpp | 10 |
3 files changed, 21 insertions, 28 deletions
diff --git a/plugins/Clist_modern/modern_tbbutton.cpp b/plugins/Clist_modern/modern_tbbutton.cpp index f6dac962f5..bf0fe2add4 100644 --- a/plugins/Clist_modern/modern_tbbutton.cpp +++ b/plugins/Clist_modern/modern_tbbutton.cpp @@ -256,35 +256,28 @@ static LRESULT CALLBACK TollbarButtonProc(HWND hwndDlg, UINT msg, WPARAM wParam SendMessage(hwndToolTips, TTM_ADDTOOL, 0, (LPARAM) &ti);
break;
}
+
case BUTTONSETASPUSHBTN:
- {
+ lpSBData->pushBtn = (wParam != 0);
+ lpSBData->pbState = (lParam & 2) != 0;
+ return 0;
- if (lParam==0)
- lpSBData->pushBtn=1;
- else
- {
- lpSBData->pushBtn=wParam;
- lpSBData->pbState = (lParam&2) ? TRUE : FALSE;
- }
- return 0;
- }
case WM_SETFOCUS:
- {
- // set keyboard focus and redraw
- lpSBData->fFocused = TRUE;
- InvalidateParentRect(lpSBData->hWnd, NULL, TRUE);
- break;
- }
+ // set keyboard focus and redraw
+ lpSBData->fFocused = TRUE;
+ InvalidateParentRect(lpSBData->hWnd, NULL, TRUE);
+ break;
+
case WM_KILLFOCUS:
- {
- // kill focus and redraw
- lpSBData->fFocused = FALSE;
- InvalidateParentRect(lpSBData->hWnd, NULL, TRUE);
- break;
- }
+ // kill focus and redraw
+ lpSBData->fFocused = FALSE;
+ InvalidateParentRect(lpSBData->hWnd, NULL, TRUE);
+ break;
+
case WM_WINDOWPOSCHANGED:
InvalidateParentRect(lpSBData->hWnd, NULL, TRUE);
break;
+
case WM_ENABLE:
// windows tells us to enable/disable
{
diff --git a/plugins/Clist_modern/modern_toolbar.cpp b/plugins/Clist_modern/modern_toolbar.cpp index d39bbf4c48..50ad1064ad 100644 --- a/plugins/Clist_modern/modern_toolbar.cpp +++ b/plugins/Clist_modern/modern_toolbar.cpp @@ -910,7 +910,7 @@ static LRESULT CALLBACK ToolBar_WndProc(HWND hwnd,UINT msg,WPARAM wParam,LPARAM strcat(buttonId,mtbi->szButtonID);
SendMessage(hwndButton, BUTTONSETID, 0 ,(LPARAM) buttonId );
if (pMTBInfo->bFlatButtons)
- SendMessage(hwndButton, BUTTONSETASFLATBTN, 0, 1 );
+ SendMessage(hwndButton, BUTTONSETASFLATBTN, TRUE, 0 );
SetWindowLongPtr(hwndButton,GWLP_USERDATA,(LONG_PTR)mtbi);
SendMessage(hwndButton, MBM_UPDATETRANSPARENTFLAG, 0, 2);
}
diff --git a/plugins/Clist_modern/modern_viewmodebar.cpp b/plugins/Clist_modern/modern_viewmodebar.cpp index c896e3b852..ae385f77bb 100644 --- a/plugins/Clist_modern/modern_viewmodebar.cpp +++ b/plugins/Clist_modern/modern_viewmodebar.cpp @@ -1081,7 +1081,7 @@ LRESULT CALLBACK ViewModeFrameWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM SendMessage(hwndSelector, BUTTONSETMARGINS,0 ,(LPARAM) &rcMargins);
SendMessage(hwndSelector, BUTTONSETID,0 ,(LPARAM) "ViewMode.Select" );
SendMessage(hwndSelector, WM_SETFONT,0 ,(LPARAM) FONTID_VIEMODES+1 );
- SendMessage(hwndSelector, BUTTONSETASFLATBTN, 0, 1 );
+ SendMessage(hwndSelector, BUTTONSETASFLATBTN, TRUE, 0 );
SendMessage(hwndSelector, MBM_UPDATETRANSPARENTFLAG, 0, 2);
SendMessage(hwndSelector, BUTTONSETSENDONDOWN, 0 ,(LPARAM) 1 );
@@ -1090,7 +1090,7 @@ LRESULT CALLBACK ViewModeFrameWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM hwnd, (HMENU) IDC_CONFIGUREMODES, g_hInst, NULL);
SendMessage(hwndButton, BUTTONADDTOOLTIP, (WPARAM)TranslateT("Setup view modes"), 0);
SendMessage(hwndButton, BUTTONSETID,0 ,(LPARAM) "ViewMode.Setup" );
- SendMessage(hwndButton, BUTTONSETASFLATBTN, 0, 1 );
+ SendMessage(hwndButton, BUTTONSETASFLATBTN, TRUE, 0 );
SendMessage(hwndButton, MBM_UPDATETRANSPARENTFLAG, 0, 2);
hwndButton = CreateWindow( SKINBUTTONCLASS, _T(""), BS_PUSHBUTTON | WS_VISIBLE | WS_CHILD | WS_TABSTOP, 0, 0, 20, 20,
@@ -1098,7 +1098,7 @@ LRESULT CALLBACK ViewModeFrameWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM SendMessage(hwndButton, BUTTONADDTOOLTIP, (WPARAM)TranslateT("Clear view mode and return to default display"), 0);
SendMessage(hwndButton, BUTTONSETID,0 ,(LPARAM) "ViewMode.Clear" );
SendMessage(hwnd, WM_USER + 100, 0, 0);
- SendMessage(hwndButton, BUTTONSETASFLATBTN, 0, 1 );
+ SendMessage(hwndButton, BUTTONSETASFLATBTN, TRUE, 0 );
SendMessage(hwndButton, MBM_UPDATETRANSPARENTFLAG, 0, 2);
return FALSE;
}
@@ -1140,11 +1140,11 @@ LRESULT CALLBACK ViewModeFrameWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM while(_buttons[i] != 0) {
//SendMessage(GetDlgItem(hwnd, _buttons[i]), BM_SETSKINNED, 0, bSkinned);
if(1&&bSkinned) {
- SendDlgItemMessage(hwnd, _buttons[i], BUTTONSETASFLATBTN, 0, 0);
+ SendDlgItemMessage(hwnd, _buttons[i], BUTTONSETASFLATBTN, TRUE, 0);
SendDlgItemMessage(hwnd, _buttons[i], BUTTONSETASFLATBTN + 10, 0, 0);
}
else {
- SendDlgItemMessage(hwnd, _buttons[i], BUTTONSETASFLATBTN, 0, 1);
+ SendDlgItemMessage(hwnd, _buttons[i], BUTTONSETASFLATBTN, TRUE, 1);
SendDlgItemMessage(hwnd, _buttons[i], BUTTONSETASFLATBTN + 10, 0, 1);
}
i++;
|