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_NACL_HOST_NACL_BROWSER_DELEGATE_IMPL_H_ | 5 #ifndef CHROME_BROWSER_NACL_HOST_NACL_BROWSER_DELEGATE_IMPL_H_ |
6 #define CHROME_BROWSER_NACL_HOST_NACL_BROWSER_DELEGATE_IMPL_H_ | 6 #define CHROME_BROWSER_NACL_HOST_NACL_BROWSER_DELEGATE_IMPL_H_ |
7 | 7 |
8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
9 #include "components/nacl/browser/nacl_browser_delegate.h" | 9 #include "components/nacl/browser/nacl_browser_delegate.h" |
10 #include "extensions/browser/info_map.h" | 10 #include "extensions/common/url_pattern.h" |
| 11 |
| 12 class ProfileManager; |
11 | 13 |
12 class NaClBrowserDelegateImpl : public NaClBrowserDelegate { | 14 class NaClBrowserDelegateImpl : public NaClBrowserDelegate { |
13 public: | 15 public: |
14 explicit NaClBrowserDelegateImpl(extensions::InfoMap* extension_info_map); | 16 explicit NaClBrowserDelegateImpl(ProfileManager* profile_manager); |
15 virtual ~NaClBrowserDelegateImpl(); | 17 virtual ~NaClBrowserDelegateImpl(); |
16 | 18 |
17 virtual void ShowMissingArchInfobar(int render_process_id, | 19 virtual void ShowMissingArchInfobar(int render_process_id, |
18 int render_view_id) OVERRIDE; | 20 int render_view_id) OVERRIDE; |
19 virtual bool DialogsAreSuppressed() OVERRIDE; | 21 virtual bool DialogsAreSuppressed() OVERRIDE; |
20 virtual bool GetCacheDirectory(base::FilePath* cache_dir) OVERRIDE; | 22 virtual bool GetCacheDirectory(base::FilePath* cache_dir) OVERRIDE; |
21 virtual bool GetPluginDirectory(base::FilePath* plugin_dir) OVERRIDE; | 23 virtual bool GetPluginDirectory(base::FilePath* plugin_dir) OVERRIDE; |
22 virtual bool GetPnaclDirectory(base::FilePath* pnacl_dir) OVERRIDE; | 24 virtual bool GetPnaclDirectory(base::FilePath* pnacl_dir) OVERRIDE; |
23 virtual bool GetUserDirectory(base::FilePath* user_dir) OVERRIDE; | 25 virtual bool GetUserDirectory(base::FilePath* user_dir) OVERRIDE; |
24 virtual std::string GetVersionString() const OVERRIDE; | 26 virtual std::string GetVersionString() const OVERRIDE; |
25 virtual ppapi::host::HostFactory* CreatePpapiHostFactory( | 27 virtual ppapi::host::HostFactory* CreatePpapiHostFactory( |
26 content::BrowserPpapiHost* ppapi_host) OVERRIDE; | 28 content::BrowserPpapiHost* ppapi_host) OVERRIDE; |
27 virtual bool MapUrlToLocalFilePath(const GURL& url, | 29 virtual bool MapUrlToLocalFilePath(const GURL& url, |
28 bool is_blocking, | 30 bool is_blocking, |
| 31 const base::FilePath& profile_directory, |
29 base::FilePath* file_path) OVERRIDE; | 32 base::FilePath* file_path) OVERRIDE; |
30 virtual void SetDebugPatterns(std::string debug_patterns) OVERRIDE; | 33 virtual void SetDebugPatterns(std::string debug_patterns) OVERRIDE; |
31 virtual bool URLMatchesDebugPatterns(const GURL& manifest_url) OVERRIDE; | 34 virtual bool URLMatchesDebugPatterns(const GURL& manifest_url) OVERRIDE; |
32 virtual content::BrowserPpapiHost::OnKeepaliveCallback | 35 virtual content::BrowserPpapiHost::OnKeepaliveCallback |
33 GetOnKeepaliveCallback() OVERRIDE; | 36 GetOnKeepaliveCallback() OVERRIDE; |
34 | 37 |
35 private: | 38 private: |
36 scoped_refptr<extensions::InfoMap> extension_info_map_; | 39 ProfileManager* profile_manager_; |
37 std::vector<URLPattern> debug_patterns_; | 40 std::vector<URLPattern> debug_patterns_; |
38 bool inverse_debug_patterns_; | 41 bool inverse_debug_patterns_; |
39 DISALLOW_COPY_AND_ASSIGN(NaClBrowserDelegateImpl); | 42 DISALLOW_COPY_AND_ASSIGN(NaClBrowserDelegateImpl); |
40 }; | 43 }; |
41 | 44 |
42 | 45 |
43 #endif // CHROME_BROWSER_NACL_HOST_NACL_BROWSER_DELEGATE_IMPL_H_ | 46 #endif // CHROME_BROWSER_NACL_HOST_NACL_BROWSER_DELEGATE_IMPL_H_ |
OLD | NEW |