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

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

Issue 1871713002: Convert //chrome/browser/extensions from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase and fix header 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
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 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_ACTION_STORAGE_MANAGER_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_ACTION_STORAGE_MANAGER_H_
6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_ACTION_STORAGE_MANAGER_H_ 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_ACTION_STORAGE_MANAGER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 26 matching lines...) Expand all
37 content::WebContents* web_contents, 37 content::WebContents* web_contents,
38 content::BrowserContext* browser_context) override; 38 content::BrowserContext* browser_context) override;
39 void OnExtensionActionAPIShuttingDown() override; 39 void OnExtensionActionAPIShuttingDown() override;
40 40
41 // ExtensionRegistryObserver: 41 // ExtensionRegistryObserver:
42 void OnExtensionLoaded(content::BrowserContext* browser_context, 42 void OnExtensionLoaded(content::BrowserContext* browser_context,
43 const Extension* extension) override; 43 const Extension* extension) override;
44 44
45 // Reads/Writes the ExtensionAction's default values to/from storage. 45 // Reads/Writes the ExtensionAction's default values to/from storage.
46 void WriteToStorage(ExtensionAction* extension_action); 46 void WriteToStorage(ExtensionAction* extension_action);
47 void ReadFromStorage( 47 void ReadFromStorage(const std::string& extension_id,
48 const std::string& extension_id, scoped_ptr<base::Value> value); 48 std::unique_ptr<base::Value> value);
49 49
50 // Returns the Extensions StateStore for the |browser_context_|. 50 // Returns the Extensions StateStore for the |browser_context_|.
51 // May return NULL. 51 // May return NULL.
52 StateStore* GetStateStore(); 52 StateStore* GetStateStore();
53 53
54 content::BrowserContext* browser_context_; 54 content::BrowserContext* browser_context_;
55 55
56 ScopedObserver<ExtensionActionAPI, ExtensionActionAPI::Observer> 56 ScopedObserver<ExtensionActionAPI, ExtensionActionAPI::Observer>
57 extension_action_observer_; 57 extension_action_observer_;
58 58
59 ScopedObserver<ExtensionRegistry, ExtensionRegistryObserver> 59 ScopedObserver<ExtensionRegistry, ExtensionRegistryObserver>
60 extension_registry_observer_; 60 extension_registry_observer_;
61 61
62 base::WeakPtrFactory<ExtensionActionStorageManager> weak_factory_; 62 base::WeakPtrFactory<ExtensionActionStorageManager> weak_factory_;
63 63
64 DISALLOW_COPY_AND_ASSIGN(ExtensionActionStorageManager); 64 DISALLOW_COPY_AND_ASSIGN(ExtensionActionStorageManager);
65 }; 65 };
66 66
67 } // namespace extensions 67 } // namespace extensions
68 68
69 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_ACTION_STORAGE_MANAGER_H_ 69 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_ACTION_STORAGE_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698