PropSheet

Eric Pouech eric.pouech at wanadoo.fr
Sun Feb 23 03:27:49 CST 2003


Interestingly enough, our propsheet implementation didn't handle the 
PSNRET_INVALID error code while applying a sheet (only 
PSNRET_INVALID_NOCHANGEPAGE was supported).
This should take care of this.

A+
-- 
Eric Pouech
-------------- next part --------------
Name:          ps_invalid
ChangeLog:     added handling for PSNRET_INVALID in PSN_APPLY notification
License:       X11
GenDate:       2003/02/23 09:20:54 UTC
ModifiedFiles: dlls/comctl32/propsheet.c
AddedFiles:    
===================================================================
RCS file: /home/cvs/cvsroot/wine/wine/dlls/comctl32/propsheet.c,v
retrieving revision 1.81
diff -u -u -r1.81 propsheet.c
--- dlls/comctl32/propsheet.c	24 Jan 2003 00:54:59 -0000	1.81
+++ dlls/comctl32/propsheet.c	22 Feb 2003 10:27:44 -0000
@@ -1615,7 +1615,6 @@
   int i;
   HWND hwndPage;
   PSHNOTIFY psn;
-  LRESULT msgResult;
   PropSheetInfo* psInfo = (PropSheetInfo*) GetPropW(hwndDlg,
                                                     PropSheetInfoStr);
 
@@ -1649,9 +1648,14 @@
     hwndPage = psInfo->proppage[i].hwndPage;
     if (hwndPage)
     {
-       msgResult = SendMessageA(hwndPage, WM_NOTIFY, 0, (LPARAM) &psn);
-       if (msgResult == PSNRET_INVALID_NOCHANGEPAGE)
-          return FALSE;
+       switch (SendMessageA(hwndPage, WM_NOTIFY, 0, (LPARAM) &psn))
+       {
+       case PSNRET_INVALID:
+           PROPSHEET_ShowPage(hwndDlg, i, psInfo);
+           /* fall through */
+       case PSNRET_INVALID_NOCHANGEPAGE:
+           return FALSE;
+       }
     }
   }
 


More information about the wine-patches mailing list