mirror of
git://source.winehq.org/git/wine.git
synced 2024-09-06 14:40:53 +00:00
appwiz.cpl: Replace install_wine_gecko with configurable install_addon.
This commit is contained in:
parent
5779ce287a
commit
f25f97d86a
|
@ -84,7 +84,7 @@ static const addon_info_t addons_info[] = {
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
static const addon_info_t *addon = &addons_info[0];
|
static const addon_info_t *addon;
|
||||||
|
|
||||||
static HWND install_dialog = NULL;
|
static HWND install_dialog = NULL;
|
||||||
static LPWSTR url = NULL;
|
static LPWSTR url = NULL;
|
||||||
|
@ -553,18 +553,20 @@ static INT_PTR CALLBACK installer_proc(HWND hwnd, UINT msg, WPARAM wParam, LPARA
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
BOOL install_wine_gecko(void)
|
BOOL install_addon(addon_t addon_type)
|
||||||
{
|
{
|
||||||
if(!*ARCH_STRING)
|
if(!*ARCH_STRING)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
|
addon = addons_info+addon_type;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Try to find Gecko .cab file in following order:
|
* Try to find addon .msi file in following order:
|
||||||
* - directory stored in GeckoCabDir value of HKCU/Wine/Software/MSHTML key
|
* - directory stored in $dir_config_key value of HKCU/Wine/Software/$config_key key
|
||||||
* - $datadir/gecko/
|
* - $datadir/$addon_subdir/
|
||||||
* - $INSTALL_DATADIR/wine/gecko/
|
* - $INSTALL_DATADIR/wine/$addon_subdir/
|
||||||
* - /usr/share/wine/gecko/
|
* - /usr/share/wine/$addon_subdir/
|
||||||
* - download from URL stored in GeckoUrl value of HKCU/Wine/Software/MSHTML key
|
* - download from URL stored in $url_config_key value of HKCU/Wine/Software/$config_key key
|
||||||
*/
|
*/
|
||||||
if(!install_from_registered_dir()
|
if(!install_from_registered_dir()
|
||||||
&& !install_from_default_dir()
|
&& !install_from_default_dir()
|
||||||
|
|
|
@ -975,7 +975,7 @@ static LONG start_params(const WCHAR *params)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
if(!strcmpW(params, install_geckoW)) {
|
if(!strcmpW(params, install_geckoW)) {
|
||||||
install_wine_gecko();
|
install_addon(ADDON_GECKO);
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -16,7 +16,11 @@
|
||||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||||||
*/
|
*/
|
||||||
|
|
||||||
BOOL install_wine_gecko(void) DECLSPEC_HIDDEN;
|
typedef enum {
|
||||||
|
ADDON_GECKO
|
||||||
|
} addon_t;
|
||||||
|
|
||||||
|
BOOL install_addon(addon_t) DECLSPEC_HIDDEN;
|
||||||
|
|
||||||
extern HINSTANCE hInst DECLSPEC_HIDDEN;
|
extern HINSTANCE hInst DECLSPEC_HIDDEN;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue