mirror of
https://github.com/valinet/ExplorerPatcher.git
synced 2024-11-23 23:21:08 +01:00
GUI: Added "Uninstall" section containing a button to launch the uninstaller.
People asked "how to uninstall" so I think this might help.
This commit is contained in:
parent
0157ecc330
commit
0c5021b376
16
ep_gui/GUI.c
16
ep_gui/GUI.c
@ -2165,6 +2165,22 @@ static BOOL GUI_Build(HDC hDC, HWND hwnd, POINT pt)
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (!strncmp(line + 1, "uninstall", 6))
|
||||
{
|
||||
wchar_t uninstallLink[MAX_PATH];
|
||||
ZeroMemory(uninstallLink, sizeof(uninstallLink));
|
||||
SHGetFolderPathW(NULL, SPECIAL_FOLDER, NULL, SHGFP_TYPE_CURRENT, uninstallLink);
|
||||
wcscat_s(uninstallLink, MAX_PATH, _T(APP_RELATIVE_PATH) L"\\" _T(SETUP_UTILITY_NAME));
|
||||
|
||||
SHELLEXECUTEINFOW sei;
|
||||
ZeroMemory(&sei, sizeof(SHELLEXECUTEINFOW));
|
||||
sei.cbSize = sizeof(sei);
|
||||
sei.hwnd = hwnd;
|
||||
sei.lpFile = uninstallLink;
|
||||
sei.nShow = SW_NORMAL;
|
||||
sei.lpParameters = L"/uninstall";
|
||||
ShellExecuteExW(&sei);
|
||||
}
|
||||
else if (!strncmp(line + 1, "update_weather", 14))
|
||||
{
|
||||
PostMessageW(FindWindowW(_T(EPW_WEATHER_CLASSNAME), NULL), EP_WEATHER_WM_FETCH_DATA, 0, 0);
|
||||
|
@ -386,4 +386,7 @@
|
||||
#define IDS_ABOUT_EXPORT_SUCCESS 2014
|
||||
#define IDS_ABOUT_RESET 2015
|
||||
|
||||
#define IDS_FOOTER_RESTART 2101
|
||||
#define IDS_UNINSTALL 2101
|
||||
#define IDS_UNINSTALL_UNINSTALL 2102
|
||||
|
||||
#define IDS_FOOTER_RESTART 2201
|
||||
|
@ -430,5 +430,8 @@ BEGIN
|
||||
IDS_ABOUT_EXPORT_SUCCESS "Settings have been exported successfully."
|
||||
IDS_ABOUT_RESET "Restore default settings"
|
||||
|
||||
IDS_UNINSTALL "Uninstall"
|
||||
IDS_UNINSTALL_UNINSTALL "Uninstall ExplorerPatcher"
|
||||
|
||||
IDS_FOOTER_RESTART "Restart File Explorer"
|
||||
END
|
||||
|
@ -783,7 +783,12 @@
|
||||
;reset
|
||||
|
||||
|
||||
;T %R:2101%
|
||||
;u %R:2102%
|
||||
;uninstall
|
||||
|
||||
|
||||
|
||||
;f
|
||||
;u %R:2101% (*)
|
||||
;u %R:2201% (*)
|
||||
;restart
|
||||
|
@ -603,7 +603,12 @@
|
||||
;reset
|
||||
|
||||
|
||||
;T %R:2101%
|
||||
;u %R:2102%
|
||||
;uninstall
|
||||
|
||||
|
||||
|
||||
;f
|
||||
;u %R:2101% (*)
|
||||
;u %R:2201% (*)
|
||||
;restart
|
||||
|
Loading…
Reference in New Issue
Block a user