Do not create uninstall shortcut in startmenu (#381)

Creating such a start menu entry is a leftover of the ancient Win 3.x time where there was no central control panel for removing programs.

Also see the Windows guidelines, where creating an uninstall shortcut is discouraged: https://msdn.microsoft.com/en-us/library/ms954377.aspx

Signed-off-by: Sven Strickroth <email@cs-ware.de>
This commit is contained in:
csware 2018-12-02 06:43:48 +01:00 committed by Mounir IDRASSI
parent e03068c372
commit e0049f601a
1 changed files with 0 additions and 18 deletions

View File

@ -1709,11 +1709,6 @@ BOOL DoShortcutsUninstall (HWND hwndDlg, wchar_t *szDestDir)
if (StatDeleteFile (szTmp2, FALSE) == FALSE)
goto error;
StringCbPrintfW (szTmp2, sizeof(szTmp2), L"%s%s", szLinkDir, L"\\Uninstall VeraCrypt.lnk");
RemoveMessage (hwndDlg, szTmp2);
if (StatDeleteFile (szTmp2, FALSE) == FALSE)
goto error;
StringCbPrintfW (szTmp2, sizeof(szTmp2), L"%s%s", szLinkDir, L"\\VeraCrypt User's Guide.lnk");
StatDeleteFile (szTmp2, FALSE);
@ -1823,19 +1818,6 @@ BOOL DoShortcutsInstall (HWND hwndDlg, wchar_t *szDestDir, BOOL bProgGroup, BOOL
else
goto error;
StringCbPrintfW (szTmp, sizeof(szTmp), L"%s%s", szDir, L"VeraCrypt Setup.exe");
StringCbPrintfW (szTmp2, sizeof(szTmp2), L"%s%s", szLinkDir, L"\\Uninstall VeraCrypt.lnk");
if (GetSystemDirectory (szTmp3, ARRAYSIZE(szTmp3)))
{
StringCbCatW (szTmp3, sizeof(szTmp3), L"\\control.exe");
}
else
StringCbCopyW(szTmp3, sizeof(szTmp3), L"C:\\Windows\\System32\\control.exe");
IconMessage (hwndDlg, szTmp2);
if (CreateLink (szTmp3, L"appwiz.cpl", szTmp2, szTmp, 0) != S_OK)
goto error;
StringCbPrintfW (szTmp2, sizeof(szTmp2), L"%s%s", szLinkDir, L"\\VeraCrypt User's Guide.lnk");
StatDeleteFile (szTmp2, FALSE);
}