[APPLICATIONS]
[reactos.git] / reactos / base / applications / regedit / framewnd.c
index baccec0..e37adbe 100644 (file)
@@ -367,12 +367,14 @@ static BOOL UnloadHive(HWND hWnd)
     TCHAR Caption[128];
     LPCTSTR pszKeyPath;
     HKEY hRootKey;
+    LONG regUnloadResult;
+
     /* get the item key to unload */
     pszKeyPath = GetItemPath(g_pChildWnd->hTreeWnd, 0, &hRootKey);
     /* load and set the caption and flags for dialog */
     LoadString(hInst, IDS_UNLOAD_HIVE, Caption, COUNT_OF(Caption));
     /* now unload the hive */
-    LONG regUnloadResult = RegUnLoadKey(hRootKey, pszKeyPath);
+    regUnloadResult = RegUnLoadKey(hRootKey, pszKeyPath);
     if(regUnloadResult == ERROR_SUCCESS)
     {
         /* refresh tree and list views */
@@ -1175,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_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);