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

Side by Side Diff: chrome/browser/extensions/install_delayer.h

Issue 1890163004: extensions: Abstract out install delay strategy (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_EXTENSIONS_INSTALL_DELAYER_H_
6 #define CHROME_BROWSER_EXTENSIONS_INSTALL_DELAYER_H_
7
8 namespace extensions {
9
10 class Extension;
11
12 // An interface that ExtensionService inquires for whether extension installs
13 // should be delayed and whether to finish/abort delayed installs.
14 class InstallDelayer {
15 public:
16 // Actions for a pending install.
17 enum Action {
18 INSTALL, // Proceed to finish the install.
19 DELAY, // Delay the install.
20 ABORT // Abort the install.
21 };
22
23 // Invoked by ExtensionService to check what to do with a pending install of
24 // the given extension. |extension| is an unpacked new extension to be
25 // installed. |install_immediately| is the flag associated with the install.
26 virtual Action GetDelayedInstallAction(const Extension* extension,
27 bool install_immediately) = 0;
28
29 protected:
30 virtual ~InstallDelayer() = default;
31 };
32
33 } // namespace extensions
34
35 #endif // CHROME_BROWSER_EXTENSIONS_INSTALL_DELAYER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698