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

Side by Side Diff: extensions/browser/extension_registry.h

Issue 297263003: Optimize promotion of ephemeral apps (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 6 years, 6 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
« no previous file with comments | « extensions/browser/extension_prefs.cc ('k') | extensions/browser/extension_registry.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 EXTENSIONS_BROWSER_EXTENSION_REGISTRY_H_ 5 #ifndef EXTENSIONS_BROWSER_EXTENSION_REGISTRY_H_
6 #define EXTENSIONS_BROWSER_EXTENSION_REGISTRY_H_ 6 #define EXTENSIONS_BROWSER_EXTENSION_REGISTRY_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 71
72 // Invokes the observer method OnExtensionUnloaded(). The extension must not 72 // Invokes the observer method OnExtensionUnloaded(). The extension must not
73 // be enabled at the time of the call. 73 // be enabled at the time of the call.
74 void TriggerOnUnloaded(const Extension* extension, 74 void TriggerOnUnloaded(const Extension* extension,
75 UnloadedExtensionInfo::Reason reason); 75 UnloadedExtensionInfo::Reason reason);
76 76
77 // If this is a fresh install then |is_update| is false and there must not be 77 // If this is a fresh install then |is_update| is false and there must not be
78 // any installed extension with |extension|'s ID. If this is an update then 78 // any installed extension with |extension|'s ID. If this is an update then
79 // |is_update| is true and must be an installed extension with |extension|'s 79 // |is_update| is true and must be an installed extension with |extension|'s
80 // ID, and |old_name| must be non-empty. 80 // ID, and |old_name| must be non-empty.
81 // If true, |from_ephemeral| indicates that the extension was previously
82 // installed ephemerally and has been promoted to a regular installed
83 // extension. |is_update| should also be true.
81 void TriggerOnWillBeInstalled(const Extension* extension, 84 void TriggerOnWillBeInstalled(const Extension* extension,
82 bool is_update, 85 bool is_update,
86 bool from_ephemeral,
83 const std::string& old_name); 87 const std::string& old_name);
84 88
85 // Invokes the observer method OnExtensionUninstalled(). The extension must 89 // Invokes the observer method OnExtensionUninstalled(). The extension must
86 // not be any installed extension with |extension|'s ID. 90 // not be any installed extension with |extension|'s ID.
87 void TriggerOnUninstalled(const Extension* extension); 91 void TriggerOnUninstalled(const Extension* extension);
88 92
89 // Find an extension by ID using |include_mask| to pick the sets to search: 93 // Find an extension by ID using |include_mask| to pick the sets to search:
90 // * enabled_extensions() --> ExtensionRegistry::ENABLED 94 // * enabled_extensions() --> ExtensionRegistry::ENABLED
91 // * disabled_extensions() --> ExtensionRegistry::DISABLED 95 // * disabled_extensions() --> ExtensionRegistry::DISABLED
92 // * terminated_extensions() --> ExtensionRegistry::TERMINATED 96 // * terminated_extensions() --> ExtensionRegistry::TERMINATED
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
151 ObserverList<ExtensionRegistryObserver> observers_; 155 ObserverList<ExtensionRegistryObserver> observers_;
152 156
153 content::BrowserContext* const browser_context_; 157 content::BrowserContext* const browser_context_;
154 158
155 DISALLOW_COPY_AND_ASSIGN(ExtensionRegistry); 159 DISALLOW_COPY_AND_ASSIGN(ExtensionRegistry);
156 }; 160 };
157 161
158 } // namespace extensions 162 } // namespace extensions
159 163
160 #endif // EXTENSIONS_BROWSER_EXTENSION_REGISTRY_H_ 164 #endif // EXTENSIONS_BROWSER_EXTENSION_REGISTRY_H_
OLDNEW
« no previous file with comments | « extensions/browser/extension_prefs.cc ('k') | extensions/browser/extension_registry.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698