Signed-off-by: Dmitry Timoshkov dmitry@baikal.ru --- dlls/comctl32/propsheet.c | 12 ++++++++---- dlls/comctl32/tests/propsheet.c | 4 ---- 2 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/dlls/comctl32/propsheet.c b/dlls/comctl32/propsheet.c index 8c72f20449..09a455121c 100644 --- a/dlls/comctl32/propsheet.c +++ b/dlls/comctl32/propsheet.c @@ -2012,6 +2012,13 @@ static BOOL PROPSHEET_SetCurSel(HWND hwndDlg, if (!psInfo->proppage[index].hwndPage) { if(!PROPSHEET_CreatePage(hwndDlg, index, psInfo, ppshpage)) { PROPSHEET_RemovePage(hwndDlg, index, NULL); + + if (!psInfo->isModeless) + { + DestroyWindow(hwndDlg); + return FALSE; + } + if(index >= psInfo->nPages) index--; if(index < 0) @@ -2754,7 +2761,7 @@ static void PROPSHEET_CleanUp(HWND hwndDlg) static INT do_loop(const PropSheetInfo *psInfo) { MSG msg; - INT ret = -1; + INT ret = 0; HWND hwnd = psInfo->hwnd; HWND parent = psInfo->ppshheader.hwndParent;
@@ -2771,10 +2778,7 @@ static INT do_loop(const PropSheetInfo *psInfo) }
if(ret == 0) - { PostQuitMessage(msg.wParam); - ret = -1; - }
if(ret != -1) ret = psInfo->result; diff --git a/dlls/comctl32/tests/propsheet.c b/dlls/comctl32/tests/propsheet.c index b5c05b253a..ea9b4a8e62 100644 --- a/dlls/comctl32/tests/propsheet.c +++ b/dlls/comctl32/tests/propsheet.c @@ -276,7 +276,6 @@ static void test_disableowner(void) psh.pfnCallback = disableowner_callback;
p = pPropertySheetA(&psh); - todo_wine ok(p == 0, "Expected 0, got %ld\n", p); ok(IsWindowEnabled(parenthwnd) != 0, "parent window should be enabled\n"); DestroyWindow(parenthwnd); @@ -1165,11 +1164,8 @@ static void test_bad_control_class(void) psh.hwndParent = GetDesktopWindow(); U3(psh).phpage = &hpsp;
-if (!strcmp(winetest_platform, "windows")) /* FIXME: enable once Wine is fixed */ -{ ret = pPropertySheetA(&psh); ok(ret == 0, "got %ld\n", ret); -}
/* Need to recreate hpsp otherwise the test fails under Windows */ hpsp = pCreatePropertySheetPageA(&psp);
Dmitry Timoshkov dmitry@baikal.ru writes:
Signed-off-by: Dmitry Timoshkov dmitry@baikal.ru
dlls/comctl32/propsheet.c | 12 ++++++++---- dlls/comctl32/tests/propsheet.c | 4 ---- 2 files changed, 8 insertions(+), 8 deletions(-)
Is there an app that needs this?
Alexandre Julliard julliard@winehq.org wrote:
Signed-off-by: Dmitry Timoshkov dmitry@baikal.ru
dlls/comctl32/propsheet.c | 12 ++++++++---- dlls/comctl32/tests/propsheet.c | 4 ---- 2 files changed, 8 insertions(+), 8 deletions(-)
Is there an app that needs this?
Yes, I have an application that stucks in the PropertySheet because of an error in the app's page dialog template. Apparently the app developers haven't noticed that because PropertySheet simply returns 0 under Windows and the app uses a different code path after that.
Dmitry Timoshkov dmitry@baikal.ru writes:
Alexandre Julliard julliard@winehq.org wrote:
Signed-off-by: Dmitry Timoshkov dmitry@baikal.ru
dlls/comctl32/propsheet.c | 12 ++++++++---- dlls/comctl32/tests/propsheet.c | 4 ---- 2 files changed, 8 insertions(+), 8 deletions(-)
Is there an app that needs this?
Yes, I have an application that stucks in the PropertySheet because of an error in the app's page dialog template. Apparently the app developers haven't noticed that because PropertySheet simply returns 0 under Windows and the app uses a different code path after that.
What app is that? I'm asking because during code freeze I'd like to know if the potential benefit to users is worth the risk of breaking things. So if it's an app that nobody uses, I'd rather defer it.