[APPLICATIONS]
authorRafal Harabien <rafalh@reactos.org>
Sun, 1 May 2011 12:53:10 +0000 (12:53 +0000)
committerRafal Harabien <rafalh@reactos.org>
Sun, 1 May 2011 12:53:10 +0000 (12:53 +0000)
* Properly support WM_SYSCOLORCHANGE in msconfig, mspaint, rapps, regedit and regedit

svn path=/trunk/; revision=51523

reactos/base/applications/msconfig/msconfig.c
reactos/base/applications/mspaint/winproc.c
reactos/base/applications/rapps/winmain.c
reactos/base/applications/regedit/framewnd.c
reactos/base/applications/sndvol32/sndvol32.c

index 49f2e31..7f68f98 100644 (file)
@@ -212,6 +212,13 @@ MsConfigWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
             }
             break;
 
             }
             break;
 
+        case WM_SYSCOLORCHANGE:
+            /* Forward WM_SYSCOLORCHANGE to common controls */
+            SendMessage(hServicesListCtrl, WM_SYSCOLORCHANGE, 0, 0);
+            SendMessage(hStartupListCtrl, WM_SYSCOLORCHANGE, 0, 0);
+            SendMessage(hToolsListCtrl, WM_SYSCOLORCHANGE, 0, 0);
+            break;
+
         case WM_DESTROY:
             if (hToolsPage)
                 DestroyWindow(hToolsPage);
         case WM_DESTROY:
             if (hToolsPage)
                 DestroyWindow(hToolsPage);
index 23e1855..213efaf 100644 (file)
@@ -692,6 +692,14 @@ WindowProcedure(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
 
         // menu and button events
 
 
         // menu and button events
 
+        case WM_SYSCOLORCHANGE:
+        {
+            /* Redirect message to common controls */
+            HWND hToolbar = FindWindowEx(hToolBoxContainer, NULL, TOOLBARCLASSNAME, NULL);
+            SendMessage(hToolbar, WM_SYSCOLORCHANGE, 0, 0);
+            break;
+        }
+
         case WM_COMMAND:
             switch (LOWORD(wParam))
             {
         case WM_COMMAND:
             switch (LOWORD(wParam))
             {
index 9f6a0fc..d722fac 100644 (file)
@@ -717,6 +717,15 @@ MainWindowProc(HWND hwnd, UINT Msg, WPARAM wParam, LPARAM lParam)
             return TRUE;
         }
 
             return TRUE;
         }
 
+        case WM_SYSCOLORCHANGE:
+        {
+            /* Forward WM_SYSCOLORCHANGE to common controls */
+            SendMessage(hListView, WM_SYSCOLORCHANGE, 0, 0);
+            SendMessage(hTreeView, WM_SYSCOLORCHANGE, 0, 0);
+            SendMessage(hToolBar, WM_SYSCOLORCHANGE, 0, 0);
+        }
+        break;
+
         case WM_DESTROY:
         {
             ShowWindow(hwnd, SW_HIDE);
         case WM_DESTROY:
         {
             ShowWindow(hwnd, SW_HIDE);
index 5d9a682..e37adbe 100644 (file)
@@ -1177,6 +1177,11 @@ LRESULT CALLBACK FrameWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lPa
     case WM_MENUSELECT:
         OnMenuSelect(hWnd, LOWORD(wParam), HIWORD(wParam), (HMENU)lParam);
         break;
     case WM_MENUSELECT:
         OnMenuSelect(hWnd, LOWORD(wParam), HIWORD(wParam), (HMENU)lParam);
         break;
+    case WM_SYSCOLORCHANGE:
+        /* Forward WM_SYSCOLORCHANGE to common controls */
+        SendMessage(g_pChildWnd->hListWnd, WM_SYSCOLORCHANGE, 0, 0);
+        SendMessage(g_pChildWnd->hTreeWnd, WM_SYSCOLORCHANGE, 0, 0);
+        break;
     case WM_DESTROY:
         WinHelp(hWnd, _T("regedit"), HELP_QUIT, 0);
         PostQuitMessage(0);
     case WM_DESTROY:
         WinHelp(hWnd, _T("regedit"), HELP_QUIT, 0);
         PostQuitMessage(0);
index 3090bfa..ec16547 100644 (file)
@@ -579,7 +579,7 @@ DlgPreferencesProc(HWND hwndDlg,
         {
             HWND hwndControls;
             
         {
             HWND hwndControls;
             
-            /* Forward WM_SYSCOLORCHANGE to common controls */
+            /* Forward WM_SYSCOLORCHANGE */
             hwndControls = GetDlgItem(hwndDlg, IDC_CONTROLS);
             SendMessage(hwndControls, WM_SYSCOLORCHANGE, 0, 0);
             break;
             hwndControls = GetDlgItem(hwndDlg, IDC_CONTROLS);
             SendMessage(hwndControls, WM_SYSCOLORCHANGE, 0, 0);
             break;