Matthias Kupfer (matthias DOT kupfer AT informatik DOT tu-chemnitz DOT de)
authorColin Finck <colin@reactos.org>
Tue, 10 Jun 2008 19:19:59 +0000 (19:19 +0000)
committerColin Finck <colin@reactos.org>
Tue, 10 Jun 2008 19:19:59 +0000 (19:19 +0000)
- Give the Run Dialog resources a default title (only done in German and English resources so far, others still need to be done)
- Add support for passing no title to RunFileDlg, so that it uses the default title
- Pass no hardcoded english title in Explorer and Task-Manager.
  I slightly modified the patch to also remove the other hardcoded text passed in Explorer.

See issue #3340 for more details.

svn path=/trunk/; revision=33919

reactos/base/applications/taskmgr/run.c
reactos/base/shell/explorer/taskbar/startmenu.cpp
reactos/dll/win32/shell32/dialogs.c
reactos/dll/win32/shell32/lang/de-DE.rc
reactos/dll/win32/shell32/lang/en-GB.rc
reactos/dll/win32/shell32/lang/en-US.rc

index 3503d1c..7c27f57 100644 (file)
@@ -43,7 +43,7 @@ void TaskManager_OnFileNew(void)
     {
         /* NOTE - don't check whether running on win 9x or NT, let's just
                   assume that a unicode build only runs on NT */
-        RunFileDlg(hMainWnd, 0, NULL, szTitle, szText, RFF_CALCDIRECTORY);
+        RunFileDlg(hMainWnd, 0, NULL, NULL, szText, RFF_CALCDIRECTORY);
     }
 
     FreeLibrary(hShell32);
index 024c736..ff25776 100644 (file)
@@ -2113,26 +2113,11 @@ void StartMenuHandler::ShowSearchComputer()
 
 void StartMenuHandler::ShowLaunchDialog(HWND hwndOwner)
 {
-        ///@todo All text phrases should be put into the resources.
-       static LPCSTR szTitle = "Run";
-       static LPCSTR szText = "Type the name of a program, folder, document, or Internet resource, and Explorer will open it for you.";
-
        static DynamicFct<RUNFILEDLG> RunFileDlg(TEXT("SHELL32"), 61);
 
         // Show "Run..." dialog
        if (RunFileDlg) {
-#ifndef _ROS_ /* FIXME: our shell32 always expects Ansi strings */
-               if ((HIWORD(GetVersion())>>14) == W_VER_NT) {
-                       WCHAR wTitle[40], wText[256];
-
-                       MultiByteToWideChar(CP_ACP, 0, szTitle, -1, wTitle, 40);
-                       MultiByteToWideChar(CP_ACP, 0, szText, -1, wText, 256);
-
-                       (*RunFileDlg)(hwndOwner, 0, NULL, (LPCSTR)wTitle, (LPCSTR)wText, RFF_CALCDIRECTORY);
-               }
-               else
-#endif
-                       (*RunFileDlg)(hwndOwner, 0, NULL, szTitle, szText, RFF_CALCDIRECTORY);
+               (*RunFileDlg)(hwndOwner, 0, NULL, NULL, NULL, RFF_CALCDIRECTORY);
        }
 }
 
index f55ef96..05e962c 100644 (file)
@@ -330,7 +330,10 @@ static INT_PTR CALLBACK RunDlgProc (HWND hwnd, UINT message, WPARAM wParam, LPAR
         {
         case WM_INITDIALOG :
             prfdp = (RUNFILEDLGPARAMS *)lParam ;
-            SetWindowTextA (hwnd, prfdp->lpstrTitle) ;
+
+            if (prfdp->lpstrTitle)
+                SetWindowTextA (hwnd, prfdp->lpstrTitle) ;
+
             SetClassLongPtrW (hwnd, GCLP_HICON, (LPARAM)prfdp->hIcon) ;
             SendMessageW (GetDlgItem (hwnd, 12297), STM_SETICON,
                           (WPARAM)LoadIconW (NULL, (LPCWSTR)IDI_WINLOGO), 0);
index ea0e57d..30d1137 100644 (file)
@@ -151,7 +151,7 @@ END
 
 SHELL_RUN_DLG DIALOGEX LOADONCALL MOVEABLE DISCARDABLE 0, 0, 227, 95
 STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
-CAPTION ""
+CAPTION "Ausführen"
 FONT 8, "MS Shell Dlg"
 BEGIN
        ICON "", 12297, 7, 11, 18, 20, WS_VISIBLE
index 5dbaa91..28af003 100644 (file)
@@ -149,7 +149,7 @@ END
 
 SHELL_RUN_DLG DIALOGEX LOADONCALL MOVEABLE DISCARDABLE 0, 0, 227, 95
 STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
-CAPTION ""
+CAPTION "Run"
 FONT 8, "MS Shell Dlg"
 BEGIN
        ICON "", 12297, 7, 11, 18, 20, WS_VISIBLE
index 2f2984b..a42a5d5 100644 (file)
@@ -149,7 +149,7 @@ END
 
 SHELL_RUN_DLG DIALOGEX LOADONCALL MOVEABLE DISCARDABLE 0, 0, 227, 95
 STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
-CAPTION ""
+CAPTION "Run"
 FONT 8, "MS Shell Dlg"
 BEGIN
        ICON "", 12297, 7, 11, 18, 20, WS_VISIBLE