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

Side by Side Diff: chrome/browser/extensions/api/media_galleries_private/media_galleries_private_api.h

Issue 14556015: [Media Galleries] Lazily initialize the storage monitor. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Rebase on prefs Created 7 years, 7 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_API_MEDIA_GALLERIES_PRIVATE_MEDIA_GALLERIES_PR IVATE_API_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_API_MEDIA_GALLERIES_PRIVATE_MEDIA_GALLERIES_PR IVATE_API_H_
6 #define CHROME_BROWSER_EXTENSIONS_API_MEDIA_GALLERIES_PRIVATE_MEDIA_GALLERIES_PR IVATE_API_H_ 6 #define CHROME_BROWSER_EXTENSIONS_API_MEDIA_GALLERIES_PRIVATE_MEDIA_GALLERIES_PR IVATE_API_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 DECLARE_EXTENSION_FUNCTION("mediaGalleriesPrivate.addGalleryWatch", 101 DECLARE_EXTENSION_FUNCTION("mediaGalleriesPrivate.addGalleryWatch",
102 MEDIAGALLERIESPRIVATE_ADDGALLERYWATCH); 102 MEDIAGALLERIESPRIVATE_ADDGALLERYWATCH);
103 103
104 protected: 104 protected:
105 virtual ~MediaGalleriesPrivateAddGalleryWatchFunction(); 105 virtual ~MediaGalleriesPrivateAddGalleryWatchFunction();
106 106
107 // AsyncExtensionFunction overrides. 107 // AsyncExtensionFunction overrides.
108 virtual bool RunImpl() OVERRIDE; 108 virtual bool RunImpl() OVERRIDE;
109 109
110 private: 110 private:
111 void OnStorageMonitorInit(chrome::MediaGalleryPrefId pref_id);
vandebo (ex-Chrome) 2013/05/23 15:04:17 Is the implementation of these missing?
Greg Billock 2013/05/30 22:17:47 Added
112
111 // Gallery watch request handler. 113 // Gallery watch request handler.
112 void HandleResponse(chrome::MediaGalleryPrefId gallery_id, 114 void HandleResponse(chrome::MediaGalleryPrefId gallery_id,
113 bool success); 115 bool success);
114 }; 116 };
115 117
116 // Implements the chrome.mediaGalleriesPrivate.removeGalleryWatch method. 118 // Implements the chrome.mediaGalleriesPrivate.removeGalleryWatch method.
117 class MediaGalleriesPrivateRemoveGalleryWatchFunction 119 class MediaGalleriesPrivateRemoveGalleryWatchFunction
118 : public SyncExtensionFunction { 120 : public AsyncExtensionFunction {
119 public: 121 public:
120 DECLARE_EXTENSION_FUNCTION("mediaGalleriesPrivate.removeGalleryWatch", 122 DECLARE_EXTENSION_FUNCTION("mediaGalleriesPrivate.removeGalleryWatch",
121 MEDIAGALLERIESPRIVATE_REMOVEGALLERYWATCH); 123 MEDIAGALLERIESPRIVATE_REMOVEGALLERYWATCH);
122 124
123 protected: 125 protected:
124 virtual ~MediaGalleriesPrivateRemoveGalleryWatchFunction(); 126 virtual ~MediaGalleriesPrivateRemoveGalleryWatchFunction();
125 127
126 // SyncExtensionFunction overrides. 128 // SyncExtensionFunction overrides.
127 virtual bool RunImpl() OVERRIDE; 129 virtual bool RunImpl() OVERRIDE;
130
131 private:
132 void OnStorageMonitorInit(chrome::MediaGalleryPrefId pref_id);
128 }; 133 };
129 134
130 // Implements the chrome.mediaGalleriesPrivate.getAllGalleryWatch method. 135 // Implements the chrome.mediaGalleriesPrivate.getAllGalleryWatch method.
131 class MediaGalleriesPrivateGetAllGalleryWatchFunction 136 class MediaGalleriesPrivateGetAllGalleryWatchFunction
132 : public SyncExtensionFunction { 137 : public SyncExtensionFunction {
133 public: 138 public:
134 DECLARE_EXTENSION_FUNCTION("mediaGalleriesPrivate.getAllGalleryWatch", 139 DECLARE_EXTENSION_FUNCTION("mediaGalleriesPrivate.getAllGalleryWatch",
135 MEDIAGALLERIESPRIVATE_GETALLGALLERYWATCH); 140 MEDIAGALLERIESPRIVATE_GETALLGALLERYWATCH);
136 protected: 141 protected:
137 virtual ~MediaGalleriesPrivateGetAllGalleryWatchFunction(); 142 virtual ~MediaGalleriesPrivateGetAllGalleryWatchFunction();
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
181 protected: 186 protected:
182 virtual ~MediaGalleriesPrivateGetHandlersFunction(); 187 virtual ~MediaGalleriesPrivateGetHandlersFunction();
183 188
184 // AsyncExtensionFunction overrides. 189 // AsyncExtensionFunction overrides.
185 virtual bool RunImpl() OVERRIDE; 190 virtual bool RunImpl() OVERRIDE;
186 }; 191 };
187 192
188 } // namespace extensions 193 } // namespace extensions
189 194
190 #endif // CHROME_BROWSER_EXTENSIONS_API_MEDIA_GALLERIES_PRIVATE_MEDIA_GALLERIES _PRIVATE_API_H_ 195 #endif // CHROME_BROWSER_EXTENSIONS_API_MEDIA_GALLERIES_PRIVATE_MEDIA_GALLERIES _PRIVATE_API_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698