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

Side by Side Diff: apps/shell/browser/shell_extensions_browser_client.h

Issue 184853012: Reland: Add ExtensionsApiClient interface, use it in the storage API SettingsFrontend (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase (api_client) Created 6 years, 9 months 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
« no previous file with comments | « no previous file | apps/shell/browser/shell_extensions_browser_client.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 APPS_SHELL_BROWSER_SHELL_EXTENSIONS_BROWSER_CLIENT_H_ 5 #ifndef APPS_SHELL_BROWSER_SHELL_EXTENSIONS_BROWSER_CLIENT_H_
6 #define APPS_SHELL_BROWSER_SHELL_EXTENSIONS_BROWSER_CLIENT_H_ 6 #define APPS_SHELL_BROWSER_SHELL_EXTENSIONS_BROWSER_CLIENT_H_
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "extensions/browser/extensions_browser_client.h" 9 #include "extensions/browser/extensions_browser_client.h"
10 10
11 class PrefService; 11 class PrefService;
12 12
13 namespace extensions { 13 namespace extensions {
14 14
15 class ExtensionsAPIClient;
16
15 // An ExtensionsBrowserClient that supports a single content::BrowserContent 17 // An ExtensionsBrowserClient that supports a single content::BrowserContent
16 // with no related incognito context. 18 // with no related incognito context.
17 class ShellExtensionsBrowserClient : public ExtensionsBrowserClient { 19 class ShellExtensionsBrowserClient : public ExtensionsBrowserClient {
18 public: 20 public:
19 // |context| is the single BrowserContext used for IsValidContext() below. 21 // |context| is the single BrowserContext used for IsValidContext() below.
20 explicit ShellExtensionsBrowserClient(content::BrowserContext* context); 22 explicit ShellExtensionsBrowserClient(content::BrowserContext* context);
21 virtual ~ShellExtensionsBrowserClient(); 23 virtual ~ShellExtensionsBrowserClient();
22 24
23 // ExtensionsBrowserClient overrides: 25 // ExtensionsBrowserClient overrides:
24 virtual bool IsShuttingDown() OVERRIDE; 26 virtual bool IsShuttingDown() OVERRIDE;
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 virtual ApiActivityMonitor* GetApiActivityMonitor( 60 virtual ApiActivityMonitor* GetApiActivityMonitor(
59 content::BrowserContext* context) OVERRIDE; 61 content::BrowserContext* context) OVERRIDE;
60 virtual ExtensionSystemProvider* GetExtensionSystemFactory() OVERRIDE; 62 virtual ExtensionSystemProvider* GetExtensionSystemFactory() OVERRIDE;
61 virtual void RegisterExtensionFunctions( 63 virtual void RegisterExtensionFunctions(
62 ExtensionFunctionRegistry* registry) const OVERRIDE; 64 ExtensionFunctionRegistry* registry) const OVERRIDE;
63 65
64 private: 66 private:
65 // The single BrowserContext for app_shell. Not owned. 67 // The single BrowserContext for app_shell. Not owned.
66 content::BrowserContext* browser_context_; 68 content::BrowserContext* browser_context_;
67 69
70 // Support for extension APIs.
71 scoped_ptr<ExtensionsAPIClient> api_client_;
72
68 // The PrefService for |browser_context_|. 73 // The PrefService for |browser_context_|.
69 scoped_ptr<PrefService> prefs_; 74 scoped_ptr<PrefService> prefs_;
70 75
71 DISALLOW_COPY_AND_ASSIGN(ShellExtensionsBrowserClient); 76 DISALLOW_COPY_AND_ASSIGN(ShellExtensionsBrowserClient);
72 }; 77 };
73 78
74 } // namespace extensions 79 } // namespace extensions
75 80
76 #endif // APPS_SHELL_BROWSER_SHELL_EXTENSIONS_BROWSER_CLIENT_H_ 81 #endif // APPS_SHELL_BROWSER_SHELL_EXTENSIONS_BROWSER_CLIENT_H_
OLDNEW
« no previous file with comments | « no previous file | apps/shell/browser/shell_extensions_browser_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698