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

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

Issue 1308823002: Move Singleton and related structs to namespace base (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ToT Created 5 years, 3 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
1 // Copyright (c) 2014 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2014 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_EXTENSIONS_EXTENSION_ASSETS_MANAGER_CHROMEOS_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_ASSETS_MANAGER_CHROMEOS_H_
6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_ASSETS_MANAGER_CHROMEOS_H_ 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_ASSETS_MANAGER_CHROMEOS_H_
7 7
8 #include <map> 8 #include <map>
9 9
10 #include "chrome/browser/extensions/extension_assets_manager.h" 10 #include "chrome/browser/extensions/extension_assets_manager.h"
11 11
12 namespace base {
12 template <typename T> struct DefaultSingletonTraits; 13 template <typename T> struct DefaultSingletonTraits;
14 }
15
13 class PrefRegistrySimple; 16 class PrefRegistrySimple;
14 17
15 namespace base { 18 namespace base {
16 class DictionaryValue; 19 class DictionaryValue;
17 class SequencedTaskRunner; 20 class SequencedTaskRunner;
18 } 21 }
19 22
20 namespace extensions { 23 namespace extensions {
21 24
22 // Chrome OS specific implementation of assets manager that shares default apps 25 // Chrome OS specific implementation of assets manager that shares default apps
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 // Cleans up shared extensions list in preferences and returns list of 60 // Cleans up shared extensions list in preferences and returns list of
58 // extension IDs and version paths that are in use in |live_extension_paths|. 61 // extension IDs and version paths that are in use in |live_extension_paths|.
59 // Files on disk are not removed. Must be called on UI thread. 62 // Files on disk are not removed. Must be called on UI thread.
60 // Returns |false| in case of errors. 63 // Returns |false| in case of errors.
61 static bool CleanUpSharedExtensions( 64 static bool CleanUpSharedExtensions(
62 std::multimap<std::string, base::FilePath>* live_extension_paths); 65 std::multimap<std::string, base::FilePath>* live_extension_paths);
63 66
64 static void SetSharedInstallDirForTesting(const base::FilePath& install_dir); 67 static void SetSharedInstallDirForTesting(const base::FilePath& install_dir);
65 68
66 private: 69 private:
67 friend struct DefaultSingletonTraits<ExtensionAssetsManagerChromeOS>; 70 friend struct base::DefaultSingletonTraits<ExtensionAssetsManagerChromeOS>;
68 71
69 ExtensionAssetsManagerChromeOS(); 72 ExtensionAssetsManagerChromeOS();
70 ~ExtensionAssetsManagerChromeOS() override; 73 ~ExtensionAssetsManagerChromeOS() override;
71 74
72 // Should be called on UI thread to get associated file task runner for 75 // Should be called on UI thread to get associated file task runner for
73 // the profile. 76 // the profile.
74 static base::SequencedTaskRunner* GetFileTaskRunner(Profile* profile); 77 static base::SequencedTaskRunner* GetFileTaskRunner(Profile* profile);
75 78
76 // Return |true| if |extension| can be installed in a shared place for all 79 // Return |true| if |extension| can be installed in a shared place for all
77 // users on the device. 80 // users on the device.
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
121 const std::string& id, 124 const std::string& id,
122 base::DictionaryValue* extension_info, 125 base::DictionaryValue* extension_info,
123 std::multimap<std::string, base::FilePath>* live_extension_paths); 126 std::multimap<std::string, base::FilePath>* live_extension_paths);
124 127
125 DISALLOW_COPY_AND_ASSIGN(ExtensionAssetsManagerChromeOS); 128 DISALLOW_COPY_AND_ASSIGN(ExtensionAssetsManagerChromeOS);
126 }; 129 };
127 130
128 } // namespace extensions 131 } // namespace extensions
129 132
130 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_ASSETS_MANAGER_CHROMEOS_H_ 133 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_ASSETS_MANAGER_CHROMEOS_H_
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_assets_manager.cc ('k') | chrome/browser/extensions/extension_assets_manager_chromeos.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698