msi: Get rid of ACTION_VerifyFeatureForAction.
This commit is contained in:
parent
598c542607
commit
c32d9d7004
|
@ -2619,7 +2619,7 @@ static void ACTION_RefCountComponent( MSIPACKAGE* package, MSICOMPONENT *comp )
|
||||||
{
|
{
|
||||||
ComponentList *cl;
|
ComponentList *cl;
|
||||||
|
|
||||||
if (!ACTION_VerifyFeatureForAction( feature, INSTALLSTATE_LOCAL ))
|
if (feature->ActionRequest != INSTALLSTATE_LOCAL)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
LIST_FOR_EACH_ENTRY( cl, &feature->Components, ComponentList, entry )
|
LIST_FOR_EACH_ENTRY( cl, &feature->Components, ComponentList, entry )
|
||||||
|
@ -2634,7 +2634,7 @@ static void ACTION_RefCountComponent( MSIPACKAGE* package, MSICOMPONENT *comp )
|
||||||
{
|
{
|
||||||
ComponentList *cl;
|
ComponentList *cl;
|
||||||
|
|
||||||
if (!ACTION_VerifyFeatureForAction( feature, INSTALLSTATE_ABSENT ))
|
if (feature->ActionRequest != INSTALLSTATE_ABSENT)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
LIST_FOR_EACH_ENTRY( cl, &feature->Components, ComponentList, entry )
|
LIST_FOR_EACH_ENTRY( cl, &feature->Components, ComponentList, entry )
|
||||||
|
@ -3922,10 +3922,9 @@ static UINT ACTION_PublishFeatures(MSIPACKAGE *package)
|
||||||
BOOL absent = FALSE;
|
BOOL absent = FALSE;
|
||||||
MSIRECORD *uirow;
|
MSIRECORD *uirow;
|
||||||
|
|
||||||
if (!ACTION_VerifyFeatureForAction( feature, INSTALLSTATE_LOCAL ) &&
|
if (feature->ActionRequest != INSTALLSTATE_LOCAL &&
|
||||||
!ACTION_VerifyFeatureForAction( feature, INSTALLSTATE_SOURCE ) &&
|
feature->ActionRequest != INSTALLSTATE_SOURCE &&
|
||||||
!ACTION_VerifyFeatureForAction( feature, INSTALLSTATE_ADVERTISED ))
|
feature->ActionRequest != INSTALLSTATE_ADVERTISED) absent = TRUE;
|
||||||
absent = TRUE;
|
|
||||||
|
|
||||||
size = 1;
|
size = 1;
|
||||||
LIST_FOR_EACH_ENTRY( cl, &feature->Components, ComponentList, entry )
|
LIST_FOR_EACH_ENTRY( cl, &feature->Components, ComponentList, entry )
|
||||||
|
|
|
@ -809,16 +809,17 @@ UINT ACTION_RegisterClassInfo(MSIPACKAGE *package)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
feature = cls->Feature;
|
feature = cls->Feature;
|
||||||
|
if (!feature)
|
||||||
|
continue;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* MSDN says that these are based on Feature not on Component.
|
* MSDN says that these are based on Feature not on Component.
|
||||||
*/
|
*/
|
||||||
if (!ACTION_VerifyFeatureForAction( feature, INSTALLSTATE_LOCAL ) &&
|
if (feature->ActionRequest != INSTALLSTATE_LOCAL &&
|
||||||
!ACTION_VerifyFeatureForAction( feature, INSTALLSTATE_ADVERTISED ))
|
feature->ActionRequest != INSTALLSTATE_ADVERTISED )
|
||||||
{
|
{
|
||||||
TRACE("Skipping class %s reg due to disabled feature %s\n",
|
TRACE("Feature %s not scheduled for installation, skipping regstration of class %s\n",
|
||||||
debugstr_w(cls->clsid), debugstr_w(feature->Feature));
|
debugstr_w(feature->Feature), debugstr_w(cls->clsid));
|
||||||
|
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1142,18 +1143,18 @@ UINT ACTION_RegisterExtensionInfo(MSIPACKAGE *package)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
feature = ext->Feature;
|
feature = ext->Feature;
|
||||||
|
if (!feature)
|
||||||
|
continue;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* yes. MSDN says that these are based on _Feature_ not on
|
* yes. MSDN says that these are based on _Feature_ not on
|
||||||
* Component. So verify the feature is to be installed
|
* Component. So verify the feature is to be installed
|
||||||
*/
|
*/
|
||||||
if ((!ACTION_VerifyFeatureForAction( feature, INSTALLSTATE_LOCAL )) &&
|
if (feature->ActionRequest != INSTALLSTATE_LOCAL &&
|
||||||
!(install_on_demand &&
|
!(install_on_demand && feature->ActionRequest == INSTALLSTATE_ADVERTISED))
|
||||||
ACTION_VerifyFeatureForAction( feature, INSTALLSTATE_ADVERTISED )))
|
|
||||||
{
|
{
|
||||||
TRACE("Skipping extension %s reg due to disabled feature %s\n",
|
TRACE("Feature %s not scheduled for installation, skipping registration of extension %s\n",
|
||||||
debugstr_w(ext->Extension), debugstr_w(feature->Feature));
|
debugstr_w(feature->Feature), debugstr_w(ext->Extension));
|
||||||
|
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -604,17 +604,6 @@ void ui_actiondata(MSIPACKAGE *package, LPCWSTR action, MSIRECORD * record)
|
||||||
msiobj_release(&row->hdr);
|
msiobj_release(&row->hdr);
|
||||||
}
|
}
|
||||||
|
|
||||||
BOOL ACTION_VerifyFeatureForAction( const MSIFEATURE* feature, INSTALLSTATE check )
|
|
||||||
{
|
|
||||||
if (!feature)
|
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
if (feature->ActionRequest == check)
|
|
||||||
return TRUE;
|
|
||||||
else
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
void reduce_to_longfilename(WCHAR* filename)
|
void reduce_to_longfilename(WCHAR* filename)
|
||||||
{
|
{
|
||||||
LPWSTR p = strchrW(filename,'|');
|
LPWSTR p = strchrW(filename,'|');
|
||||||
|
|
|
@ -982,7 +982,6 @@ extern void msi_free_action_script(MSIPACKAGE *package, UINT script);
|
||||||
extern LPWSTR build_icon_path(MSIPACKAGE *, LPCWSTR);
|
extern LPWSTR build_icon_path(MSIPACKAGE *, LPCWSTR);
|
||||||
extern LPWSTR build_directory_name(DWORD , ...);
|
extern LPWSTR build_directory_name(DWORD , ...);
|
||||||
extern BOOL create_full_pathW(const WCHAR *path);
|
extern BOOL create_full_pathW(const WCHAR *path);
|
||||||
extern BOOL ACTION_VerifyFeatureForAction(const MSIFEATURE*, INSTALLSTATE);
|
|
||||||
extern void reduce_to_longfilename(WCHAR*);
|
extern void reduce_to_longfilename(WCHAR*);
|
||||||
extern LPWSTR create_component_advertise_string(MSIPACKAGE*, MSICOMPONENT*, LPCWSTR);
|
extern LPWSTR create_component_advertise_string(MSIPACKAGE*, MSICOMPONENT*, LPCWSTR);
|
||||||
extern void ACTION_UpdateComponentStates(MSIPACKAGE *package, LPCWSTR szFeature);
|
extern void ACTION_UpdateComponentStates(MSIPACKAGE *package, LPCWSTR szFeature);
|
||||||
|
|
Loading…
Reference in New Issue