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

Side by Side Diff: chrome/browser/extensions/api/tabs/tabs_api.h

Issue 16915006: Convert most of extensions and some other random stuff to using the base namespace for Values. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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 | Annotate | Revision Log
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_TABS_TABS_API_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_API_TABS_TABS_API_H_
6 #define CHROME_BROWSER_EXTENSIONS_API_TABS_TABS_API_H_ 6 #define CHROME_BROWSER_EXTENSIONS_API_TABS_TABS_API_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
143 bool* is_async); 143 bool* is_async);
144 virtual void PopulateResult(); 144 virtual void PopulateResult();
145 145
146 content::WebContents* web_contents_; 146 content::WebContents* web_contents_;
147 147
148 private: 148 private:
149 virtual bool RunImpl() OVERRIDE; 149 virtual bool RunImpl() OVERRIDE;
150 void OnExecuteCodeFinished(const std::string& error, 150 void OnExecuteCodeFinished(const std::string& error,
151 int32 on_page_id, 151 int32 on_page_id,
152 const GURL& on_url, 152 const GURL& on_url,
153 const ListValue& script_result); 153 const base::ListValue& script_result);
154 154
155 DECLARE_EXTENSION_FUNCTION("tabs.update", TABS_UPDATE) 155 DECLARE_EXTENSION_FUNCTION("tabs.update", TABS_UPDATE)
156 }; 156 };
157 class TabsMoveFunction : public SyncExtensionFunction { 157 class TabsMoveFunction : public SyncExtensionFunction {
158 virtual ~TabsMoveFunction() {} 158 virtual ~TabsMoveFunction() {}
159 virtual bool RunImpl() OVERRIDE; 159 virtual bool RunImpl() OVERRIDE;
160 bool MoveTab(int tab_id, 160 bool MoveTab(int tab_id,
161 int* new_index, 161 int* new_index,
162 int iteration, 162 int iteration,
163 ListValue* tab_values, 163 base::ListValue* tab_values,
164 int* window_id); 164 int* window_id);
165 DECLARE_EXTENSION_FUNCTION("tabs.move", TABS_MOVE) 165 DECLARE_EXTENSION_FUNCTION("tabs.move", TABS_MOVE)
166 }; 166 };
167 class TabsReloadFunction : public SyncExtensionFunction { 167 class TabsReloadFunction : public SyncExtensionFunction {
168 virtual ~TabsReloadFunction() {} 168 virtual ~TabsReloadFunction() {}
169 virtual bool RunImpl() OVERRIDE; 169 virtual bool RunImpl() OVERRIDE;
170 DECLARE_EXTENSION_FUNCTION("tabs.reload", TABS_RELOAD) 170 DECLARE_EXTENSION_FUNCTION("tabs.reload", TABS_RELOAD)
171 }; 171 };
172 class TabsRemoveFunction : public SyncExtensionFunction { 172 class TabsRemoveFunction : public SyncExtensionFunction {
173 virtual ~TabsRemoveFunction() {} 173 virtual ~TabsRemoveFunction() {}
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
246 int execute_tab_id_; 246 int execute_tab_id_;
247 }; 247 };
248 248
249 class TabsExecuteScriptFunction : public ExecuteCodeInTabFunction { 249 class TabsExecuteScriptFunction : public ExecuteCodeInTabFunction {
250 protected: 250 protected:
251 virtual bool ShouldInsertCSS() const OVERRIDE; 251 virtual bool ShouldInsertCSS() const OVERRIDE;
252 252
253 private: 253 private:
254 virtual ~TabsExecuteScriptFunction() {} 254 virtual ~TabsExecuteScriptFunction() {}
255 255
256 virtual void OnExecuteCodeFinished(const std::string& error, 256 virtual void OnExecuteCodeFinished(
257 int32 on_page_id, 257 const std::string& error,
258 const GURL& on_url, 258 int32 on_page_id,
259 const ListValue& script_result) OVERRIDE; 259 const GURL& on_url,
260 const base::ListValue& script_result) OVERRIDE;
260 261
261 DECLARE_EXTENSION_FUNCTION("tabs.executeScript", TABS_EXECUTESCRIPT) 262 DECLARE_EXTENSION_FUNCTION("tabs.executeScript", TABS_EXECUTESCRIPT)
262 }; 263 };
263 264
264 class TabsInsertCSSFunction : public ExecuteCodeInTabFunction { 265 class TabsInsertCSSFunction : public ExecuteCodeInTabFunction {
265 private: 266 private:
266 virtual ~TabsInsertCSSFunction() {} 267 virtual ~TabsInsertCSSFunction() {}
267 268
268 virtual bool ShouldInsertCSS() const OVERRIDE; 269 virtual bool ShouldInsertCSS() const OVERRIDE;
269 270
270 DECLARE_EXTENSION_FUNCTION("tabs.insertCSS", TABS_INSERTCSS) 271 DECLARE_EXTENSION_FUNCTION("tabs.insertCSS", TABS_INSERTCSS)
271 }; 272 };
272 273
273 } // namespace extensions 274 } // namespace extensions
274 275
275 #endif // CHROME_BROWSER_EXTENSIONS_API_TABS_TABS_API_H_ 276 #endif // CHROME_BROWSER_EXTENSIONS_API_TABS_TABS_API_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698