OLD | NEW |
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/crx_installer.h" | 5 #include "chrome/browser/extensions/crx_installer.h" |
6 | 6 |
7 #include <map> | 7 #include <map> |
8 #include <set> | 8 #include <set> |
9 | 9 |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 542 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
553 // getting called in response to ExtensionInstallPrompt::ConfirmReEnable() | 553 // getting called in response to ExtensionInstallPrompt::ConfirmReEnable() |
554 // and if it is false, this function is called in response to | 554 // and if it is false, this function is called in response to |
555 // ExtensionInstallPrompt::ConfirmInstall(). | 555 // ExtensionInstallPrompt::ConfirmInstall(). |
556 if (!update_from_settings_page_) { | 556 if (!update_from_settings_page_) { |
557 std::string histogram_name = user_initiated ? | 557 std::string histogram_name = user_initiated ? |
558 "Extensions.Permissions_InstallCancel" : | 558 "Extensions.Permissions_InstallCancel" : |
559 "Extensions.Permissions_InstallAbort"; | 559 "Extensions.Permissions_InstallAbort"; |
560 ExtensionService::RecordPermissionMessagesHistogram( | 560 ExtensionService::RecordPermissionMessagesHistogram( |
561 extension(), histogram_name.c_str()); | 561 extension(), histogram_name.c_str()); |
562 | 562 |
563 // Kill the theme loading bubble. | |
564 content::NotificationService* service = | |
565 content::NotificationService::current(); | |
566 service->Notify(chrome::NOTIFICATION_NO_THEME_DETECTED, | |
567 content::Source<CrxInstaller>(this), | |
568 content::NotificationService::NoDetails()); | |
569 | |
570 NotifyCrxInstallComplete(false); | 563 NotifyCrxInstallComplete(false); |
571 } | 564 } |
572 | 565 |
573 Release(); // balanced in ConfirmInstall() or ConfirmReEnable(). | 566 Release(); // balanced in ConfirmInstall() or ConfirmReEnable(). |
574 | 567 |
575 // We're done. Since we don't post any more tasks to ourself, our ref count | 568 // We're done. Since we don't post any more tasks to ourself, our ref count |
576 // should go to zero and we die. The destructor will clean up the temp dir. | 569 // should go to zero and we die. The destructor will clean up the temp dir. |
577 } | 570 } |
578 | 571 |
579 void CrxInstaller::CompleteInstall() { | 572 void CrxInstaller::CompleteInstall() { |
(...skipping 207 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
787 if (!prefs->DidExtensionEscalatePermissions(extension()->id())) | 780 if (!prefs->DidExtensionEscalatePermissions(extension()->id())) |
788 return; | 781 return; |
789 | 782 |
790 if (client_) { | 783 if (client_) { |
791 AddRef(); // Balanced in InstallUIProceed() and InstallUIAbort(). | 784 AddRef(); // Balanced in InstallUIProceed() and InstallUIAbort(). |
792 client_->ConfirmReEnable(this, extension()); | 785 client_->ConfirmReEnable(this, extension()); |
793 } | 786 } |
794 } | 787 } |
795 | 788 |
796 } // namespace extensions | 789 } // namespace extensions |
OLD | NEW |