comdlg32: Open should try to browse directory first.
authorGabriele Moabiti <gabmoa@yahoo.it>
Mon, 15 Feb 2010 13:48:11 +0000 (14:48 +0100)
committerAlexandre Julliard <julliard@winehq.org>
Thu, 18 Feb 2010 13:38:58 +0000 (14:38 +0100)
dlls/comdlg32/filedlg.c

index 5e8f75e420d6624e3c793ae92583caa5dfa3b75b..58b57ccbbaccf8b710203b74ee81d0369634c833 100644 (file)
@@ -1989,15 +1989,15 @@ BOOL FILEDLG95_OnOpen(HWND hwnd)
 
   TRACE("hwnd=%p\n", hwnd);
 
+  /* try to browse the selected item */
+  if(BrowseSelectedFolder(hwnd))
+      return FALSE;
+
   /* get the files from the edit control */
   nFileCount = FILEDLG95_FILENAME_GetFileNames(hwnd, &lpstrFileList, &sizeUsed);
 
-  /* try if the user selected a folder in the shellview */
   if(nFileCount == 0)
-  {
-      BrowseSelectedFolder(hwnd);
       return FALSE;
-  }
 
   if(nFileCount > 1)
   {