From 6d102168919c46c69e7620b5ada6994866dd552c Mon Sep 17 00:00:00 2001 From: Hans Leidekker Date: Fri, 24 Dec 2010 15:32:01 +0100 Subject: [PATCH] msi: Change ACTION_UpdateComponentStates to take a feature pointer. --- dlls/msi/dialog.c | 2 +- dlls/msi/helpers.c | 7 +------ dlls/msi/install.c | 2 +- dlls/msi/msipriv.h | 2 +- 4 files changed, 4 insertions(+), 9 deletions(-) diff --git a/dlls/msi/dialog.c b/dlls/msi/dialog.c index b8330704ccb..ce904187e10 100644 --- a/dlls/msi/dialog.c +++ b/dlls/msi/dialog.c @@ -2127,7 +2127,7 @@ msi_seltree_update_feature_installstate( HWND hwnd, HTREEITEM hItem, { msi_feature_set_state( package, feature, state ); msi_seltree_sync_item_state( hwnd, feature, hItem ); - ACTION_UpdateComponentStates( package, feature->Feature ); + ACTION_UpdateComponentStates( package, feature ); } static void diff --git a/dlls/msi/helpers.c b/dlls/msi/helpers.c index ec8db475376..df5d44892a1 100644 --- a/dlls/msi/helpers.c +++ b/dlls/msi/helpers.c @@ -639,16 +639,11 @@ LPWSTR create_component_advertise_string(MSIPACKAGE* package, } /* update component state based on a feature change */ -void ACTION_UpdateComponentStates(MSIPACKAGE *package, LPCWSTR szFeature) +void ACTION_UpdateComponentStates( MSIPACKAGE *package, MSIFEATURE *feature ) { INSTALLSTATE newstate; - MSIFEATURE *feature; ComponentList *cl; - feature = get_loaded_feature(package,szFeature); - if (!feature) - return; - newstate = feature->ActionRequest; if (newstate == INSTALLSTATE_ABSENT) diff --git a/dlls/msi/install.c b/dlls/msi/install.c index d34de8c4993..338ef0a00c9 100644 --- a/dlls/msi/install.c +++ b/dlls/msi/install.c @@ -827,7 +827,7 @@ UINT WINAPI MSI_SetFeatureStateW(MSIPACKAGE* package, LPCWSTR szFeature, feature->ActionRequest = iState; - ACTION_UpdateComponentStates(package,szFeature); + ACTION_UpdateComponentStates( package, feature ); /* update all the features that are children of this feature */ LIST_FOR_EACH_ENTRY( child, &package->features, MSIFEATURE, entry ) diff --git a/dlls/msi/msipriv.h b/dlls/msi/msipriv.h index 4429fc1fd56..10ddb4e8c54 100644 --- a/dlls/msi/msipriv.h +++ b/dlls/msi/msipriv.h @@ -945,7 +945,7 @@ extern LPWSTR build_directory_name(DWORD , ...); extern BOOL create_full_pathW(const WCHAR *path); extern void reduce_to_longfilename(WCHAR*); extern LPWSTR create_component_advertise_string(MSIPACKAGE*, MSICOMPONENT*, LPCWSTR); -extern void ACTION_UpdateComponentStates(MSIPACKAGE *package, LPCWSTR szFeature); +extern void ACTION_UpdateComponentStates(MSIPACKAGE *package, MSIFEATURE *feature); extern UINT register_unique_action(MSIPACKAGE *, LPCWSTR); extern BOOL check_unique_action(const MSIPACKAGE *, LPCWSTR); extern WCHAR* generate_error_string(MSIPACKAGE *, UINT, DWORD, ... ); -- 2.11.4.GIT