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

Side by Side Diff: chrome/browser/automation/automation_provider.cc

Issue 4687005: Track permissions granted to extensions in prefs (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: missed updating a method call Created 10 years, 1 month 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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/automation/automation_provider.h" 5 #include "chrome/browser/automation/automation_provider.h"
6 6
7 #include <set> 7 #include <set>
8 8
9 #include "app/message_box_flags.h" 9 #include "app/message_box_flags.h"
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 751 matching lines...) Expand 10 before | Expand all | Expand 10 after
762 // The observer will delete itself when done. 762 // The observer will delete itself when done.
763 new ExtensionInstallNotificationObserver(this, 763 new ExtensionInstallNotificationObserver(this,
764 AutomationMsg_InstallExtension::ID, 764 AutomationMsg_InstallExtension::ID,
765 reply_message); 765 reply_message);
766 766
767 const FilePath& install_dir = service->install_directory(); 767 const FilePath& install_dir = service->install_directory();
768 scoped_refptr<CrxInstaller> installer( 768 scoped_refptr<CrxInstaller> installer(
769 new CrxInstaller(install_dir, 769 new CrxInstaller(install_dir,
770 service, 770 service,
771 NULL)); // silent install, no UI 771 NULL)); // silent install, no UI
772 installer->set_allow_privilege_increase(true);
773 installer->InstallCrx(crx_path); 772 installer->InstallCrx(crx_path);
774 } else { 773 } else {
775 AutomationMsg_InstallExtension::WriteReplyParams( 774 AutomationMsg_InstallExtension::WriteReplyParams(
776 reply_message, AUTOMATION_MSG_EXTENSION_INSTALL_FAILED); 775 reply_message, AUTOMATION_MSG_EXTENSION_INSTALL_FAILED);
777 Send(reply_message); 776 Send(reply_message);
778 } 777 }
779 } 778 }
780 779
781 void AutomationProvider::LoadExpandedExtension( 780 void AutomationProvider::LoadExpandedExtension(
782 const FilePath& extension_dir, 781 const FilePath& extension_dir,
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
834 this, 833 this,
835 AutomationMsg_InstallExtensionAndGetHandle::ID, 834 AutomationMsg_InstallExtensionAndGetHandle::ID,
836 reply_message); 835 reply_message);
837 836
838 ExtensionInstallUI* client = 837 ExtensionInstallUI* client =
839 (with_ui ? new ExtensionInstallUI(profile_) : NULL); 838 (with_ui ? new ExtensionInstallUI(profile_) : NULL);
840 scoped_refptr<CrxInstaller> installer( 839 scoped_refptr<CrxInstaller> installer(
841 new CrxInstaller(service->install_directory(), 840 new CrxInstaller(service->install_directory(),
842 service, 841 service,
843 client)); 842 client));
844 installer->set_allow_privilege_increase(true);
845 installer->InstallCrx(crx_path); 843 installer->InstallCrx(crx_path);
846 } else { 844 } else {
847 AutomationMsg_InstallExtensionAndGetHandle::WriteReplyParams( 845 AutomationMsg_InstallExtensionAndGetHandle::WriteReplyParams(
848 reply_message, 0); 846 reply_message, 0);
849 Send(reply_message); 847 Send(reply_message);
850 } 848 }
851 } 849 }
852 850
853 void AutomationProvider::UninstallExtension(int extension_handle, 851 void AutomationProvider::UninstallExtension(int extension_handle,
854 bool* success) { 852 bool* success) {
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
992 } 990 }
993 } 991 }
994 } 992 }
995 993
996 void AutomationProvider::SaveAsAsync(int tab_handle) { 994 void AutomationProvider::SaveAsAsync(int tab_handle) {
997 NavigationController* tab = NULL; 995 NavigationController* tab = NULL;
998 TabContents* tab_contents = GetTabContentsForHandle(tab_handle, &tab); 996 TabContents* tab_contents = GetTabContentsForHandle(tab_handle, &tab);
999 if (tab_contents) 997 if (tab_contents)
1000 tab_contents->OnSavePage(); 998 tab_contents->OnSavePage();
1001 } 999 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/download/download_util.cc » ('j') | chrome/browser/extensions/extensions_service.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698