| 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/extension_host.h" | 5 #include "chrome/browser/extensions/extension_host.h" |
| 6 | 6 |
| 7 #include <list> | 7 #include <list> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 644 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 655 } | 655 } |
| 656 | 656 |
| 657 content::JavaScriptDialogManager* ExtensionHost::GetJavaScriptDialogManager() { | 657 content::JavaScriptDialogManager* ExtensionHost::GetJavaScriptDialogManager() { |
| 658 if (!dialog_manager_) { | 658 if (!dialog_manager_) { |
| 659 dialog_manager_.reset(CreateJavaScriptDialogManagerInstance(this)); | 659 dialog_manager_.reset(CreateJavaScriptDialogManagerInstance(this)); |
| 660 } | 660 } |
| 661 return dialog_manager_.get(); | 661 return dialog_manager_.get(); |
| 662 } | 662 } |
| 663 | 663 |
| 664 content::ColorChooser* ExtensionHost::OpenColorChooser( | 664 content::ColorChooser* ExtensionHost::OpenColorChooser( |
| 665 WebContents* web_contents, SkColor initial_color) { | 665 WebContents* web_contents, |
| 666 SkColor initial_color, |
| 667 const std::vector<SkColor>& suggestions, |
| 668 const std::vector<string16>& suggestion_labels) { |
| 666 return chrome::ShowColorChooser(web_contents, initial_color); | 669 return chrome::ShowColorChooser(web_contents, initial_color); |
| 667 } | 670 } |
| 668 | 671 |
| 669 void ExtensionHost::RunFileChooser(WebContents* tab, | 672 void ExtensionHost::RunFileChooser(WebContents* tab, |
| 670 const content::FileChooserParams& params) { | 673 const content::FileChooserParams& params) { |
| 671 FileSelectHelper::RunFileChooser(tab, params); | 674 FileSelectHelper::RunFileChooser(tab, params); |
| 672 } | 675 } |
| 673 | 676 |
| 674 void ExtensionHost::AddNewContents(WebContents* source, | 677 void ExtensionHost::AddNewContents(WebContents* source, |
| 675 WebContents* new_contents, | 678 WebContents* new_contents, |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 713 | 716 |
| 714 void ExtensionHost::RequestMediaAccessPermission( | 717 void ExtensionHost::RequestMediaAccessPermission( |
| 715 content::WebContents* web_contents, | 718 content::WebContents* web_contents, |
| 716 const content::MediaStreamRequest& request, | 719 const content::MediaStreamRequest& request, |
| 717 const content::MediaResponseCallback& callback) { | 720 const content::MediaResponseCallback& callback) { |
| 718 MediaCaptureDevicesDispatcher::GetInstance()->ProcessMediaAccessRequest( | 721 MediaCaptureDevicesDispatcher::GetInstance()->ProcessMediaAccessRequest( |
| 719 web_contents, request, callback, extension()); | 722 web_contents, request, callback, extension()); |
| 720 } | 723 } |
| 721 | 724 |
| 722 } // namespace extensions | 725 } // namespace extensions |
| OLD | NEW |