[REGEDIT]
authorGabriel Ilardi <gabrielilardi@hotmail.it>
Sun, 23 May 2010 17:01:06 +0000 (17:01 +0000)
committerGabriel Ilardi <gabrielilardi@hotmail.it>
Sun, 23 May 2010 17:01:06 +0000 (17:01 +0000)
- Don't display "finished" message if search is aborted.
Patch by Katayama Hirofumi.
See issue #5421 for more details.

svn path=/trunk/; revision=47328

reactos/base/applications/regedit/find.c

index e20d016..e3bb26e 100644 (file)
@@ -684,7 +684,7 @@ BOOL FindNext(HWND hWnd)
         free(pszFoundValueName);
         SetFocus(g_pChildWnd->hListWnd);
     }
         free(pszFoundValueName);
         SetFocus(g_pChildWnd->hListWnd);
     }
-    return fSuccess;
+    return fSuccess || s_bAbort;
 }
 
 static INT_PTR CALLBACK FindDialogProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
 }
 
 static INT_PTR CALLBACK FindDialogProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
@@ -807,7 +807,7 @@ void FindDialog(HWND hWnd)
     if (DialogBoxParam(GetModuleHandle(NULL), MAKEINTRESOURCE(IDD_FIND),
         hWnd, FindDialogProc, 0) != 0)
     {
     if (DialogBoxParam(GetModuleHandle(NULL), MAKEINTRESOURCE(IDD_FIND),
         hWnd, FindDialogProc, 0) != 0)
     {
-        if (FindNext(hWnd) == FALSE)
+        if (!FindNext(hWnd))
         {
            TCHAR msg[128], caption[128];
 
         {
            TCHAR msg[128], caption[128];