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

Side by Side Diff: chrome/browser/extensions/external_install_ui.cc

Issue 284103002: Replace "external_install" boolean parameter with explicit enumeration in ExtensionUninstall method. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 7 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #include "chrome/browser/extensions/external_install_ui.h" 5 #include "chrome/browser/extensions/external_install_ui.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/lazy_instance.h" 10 #include "base/lazy_instance.h"
(...skipping 324 matching lines...) Expand 10 before | Expand all | Expand 10 after
335 (extension = service_weak_->GetInstalledExtension(extension_id_))) { 335 (extension = service_weak_->GetInstalledExtension(extension_id_))) {
336 service_weak_->GrantPermissionsAndEnableExtension(extension); 336 service_weak_->GrantPermissionsAndEnableExtension(extension);
337 } 337 }
338 Release(); 338 Release();
339 } 339 }
340 340
341 void ExternalInstallDialogDelegate::InstallUIAbort(bool user_initiated) { 341 void ExternalInstallDialogDelegate::InstallUIAbort(bool user_initiated) {
342 const Extension* extension = NULL; 342 const Extension* extension = NULL;
343 if (service_weak_.get() && 343 if (service_weak_.get() &&
344 (extension = service_weak_->GetInstalledExtension(extension_id_))) { 344 (extension = service_weak_->GetInstalledExtension(extension_id_))) {
345 service_weak_->UninstallExtension(extension_id_, false, NULL); 345 service_weak_->UninstallExtension(
346 extension_id_, ExtensionService::kUninstallReasonDefault, NULL);
Devlin 2014/05/14 23:14:20 I don't think that external_install_ui and extensi
rpaquay 2014/06/30 23:16:18 Done.
346 } 347 }
347 Release(); 348 Release();
348 } 349 }
349 350
350 // ExternalInstallMenuAlert ------------------------------------------------- 351 // ExternalInstallMenuAlert -------------------------------------------------
351 352
352 ExternalInstallMenuAlert::ExternalInstallMenuAlert(ExtensionService* service, 353 ExternalInstallMenuAlert::ExternalInstallMenuAlert(ExtensionService* service,
353 const Extension* extension) 354 const Extension* extension)
354 : service_(service), 355 : service_(service),
355 extension_(extension), 356 extension_(extension),
(...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after
574 575
575 bool HasExternalInstallBubble(ExtensionService* service) { 576 bool HasExternalInstallBubble(ExtensionService* service) {
576 GlobalErrorService* error_service = 577 GlobalErrorService* error_service =
577 GlobalErrorServiceFactory::GetForProfile(service->profile()); 578 GlobalErrorServiceFactory::GetForProfile(service->profile());
578 GlobalError* error = error_service->GetGlobalErrorByMenuItemCommandID( 579 GlobalError* error = error_service->GetGlobalErrorByMenuItemCommandID(
579 kMenuCommandId); 580 kMenuCommandId);
580 return error && error->HasBubbleView(); 581 return error && error->HasBubbleView();
581 } 582 }
582 583
583 } // namespace extensions 584 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698