Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
aefd67ff
Commit
aefd67ff
authored
Aug 31, 2022
by
Piotr Caban
Committed by
Alexandre Julliard
Oct 14, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
comctl32: Use HPROPSHEETPAGE directly in PROPSHEET_CreatePage.
parent
c7b5108c
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
26 additions
and
29 deletions
+26
-29
propsheet.c
dlls/comctl32/propsheet.c
+26
-29
No files found.
dlls/comctl32/propsheet.c
View file @
aefd67ff
...
...
@@ -1341,7 +1341,7 @@ static UINT GetTemplateSize(const DLGTEMPLATE* pTemplate)
static
BOOL
PROPSHEET_CreatePage
(
HWND
hwndParent
,
int
index
,
const
PropSheetInfo
*
psInfo
,
LPCPROPSHEETPAGEW
ppshpage
)
HPROPSHEETPAGE
hpsp
)
{
const
DLGTEMPLATE
*
pTemplate
;
HWND
hwndPage
;
...
...
@@ -1350,30 +1350,30 @@ static BOOL PROPSHEET_CreatePage(HWND hwndParent,
TRACE
(
"index %d
\n
"
,
index
);
if
(
ppshpage
==
NULL
)
if
(
hpsp
==
NULL
)
{
return
FALSE
;
}
if
(
ppshpage
->
dwFlags
&
PSP_DLGINDIRECT
)
if
(
hpsp
->
psp
.
dwFlags
&
PSP_DLGINDIRECT
)
{
pTemplate
=
ppshpage
->
u
.
pResource
;
pTemplate
=
hpsp
->
psp
.
u
.
pResource
;
resSize
=
GetTemplateSize
(
pTemplate
);
}
else
if
(
ppshpage
->
dwFlags
&
PSP_INTERNAL_UNICODE
)
else
if
(
hpsp
->
psp
.
dwFlags
&
PSP_INTERNAL_UNICODE
)
{
HRSRC
hResource
;
HANDLE
hTemplate
;
hResource
=
FindResourceW
(
ppshpage
->
hInstance
,
ppshpage
->
u
.
pszTemplate
,
hResource
=
FindResourceW
(
hpsp
->
psp
.
hInstance
,
hpsp
->
psp
.
u
.
pszTemplate
,
(
LPWSTR
)
RT_DIALOG
);
if
(
!
hResource
)
return
FALSE
;
resSize
=
SizeofResource
(
ppshpage
->
hInstance
,
hResource
);
resSize
=
SizeofResource
(
hpsp
->
psp
.
hInstance
,
hResource
);
hTemplate
=
LoadResource
(
ppshpage
->
hInstance
,
hResource
);
hTemplate
=
LoadResource
(
hpsp
->
psp
.
hInstance
,
hResource
);
if
(
!
hTemplate
)
return
FALSE
;
...
...
@@ -1387,15 +1387,15 @@ static BOOL PROPSHEET_CreatePage(HWND hwndParent,
HRSRC
hResource
;
HANDLE
hTemplate
;
hResource
=
FindResourceA
(
ppshpage
->
hInstance
,
(
LPCSTR
)
ppshpage
->
u
.
pszTemplate
,
hResource
=
FindResourceA
(
hpsp
->
psp
.
hInstance
,
(
LPCSTR
)
hpsp
->
psp
.
u
.
pszTemplate
,
(
LPSTR
)
RT_DIALOG
);
if
(
!
hResource
)
return
FALSE
;
resSize
=
SizeofResource
(
ppshpage
->
hInstance
,
hResource
);
resSize
=
SizeofResource
(
hpsp
->
psp
.
hInstance
,
hResource
);
hTemplate
=
LoadResource
(
ppshpage
->
hInstance
,
hResource
);
hTemplate
=
LoadResource
(
hpsp
->
psp
.
hInstance
,
hResource
);
if
(
!
hTemplate
)
return
FALSE
;
...
...
@@ -1439,21 +1439,20 @@ static BOOL PROPSHEET_CreatePage(HWND hwndParent,
}
if
(
psInfo
->
proppage
[
index
].
useCallback
)
(
*
(
ppshpage
->
pfnCallback
))(
0
,
PSPCB_CREATE
,
(
LPPROPSHEETPAGEW
)
ppshpage
);
(
*
(
hpsp
->
psp
.
pfnCallback
))(
0
,
PSPCB_CREATE
,
&
hpsp
->
psp
);
if
(
ppshpage
->
dwFlags
&
PSP_INTERNAL_UNICODE
)
hwndPage
=
CreateDialogIndirectParamW
(
ppshpage
->
hInstance
,
if
(
hpsp
->
psp
.
dwFlags
&
PSP_INTERNAL_UNICODE
)
hwndPage
=
CreateDialogIndirectParamW
(
hpsp
->
psp
.
hInstance
,
pTemplateCopy
,
hwndParent
,
ppshpage
->
pfnDlgProc
,
(
LPARAM
)
ppshpage
);
hpsp
->
psp
.
pfnDlgProc
,
(
LPARAM
)
&
hpsp
->
psp
);
else
hwndPage
=
CreateDialogIndirectParamA
(
ppshpage
->
hInstance
,
hwndPage
=
CreateDialogIndirectParamA
(
hpsp
->
psp
.
hInstance
,
pTemplateCopy
,
hwndParent
,
ppshpage
->
pfnDlgProc
,
(
LPARAM
)
ppshpage
);
hpsp
->
psp
.
pfnDlgProc
,
(
LPARAM
)
&
hpsp
->
psp
);
/* Free a no more needed copy */
Free
(
pTemplateCopy
);
...
...
@@ -1465,7 +1464,7 @@ static BOOL PROPSHEET_CreatePage(HWND hwndParent,
/* Subclass exterior wizard pages */
if
((
psInfo
->
ppshheader
.
dwFlags
&
(
PSH_WIZARD97_NEW
|
PSH_WIZARD97_OLD
))
&&
(
psInfo
->
ppshheader
.
dwFlags
&
PSH_WATERMARK
)
&&
(
ppshpage
->
dwFlags
&
PSP_HIDEHEADER
))
(
hpsp
->
psp
.
dwFlags
&
PSP_HIDEHEADER
))
{
SetWindowSubclass
(
hwndPage
,
PROPSHEET_WizardSubclassProc
,
1
,
0
);
}
...
...
@@ -1525,10 +1524,9 @@ static BOOL PROPSHEET_ShowPage(HWND hwndDlg, int index, PropSheetInfo * psInfo)
return
TRUE
;
}
ppshpage
=
(
LPCPROPSHEETPAGEW
)
psInfo
->
proppage
[
index
].
hpage
;
if
(
psInfo
->
proppage
[
index
].
hwndPage
==
0
)
{
PROPSHEET_CreatePage
(
hwndDlg
,
index
,
psInfo
,
p
ps
hpage
);
PROPSHEET_CreatePage
(
hwndDlg
,
index
,
psInfo
,
p
sInfo
->
proppage
[
index
].
hpage
);
}
if
(
psInfo
->
ppshheader
.
dwFlags
&
INTRNL_ANY_WIZARD
)
...
...
@@ -2009,7 +2007,7 @@ static BOOL PROPSHEET_SetCurSel(HWND hwndDlg,
psn
.
lParam
=
0
;
if
(
!
psInfo
->
proppage
[
index
].
hwndPage
)
{
if
(
!
PROPSHEET_CreatePage
(
hwndDlg
,
index
,
psInfo
,
p
ps
hpage
))
{
if
(
!
PROPSHEET_CreatePage
(
hwndDlg
,
index
,
psInfo
,
p
sInfo
->
proppage
[
index
].
hpage
))
{
PROPSHEET_RemovePage
(
hwndDlg
,
index
,
NULL
);
if
(
!
psInfo
->
isModeless
)
...
...
@@ -2247,7 +2245,6 @@ static BOOL PROPSHEET_InsertPage(HWND hwndDlg, HPROPSHEETPAGE hpageInsertAfter,
PropSheetInfo
*
psInfo
=
GetPropW
(
hwndDlg
,
PropSheetInfoStr
);
PropPageInfo
*
ppi
,
*
prev_ppi
=
psInfo
->
proppage
;
HWND
hwndTabControl
=
GetDlgItem
(
hwndDlg
,
IDC_TABCONTROL
);
LPCPROPSHEETPAGEW
ppsp
=
(
LPCPROPSHEETPAGEW
)
hpage
;
TCITEMW
item
;
int
index
;
...
...
@@ -2292,10 +2289,10 @@ static BOOL PROPSHEET_InsertPage(HWND hwndDlg, HPROPSHEETPAGE hpageInsertAfter,
psInfo
->
proppage
[
index
].
hpage
=
hpage
;
if
(
ppsp
->
dwFlags
&
PSP_PREMATURE
)
if
(
hpage
->
psp
.
dwFlags
&
PSP_PREMATURE
)
{
/* Create the page but don't show it */
if
(
!
PROPSHEET_CreatePage
(
hwndDlg
,
index
,
psInfo
,
ppsp
))
if
(
!
PROPSHEET_CreatePage
(
hwndDlg
,
index
,
psInfo
,
hpage
))
{
psInfo
->
proppage
=
prev_ppi
;
Free
(
ppi
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment