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
fd91013b
Commit
fd91013b
authored
Feb 02, 2005
by
Mike McCormack
Committed by
Alexandre Julliard
Feb 02, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add more dialog controls, do something when they're clicked on.
parent
ac643d31
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
59 additions
and
10 deletions
+59
-10
dialog.c
dlls/msi/dialog.c
+0
-0
msipriv.h
dlls/msi/msipriv.h
+16
-7
msiquery.c
dlls/msi/msiquery.c
+34
-0
package.c
dlls/msi/package.c
+4
-0
preview.c
dlls/msi/preview.c
+5
-3
No files found.
dlls/msi/dialog.c
View file @
fd91013b
This diff is collapsed.
Click to expand it.
dlls/msi/msipriv.h
View file @
fd91013b
...
...
@@ -182,6 +182,9 @@ struct tagMSIVIEW
MSIVIEWOPS
*
ops
;
};
struct
msi_dialog_tag
;
typedef
struct
msi_dialog_tag
msi_dialog
;
typedef
struct
tagMSIPACKAGE
{
MSIOBJECTHDR
hdr
;
...
...
@@ -209,16 +212,15 @@ typedef struct tagMSIPACKAGE
LPWSTR
PackagePath
;
UINT
CurrentInstallState
;
msi_dialog
*
dialog
;
LPWSTR
next_dialog
;
}
MSIPACKAGE
;
struct
tag_dialog_info
;
typedef
struct
tag_dialog_info
dialog_info
;
typedef
struct
tagMSIPREVIEW
{
MSIOBJECTHDR
hdr
;
MSIPACKAGE
*
package
;
dialog_info
*
dialog
;
msi_dialog
*
dialog
;
}
MSIPREVIEW
;
#define MSIHANDLETYPE_ANY 0
...
...
@@ -299,6 +301,7 @@ extern UINT read_raw_stream_data( MSIDATABASE*, LPCWSTR stname,
/* action internals */
extern
UINT
ACTION_DoTopLevelINSTALL
(
MSIPACKAGE
*
,
LPCWSTR
,
LPCWSTR
);
extern
void
ACTION_free_package_structures
(
MSIPACKAGE
*
);
extern
UINT
ACTION_DialogBox
(
MSIPACKAGE
*
,
LPCWSTR
);
/* record internals */
extern
UINT
MSI_RecordSetIStream
(
MSIRECORD
*
,
unsigned
int
,
IStream
*
);
...
...
@@ -322,6 +325,8 @@ extern void enum_stream_names( IStorage *stg );
extern
UINT
MSI_OpenDatabaseW
(
LPCWSTR
,
LPCWSTR
,
MSIDATABASE
**
);
extern
UINT
MSI_DatabaseOpenViewW
(
MSIDATABASE
*
,
LPCWSTR
,
MSIQUERY
**
);
extern
UINT
MSI_OpenQuery
(
MSIDATABASE
*
,
MSIQUERY
**
,
LPCWSTR
,
...
);
typedef
UINT
(
*
record_func
)(
MSIRECORD
*
rec
,
LPVOID
param
);
extern
UINT
MSI_IterateRecords
(
MSIQUERY
*
,
DWORD
*
,
record_func
,
LPVOID
);
/* view internals */
extern
UINT
MSI_ViewExecute
(
MSIQUERY
*
,
MSIRECORD
*
);
...
...
@@ -359,9 +364,13 @@ extern UINT MSIREG_OpenProductsKey(LPCWSTR szProduct, HKEY* key, BOOL create);
extern
UINT
MSIREG_OpenUserFeaturesKey
(
LPCWSTR
szProduct
,
HKEY
*
key
,
BOOL
create
);
/* msi dialog interface */
typedef
VOID
(
*
msi_dialog_event_handler
)(
MSIPACKAGE
*
,
LPCWSTR
,
LPCWSTR
,
HWND
);
extern
dialog_info
*
msi_dialog_create
(
MSIPACKAGE
*
,
LPCWSTR
,
msi_dialog_event_handler
);
extern
void
msi_dialog_destroy
(
dialog_info
*
);
typedef
VOID
(
*
msi_dialog_event_handler
)(
MSIPACKAGE
*
,
LPCWSTR
,
LPCWSTR
,
msi_dialog
*
);
extern
msi_dialog
*
msi_dialog_create
(
MSIPACKAGE
*
,
LPCWSTR
,
msi_dialog_event_handler
);
extern
UINT
msi_dialog_run_message_loop
(
msi_dialog
*
);
extern
void
msi_dialog_end_dialog
(
msi_dialog
*
);
extern
void
msi_dialog_check_messages
(
msi_dialog
*
);
extern
void
msi_dialog_do_preview
(
msi_dialog
*
);
extern
void
msi_dialog_destroy
(
msi_dialog
*
);
extern
void
msi_dialog_register_class
(
void
);
extern
void
msi_dialog_unregister_class
(
void
);
...
...
dlls/msi/msiquery.c
View file @
fd91013b
...
...
@@ -182,6 +182,40 @@ UINT MSI_OpenQuery( MSIDATABASE *db, MSIQUERY **view, LPCWSTR fmt, ... )
return
rc
;
}
UINT
MSI_IterateRecords
(
MSIQUERY
*
view
,
DWORD
*
count
,
record_func
func
,
LPVOID
param
)
{
MSIRECORD
*
rec
=
NULL
;
UINT
r
,
n
=
0
,
max
=
0
;
r
=
MSI_ViewExecute
(
view
,
NULL
);
if
(
r
!=
ERROR_SUCCESS
)
return
r
;
if
(
count
)
max
=
*
count
;
/* iterate a query */
for
(
n
=
0
;
(
max
==
0
)
||
(
n
<
max
);
n
++
)
{
r
=
MSI_ViewFetch
(
view
,
&
rec
);
if
(
r
!=
ERROR_SUCCESS
)
break
;
r
=
func
(
rec
,
param
);
msiobj_release
(
&
rec
->
hdr
);
if
(
r
!=
ERROR_SUCCESS
)
break
;
n
++
;
}
MSI_ViewClose
(
view
);
if
(
count
)
*
count
=
n
;
return
r
;
}
UINT
WINAPI
MsiDatabaseOpenViewW
(
MSIHANDLE
hdb
,
LPCWSTR
szQuery
,
MSIHANDLE
*
phView
)
{
...
...
dlls/msi/package.c
View file @
fd91013b
...
...
@@ -53,6 +53,8 @@ void MSI_FreePackage( MSIOBJECTHDR *arg)
{
MSIPACKAGE
*
package
=
(
MSIPACKAGE
*
)
arg
;
if
(
package
->
dialog
)
msi_dialog_destroy
(
package
->
dialog
);
ACTION_free_package_structures
(
package
);
msiobj_release
(
&
package
->
db
->
hdr
);
...
...
@@ -378,6 +380,8 @@ MSIPACKAGE *MSI_CreatePackage( MSIDATABASE *db )
package
->
loaded_files
=
0
;
package
->
ActionFormat
=
NULL
;
package
->
LastAction
=
NULL
;
package
->
dialog
=
NULL
;
package
->
next_dialog
=
NULL
;
/* OK, here is where we do a slew of things to the database to
* prep for all that is to come as a package */
...
...
dlls/msi/preview.c
View file @
fd91013b
...
...
@@ -82,7 +82,7 @@ UINT WINAPI MsiEnableUIPreview( MSIHANDLE hdb, MSIHANDLE* phPreview )
}
static
VOID
preview_event_handler
(
MSIPACKAGE
*
package
,
LPCWSTR
event
,
LPCWSTR
argument
,
HWND
dialog
)
LPCWSTR
argument
,
msi_dialog
*
dialog
)
{
MESSAGE
(
"Preview dialog event '%s' (arg='%s')
\n
"
,
debugstr_w
(
event
),
debugstr_w
(
argument
));
...
...
@@ -90,7 +90,7 @@ static VOID preview_event_handler( MSIPACKAGE *package, LPCWSTR event,
UINT
MSI_PreviewDialogW
(
MSIPREVIEW
*
preview
,
LPCWSTR
szDialogName
)
{
dialog_info
*
dialog
=
NULL
;
msi_dialog
*
dialog
=
NULL
;
UINT
r
=
ERROR_SUCCESS
;
if
(
preview
->
dialog
)
...
...
@@ -101,7 +101,9 @@ UINT MSI_PreviewDialogW( MSIPREVIEW *preview, LPCWSTR szDialogName )
{
dialog
=
msi_dialog_create
(
preview
->
package
,
szDialogName
,
preview_event_handler
);
if
(
!
dialog
)
if
(
dialog
)
msi_dialog_do_preview
(
dialog
);
else
r
=
ERROR_FUNCTION_FAILED
;
}
preview
->
dialog
=
dialog
;
...
...
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