Zhiyi Zhang (@zhiyi) commented about dlls/comctl32/tests/propsheet.c:
- psh.dwFlags = PSH_PROPSHEETPAGE | PSH_MODELESS;
- psh.hwndParent = GetDesktopWindow();
- psh.pszCaption = "Modeless Property Sheet";
- psh.nPages = sizeof(psp) / sizeof(PROPSHEETPAGEA);
- psh.ppsp = (LPCPROPSHEETPAGEA)&psp;
- hp = (HWND) pPropertySheetA(&psh);
- tab_ctrl = (HWND)SendMessageA(hp, PSM_GETTABCONTROL, 0, 0);
- //Test PSN_QUERYINITIALFOCUS gets sent on start
- ok(query_initial_focus, "Did not recieve PSN_QUERYINITIALFOCUS on start.\n");
- query_initial_focus = 0;
- //Test changing of tabs
- ok(tab_ctrl != 0, "Could not test changing tabs. No tab control found.\n");
- if(tab_ctrl)
You can remove this if(tab_ctrl) check. ok(tab_ctrl != 0, ...) already checks for this.