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

Side by Side Diff: chrome/installer/setup/uninstall.cc

Issue 21259: Fix bugs related to making Chrome default browser on Vista. (Closed)
Patch Set: after merge Created 11 years, 10 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 unified diff | Download patch
« no previous file with comments | « no previous file | chrome/installer/util/shell_util.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 // 4 //
5 // This file defines the methods useful for uninstalling Chrome. 5 // This file defines the methods useful for uninstalling Chrome.
6 6
7 #include "chrome/installer/setup/uninstall.h" 7 #include "chrome/installer/setup/uninstall.h"
8 8
9 #include "base/file_util.h" 9 #include "base/file_util.h"
10 #include "base/path_service.h" 10 #include "base/path_service.h"
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after
250 // Delete shared registry keys as well (these require admin rights) if 250 // Delete shared registry keys as well (these require admin rights) if
251 // remove_all option is specified. 251 // remove_all option is specified.
252 if (remove_all) { 252 if (remove_all) {
253 DeleteRegistryKey(hklm_key, set_access_key); 253 DeleteRegistryKey(hklm_key, set_access_key);
254 DeleteRegistryKey(hklm_key, html_prog_id); 254 DeleteRegistryKey(hklm_key, html_prog_id);
255 DeleteRegistryValue(HKEY_LOCAL_MACHINE, 255 DeleteRegistryValue(HKEY_LOCAL_MACHINE,
256 ShellUtil::kRegRegisteredApplications, 256 ShellUtil::kRegRegisteredApplications,
257 dist->GetApplicationName()); 257 dist->GetApplicationName());
258 258
259 // Delete the App Paths key that lets explorer find Chrome. 259 // Delete the App Paths key that lets explorer find Chrome.
260 DeleteRegistryKey(hklm_key, installer_util::kAppPathsRegistryKey); 260 std::wstring app_path_key(ShellUtil::kAppPathsRegistryKey);
261 file_util::AppendToPath(&app_path_key, installer_util::kChromeExe);
262 DeleteRegistryKey(hklm_key, app_path_key);
261 263
262 // Delete media player registry key that exists only in HKLM. 264 // Delete media player registry key that exists only in HKLM.
263 std::wstring reg_path(installer::kMediaPlayerRegPath); 265 std::wstring reg_path(installer::kMediaPlayerRegPath);
264 file_util::AppendToPath(&reg_path, installer_util::kChromeExe); 266 file_util::AppendToPath(&reg_path, installer_util::kChromeExe);
265 DeleteRegistryKey(hklm_key, reg_path); 267 DeleteRegistryKey(hklm_key, reg_path);
266 hklm_key.Close(); 268 hklm_key.Close();
267 } 269 }
268 270
269 // Finally delete all the files from Chrome folder after moving setup.exe 271 // Finally delete all the files from Chrome folder after moving setup.exe
270 // to a temp location. 272 // to a temp location.
271 if (!DeleteFilesAndFolders(exe_path, system_uninstall, installed_version)) 273 if (!DeleteFilesAndFolders(exe_path, system_uninstall, installed_version))
272 return installer_util::UNINSTALL_FAILED; 274 return installer_util::UNINSTALL_FAILED;
273 275
274 if (!force_uninstall) { 276 if (!force_uninstall) {
275 LOG(INFO) << "Uninstallation complete. Launching Uninstall survey."; 277 LOG(INFO) << "Uninstallation complete. Launching Uninstall survey.";
276 dist->DoPostUninstallOperations(installed_version); 278 dist->DoPostUninstallOperations(installed_version);
277 } 279 }
278 return installer_util::UNINSTALL_SUCCESSFUL; 280 return installer_util::UNINSTALL_SUCCESSFUL;
279 } 281 }
280 282
OLDNEW
« no previous file with comments | « no previous file | chrome/installer/util/shell_util.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698