OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #ifndef CHROME_BROWSER_EXTENSIONS_CHROME_EXTENSIONS_BROWSER_CLIENT_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_CHROME_EXTENSIONS_BROWSER_CLIENT_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_CHROME_EXTENSIONS_BROWSER_CLIENT_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_CHROME_EXTENSIONS_BROWSER_CLIENT_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 13 matching lines...) Expand all Loading... |
24 namespace content { | 24 namespace content { |
25 class BrowserContext; | 25 class BrowserContext; |
26 } | 26 } |
27 | 27 |
28 namespace extensions { | 28 namespace extensions { |
29 | 29 |
30 class ChromeComponentExtensionResourceManager; | 30 class ChromeComponentExtensionResourceManager; |
31 class ChromeExtensionsAPIClient; | 31 class ChromeExtensionsAPIClient; |
32 class ChromeProcessManagerDelegate; | 32 class ChromeProcessManagerDelegate; |
33 class ContentSettingsPrefsObserver; | 33 class ContentSettingsPrefsObserver; |
| 34 class ClipboardExtensionHelper; |
34 | 35 |
35 // Implementation of BrowserClient for Chrome, which includes | 36 // Implementation of BrowserClient for Chrome, which includes |
36 // knowledge of Profiles, BrowserContexts and incognito. | 37 // knowledge of Profiles, BrowserContexts and incognito. |
37 // | 38 // |
38 // NOTE: Methods that do not require knowledge of browser concepts should be | 39 // NOTE: Methods that do not require knowledge of browser concepts should be |
39 // implemented in ChromeExtensionsClient even if they are only used in the | 40 // implemented in ChromeExtensionsClient even if they are only used in the |
40 // browser process (see chrome/common/extensions/chrome_extensions_client.h). | 41 // browser process (see chrome/common/extensions/chrome_extensions_client.h). |
41 class ChromeExtensionsBrowserClient : public ExtensionsBrowserClient { | 42 class ChromeExtensionsBrowserClient : public ExtensionsBrowserClient { |
42 public: | 43 public: |
43 ChromeExtensionsBrowserClient(); | 44 ChromeExtensionsBrowserClient(); |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
99 void BroadcastEventToRenderers( | 100 void BroadcastEventToRenderers( |
100 events::HistogramValue histogram_value, | 101 events::HistogramValue histogram_value, |
101 const std::string& event_name, | 102 const std::string& event_name, |
102 std::unique_ptr<base::ListValue> args) override; | 103 std::unique_ptr<base::ListValue> args) override; |
103 net::NetLog* GetNetLog() override; | 104 net::NetLog* GetNetLog() override; |
104 ExtensionCache* GetExtensionCache() override; | 105 ExtensionCache* GetExtensionCache() override; |
105 bool IsBackgroundUpdateAllowed() override; | 106 bool IsBackgroundUpdateAllowed() override; |
106 bool IsMinBrowserVersionSupported(const std::string& min_version) override; | 107 bool IsMinBrowserVersionSupported(const std::string& min_version) override; |
107 ExtensionWebContentsObserver* GetExtensionWebContentsObserver( | 108 ExtensionWebContentsObserver* GetExtensionWebContentsObserver( |
108 content::WebContents* web_contents) override; | 109 content::WebContents* web_contents) override; |
| 110 void SaveImageDataToClipboard(const std::vector<char>& image_data, |
| 111 clipboard::ImageType type, |
| 112 const base::Closure& success_callback, |
| 113 const base::Closure& error_callback) override; |
109 void ReportError(content::BrowserContext* context, | 114 void ReportError(content::BrowserContext* context, |
110 std::unique_ptr<ExtensionError> error) override; | 115 std::unique_ptr<ExtensionError> error) override; |
111 void CleanUpWebView(content::BrowserContext* browser_context, | 116 void CleanUpWebView(content::BrowserContext* browser_context, |
112 int embedder_process_id, | 117 int embedder_process_id, |
113 int view_instance_id) override; | 118 int view_instance_id) override; |
114 void AttachExtensionTaskManagerTag(content::WebContents* web_contents, | 119 void AttachExtensionTaskManagerTag(content::WebContents* web_contents, |
115 ViewType view_type) override; | 120 ViewType view_type) override; |
116 scoped_refptr<update_client::UpdateClient> CreateUpdateClient( | 121 scoped_refptr<update_client::UpdateClient> CreateUpdateClient( |
117 content::BrowserContext* context) override; | 122 content::BrowserContext* context) override; |
118 std::unique_ptr<ExtensionApiFrameIdMapHelper> | 123 std::unique_ptr<ExtensionApiFrameIdMapHelper> |
(...skipping 13 matching lines...) Expand all Loading... |
132 // Support for ProcessManager. | 137 // Support for ProcessManager. |
133 std::unique_ptr<ChromeProcessManagerDelegate> process_manager_delegate_; | 138 std::unique_ptr<ChromeProcessManagerDelegate> process_manager_delegate_; |
134 | 139 |
135 // Client for API implementations. | 140 // Client for API implementations. |
136 std::unique_ptr<ChromeExtensionsAPIClient> api_client_; | 141 std::unique_ptr<ChromeExtensionsAPIClient> api_client_; |
137 | 142 |
138 std::unique_ptr<ChromeComponentExtensionResourceManager> resource_manager_; | 143 std::unique_ptr<ChromeComponentExtensionResourceManager> resource_manager_; |
139 | 144 |
140 std::unique_ptr<ExtensionCache> extension_cache_; | 145 std::unique_ptr<ExtensionCache> extension_cache_; |
141 | 146 |
| 147 std::unique_ptr<ClipboardExtensionHelper> clipboard_extension_helper_; |
| 148 |
142 std::unique_ptr<KioskDelegate> kiosk_delegate_; | 149 std::unique_ptr<KioskDelegate> kiosk_delegate_; |
143 | 150 |
144 DISALLOW_COPY_AND_ASSIGN(ChromeExtensionsBrowserClient); | 151 DISALLOW_COPY_AND_ASSIGN(ChromeExtensionsBrowserClient); |
145 }; | 152 }; |
146 | 153 |
147 } // namespace extensions | 154 } // namespace extensions |
148 | 155 |
149 #endif // CHROME_BROWSER_EXTENSIONS_CHROME_EXTENSIONS_BROWSER_CLIENT_H_ | 156 #endif // CHROME_BROWSER_EXTENSIONS_CHROME_EXTENSIONS_BROWSER_CLIENT_H_ |
OLD | NEW |