Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5401)

Unified Diff: chrome/installer/setup/install.cc

Issue 1315233005: Revert "Reset the default browser choice on windows 10 on install" (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/installer/setup/install.cc
diff --git a/chrome/installer/setup/install.cc b/chrome/installer/setup/install.cc
index d972d43be3c5855b424157e486768528147eed8d..a076ca3a6efbd8ed4e23c021e2b10544f10d851c 100644
--- a/chrome/installer/setup/install.cc
+++ b/chrome/installer/setup/install.cc
@@ -41,6 +41,7 @@
#include "chrome/installer/util/work_item.h"
#include "chrome/installer/util/work_item_list.h"
+
namespace {
void LogShortcutOperation(ShellUtil::ShortcutLocation location,
@@ -250,28 +251,6 @@ installer::InstallStatus InstallNewVersion(
return installer::INSTALL_FAILED;
}
-bool CanResetDefaultBrowserIntentPicker() {
- return base::win::GetVersion() >= base::win::VERSION_WIN10;
-}
-
-void ResetDefaultBrowserIntentPicker() {
- static const wchar_t kUrlAssociationKeyFormat[] =
- L"SOFTWARE\\Microsoft\\Windows\\Shell\\Associations\\UrlAssociations\\"
- L"%ls\\UserChoice";
-
- if (ShellUtil::GetChromeDefaultState() != ShellUtil::IS_DEFAULT) {
- const base::string16 hash_value_name(L"Hash");
- InstallUtil::DeleteRegistryValue(
- HKEY_CURRENT_USER,
- base::StringPrintf(kUrlAssociationKeyFormat, L"http"), 0,
- hash_value_name);
- InstallUtil::DeleteRegistryValue(
- HKEY_CURRENT_USER,
- base::StringPrintf(kUrlAssociationKeyFormat, L"https"), 0,
- hash_value_name);
- }
-}
-
} // end namespace
namespace installer {
@@ -483,8 +462,6 @@ void RegisterChromeOnMachine(const installer::InstallerState& installer_state,
ShellUtil::MakeChromeDefault(dist, level, chrome_exe, true);
} else {
ShellUtil::RegisterChromeBrowser(dist, chrome_exe, base::string16(), false);
- if (make_chrome_default && CanResetDefaultBrowserIntentPicker())
- ResetDefaultBrowserIntentPicker();
}
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698