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

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

Issue 171523005: BACKUP: NativeAppWindowView - before splitting CL (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 10 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
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_EXTENSION_SYSTEM_H_ 5 #ifndef APPS_SHELL_BROWSER_SHELL_EXTENSION_SYSTEM_H_
6 #define APPS_SHELL_BROWSER_SHELL_EXTENSION_SYSTEM_H_ 6 #define APPS_SHELL_BROWSER_SHELL_EXTENSION_SYSTEM_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 22 matching lines...) Expand all
33 // app_shell to skip initialization of services it doesn't need. 33 // app_shell to skip initialization of services it doesn't need.
34 class ShellExtensionSystem : public ExtensionSystem { 34 class ShellExtensionSystem : public ExtensionSystem {
35 public: 35 public:
36 explicit ShellExtensionSystem(content::BrowserContext* browser_context); 36 explicit ShellExtensionSystem(content::BrowserContext* browser_context);
37 virtual ~ShellExtensionSystem(); 37 virtual ~ShellExtensionSystem();
38 38
39 // Loads an unpacked application from a directory and attempts to launch it. 39 // Loads an unpacked application from a directory and attempts to launch it.
40 // Returns true on success. 40 // Returns true on success.
41 bool LoadAndLaunchApp(const base::FilePath& app_dir); 41 bool LoadAndLaunchApp(const base::FilePath& app_dir);
42 42
43 // Closes the running app.
44 void CloseApp();
45
43 // BrowserContextKeyedService implementation: 46 // BrowserContextKeyedService implementation:
44 virtual void Shutdown() OVERRIDE; 47 virtual void Shutdown() OVERRIDE;
45 48
46 // ExtensionSystem implementation: 49 // ExtensionSystem implementation:
47 virtual void InitForRegularProfile(bool extensions_enabled) OVERRIDE; 50 virtual void InitForRegularProfile(bool extensions_enabled) OVERRIDE;
48 virtual ExtensionService* extension_service() OVERRIDE; 51 virtual ExtensionService* extension_service() OVERRIDE;
49 virtual RuntimeData* runtime_data() OVERRIDE; 52 virtual RuntimeData* runtime_data() OVERRIDE;
50 virtual ManagementPolicy* management_policy() OVERRIDE; 53 virtual ManagementPolicy* management_policy() OVERRIDE;
51 virtual UserScriptMaster* user_script_master() OVERRIDE; 54 virtual UserScriptMaster* user_script_master() OVERRIDE;
52 virtual ProcessManager* process_manager() OVERRIDE; 55 virtual ProcessManager* process_manager() OVERRIDE;
(...skipping 11 matching lines...) Expand all
64 virtual void RegisterExtensionWithRequestContexts( 67 virtual void RegisterExtensionWithRequestContexts(
65 const Extension* extension) OVERRIDE; 68 const Extension* extension) OVERRIDE;
66 virtual void UnregisterExtensionWithRequestContexts( 69 virtual void UnregisterExtensionWithRequestContexts(
67 const std::string& extension_id, 70 const std::string& extension_id,
68 const UnloadedExtensionInfo::Reason reason) OVERRIDE; 71 const UnloadedExtensionInfo::Reason reason) OVERRIDE;
69 virtual const OneShotEvent& ready() const OVERRIDE; 72 virtual const OneShotEvent& ready() const OVERRIDE;
70 73
71 private: 74 private:
72 content::BrowserContext* browser_context_; // Not owned. 75 content::BrowserContext* browser_context_; // Not owned.
73 76
77 // Extension ID for the app.
78 std::string app_id_;
79
74 // Data to be accessed on the IO thread. Must outlive process_manager_. 80 // Data to be accessed on the IO thread. Must outlive process_manager_.
75 scoped_refptr<InfoMap> info_map_; 81 scoped_refptr<InfoMap> info_map_;
76 82
77 scoped_ptr<RuntimeData> runtime_data_; 83 scoped_ptr<RuntimeData> runtime_data_;
78 scoped_ptr<LazyBackgroundTaskQueue> lazy_background_task_queue_; 84 scoped_ptr<LazyBackgroundTaskQueue> lazy_background_task_queue_;
79 scoped_ptr<EventRouter> event_router_; 85 scoped_ptr<EventRouter> event_router_;
80 scoped_ptr<ProcessManager> process_manager_; 86 scoped_ptr<ProcessManager> process_manager_;
81 scoped_ptr<QuotaService> quota_service_; 87 scoped_ptr<QuotaService> quota_service_;
82 88
83 // Signaled when the extension system has completed its startup tasks. 89 // Signaled when the extension system has completed its startup tasks.
84 OneShotEvent ready_; 90 OneShotEvent ready_;
85 91
86 DISALLOW_COPY_AND_ASSIGN(ShellExtensionSystem); 92 DISALLOW_COPY_AND_ASSIGN(ShellExtensionSystem);
87 }; 93 };
88 94
89 } // namespace extensions 95 } // namespace extensions
90 96
91 #endif // APPS_SHELL_BROWSER_SHELL_EXTENSION_SYSTEM_H_ 97 #endif // APPS_SHELL_BROWSER_SHELL_EXTENSION_SYSTEM_H_
OLDNEW
« no previous file with comments | « apps/shell/browser/shell_browser_main_parts.cc ('k') | apps/shell/browser/shell_extension_system.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698