Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
ca136d75
Commit
ca136d75
authored
May 27, 2011
by
David Hedberg
Committed by
Alexandre Julliard
May 27, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
comdlg32: Support adding custom controls to the item dialog.
parent
44e7cda4
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
71 additions
and
0 deletions
+71
-0
itemdlg.c
dlls/comdlg32/itemdlg.c
+0
-0
itemdlg.c
dlls/comdlg32/tests/itemdlg.c
+71
-0
No files found.
dlls/comdlg32/itemdlg.c
View file @
ca136d75
This diff is collapsed.
Click to expand it.
dlls/comdlg32/tests/itemdlg.c
View file @
ca136d75
...
...
@@ -1200,11 +1200,21 @@ static void test_filename(void)
DeleteFileW
(
filename_ext2W
);
}
static
const
WCHAR
label
[]
=
{
'l'
,
'a'
,
'b'
,
'e'
,
'l'
,
0
};
static
const
WCHAR
menuW
[]
=
{
'm'
,
'e'
,
'n'
,
'u'
,
'_'
,
'i'
,
't'
,
'e'
,
'm'
,
0
};
static
const
WCHAR
pushbutton1W
[]
=
{
'p'
,
'u'
,
's'
,
'h'
,
'b'
,
'u'
,
't'
,
't'
,
'o'
,
'n'
,
'_'
,
'i'
,
't'
,
'e'
,
'm'
,
0
};
static
const
WCHAR
pushbutton2W
[]
=
{
'p'
,
'u'
,
's'
,
'h'
,
'b'
,
'u'
,
't'
,
't'
,
'o'
,
'n'
,
'2'
,
'_'
,
'i'
,
't'
,
'e'
,
'm'
,
0
};
static
const
WCHAR
checkbutton1W
[]
=
{
'c'
,
'h'
,
'e'
,
'c'
,
'k'
,
'b'
,
'u'
,
't'
,
't'
,
'o'
,
'n'
,
'1'
,
'_'
,
'i'
,
't'
,
'e'
,
'm'
,
0
};
static
const
WCHAR
editbox1W
[]
=
{
'e'
,
'd'
,
'i'
,
't'
,
'b'
,
'o'
,
'x'
,
'W'
,
'1'
,
'_'
,
'i'
,
't'
,
'e'
,
'm'
,
0
};
static
const
WCHAR
textW
[]
=
{
't'
,
'e'
,
'x'
,
't'
,
'_'
,
'i'
,
't'
,
'e'
,
'm'
,
0
};
static
const
WCHAR
visualgroup1W
[]
=
{
'v'
,
'i'
,
's'
,
'u'
,
'a'
,
'l'
,
'g'
,
'r'
,
'o'
,
'u'
,
'p'
,
'1'
,
0
};
static
void
test_customize
(
void
)
{
IFileDialog
*
pfod
;
IFileDialogCustomize
*
pfdc
;
IOleWindow
*
pow
;
UINT
i
;
LONG
ref
;
HWND
dlg_hwnd
;
HRESULT
hr
;
...
...
@@ -1220,6 +1230,12 @@ static void test_customize(void)
return
;
}
i
=
0
;
hr
=
IFileDialogCustomize_AddPushButton
(
pfdc
,
i
,
pushbutton1W
);
ok
(
hr
==
S_OK
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_AddPushButton
(
pfdc
,
i
,
pushbutton1W
);
ok
(
hr
==
E_UNEXPECTED
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialog_QueryInterface
(
pfod
,
&
IID_IOleWindow
,
(
void
**
)
&
pow
);
ok
(
hr
==
S_OK
,
"Got 0x%08x
\n
"
,
hr
);
hr
=
IOleWindow_GetWindow
(
pow
,
&
dlg_hwnd
);
...
...
@@ -1227,6 +1243,61 @@ static void test_customize(void)
ok
(
dlg_hwnd
==
NULL
,
"NULL
\n
"
);
IOleWindow_Release
(
pow
);
hr
=
IFileDialogCustomize_EnableOpenDropDown
(
pfdc
,
i
);
todo_wine
ok
(
hr
==
E_UNEXPECTED
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_EnableOpenDropDown
(
pfdc
,
++
i
);
todo_wine
ok
(
hr
==
S_OK
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_AddMenu
(
pfdc
,
i
,
menuW
);
todo_wine
ok
(
hr
==
E_UNEXPECTED
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_AddMenu
(
pfdc
,
++
i
,
label
);
ok
(
hr
==
S_OK
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_AddPushButton
(
pfdc
,
i
,
pushbutton2W
);
ok
(
hr
==
E_UNEXPECTED
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_AddPushButton
(
pfdc
,
++
i
,
pushbutton2W
);
ok
(
hr
==
S_OK
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_AddComboBox
(
pfdc
,
i
);
ok
(
hr
==
E_UNEXPECTED
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_AddComboBox
(
pfdc
,
++
i
);
ok
(
hr
==
S_OK
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_AddRadioButtonList
(
pfdc
,
i
);
todo_wine
ok
(
hr
==
E_UNEXPECTED
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_AddRadioButtonList
(
pfdc
,
++
i
);
todo_wine
ok
(
hr
==
S_OK
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_AddCheckButton
(
pfdc
,
i
,
label
,
TRUE
);
todo_wine
ok
(
hr
==
E_UNEXPECTED
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_AddCheckButton
(
pfdc
,
++
i
,
checkbutton1W
,
TRUE
);
ok
(
hr
==
S_OK
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_AddEditBox
(
pfdc
,
i
,
label
);
ok
(
hr
==
E_UNEXPECTED
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_AddEditBox
(
pfdc
,
++
i
,
editbox1W
);
ok
(
hr
==
S_OK
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_AddSeparator
(
pfdc
,
i
);
ok
(
hr
==
E_UNEXPECTED
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_AddSeparator
(
pfdc
,
++
i
);
ok
(
hr
==
S_OK
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_AddText
(
pfdc
,
i
,
label
);
ok
(
hr
==
E_UNEXPECTED
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_AddText
(
pfdc
,
++
i
,
textW
);
ok
(
hr
==
S_OK
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_StartVisualGroup
(
pfdc
,
i
,
label
);
todo_wine
ok
(
hr
==
E_UNEXPECTED
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_StartVisualGroup
(
pfdc
,
++
i
,
visualgroup1W
);
todo_wine
ok
(
hr
==
S_OK
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_StartVisualGroup
(
pfdc
,
++
i
,
label
);
todo_wine
ok
(
hr
==
E_UNEXPECTED
,
"got 0x%08x.
\n
"
,
hr
);
hr
=
IFileDialogCustomize_EndVisualGroup
(
pfdc
);
todo_wine
ok
(
hr
==
S_OK
,
"got 0x%08x.
\n
"
,
hr
);
IFileDialogCustomize_Release
(
pfdc
);
ref
=
IFileOpenDialog_Release
(
pfod
);
ok
(
!
ref
,
"Refcount not zero (%d).
\n
"
,
ref
);
...
...
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