From 09539e4219c0019b4155dea1f1414ac753bed937 Mon Sep 17 00:00:00 2001 From: Dmitry Timoshkov Date: Tue, 5 Oct 2010 15:18:21 +0900 Subject: [PATCH] comctl32: Postpone setting the property sheet focus until the tab control is initialized. --- dlls/comctl32/propsheet.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/dlls/comctl32/propsheet.c b/dlls/comctl32/propsheet.c index 3e313bad59..3d2cd3b1b8 100644 --- a/dlls/comctl32/propsheet.c +++ b/dlls/comctl32/propsheet.c @@ -3415,10 +3415,7 @@ PROPSHEET_DialogProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) { /* set up the Next and Back buttons by default */ PROPSHEET_SetWizButtons(hwnd, PSWIZB_BACK|PSWIZB_NEXT); - SetFocus(GetDlgItem(hwnd, IDC_NEXT_BUTTON)); } - else - SetFocus(GetDlgItem(hwnd, IDOK)); /* Set up fonts */ SystemParametersInfoW (SPI_GETICONTITLELOGFONT, 0, &logFont, 0); @@ -3464,6 +3461,7 @@ PROPSHEET_DialogProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) ShowWindow(hwndTabCtrl, SW_HIDE); PROPSHEET_AdjustSizeWizard(hwnd, psInfo); PROPSHEET_AdjustButtonsWizard(hwnd, psInfo); + SetFocus(GetDlgItem(hwnd, IDC_NEXT_BUTTON)); } else { @@ -3472,6 +3470,7 @@ PROPSHEET_DialogProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) PROPSHEET_AdjustSize(hwnd, psInfo); PROPSHEET_AdjustButtons(hwnd, psInfo); } + SetFocus(GetDlgItem(hwnd, IDOK)); } if (IS_INTRESOURCE(psInfo->ppshheader.pszCaption) && -- 2.32.0.93.g670b81a890