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

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

Issue 226043005: Fix webview.executeScript API (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update InsertCss API. Created 6 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 (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 207 matching lines...) Expand 10 before | Expand all | Expand 10 after
218 218
219 // ExtensionFunction: 219 // ExtensionFunction:
220 virtual bool HasPermission() OVERRIDE; 220 virtual bool HasPermission() OVERRIDE;
221 221
222 // Initialize the |execute_tab_id_| and |details_| if they haven't already 222 // Initialize the |execute_tab_id_| and |details_| if they haven't already
223 // been. Returns whether initialization was successful. 223 // been. Returns whether initialization was successful.
224 virtual bool Init() OVERRIDE; 224 virtual bool Init() OVERRIDE;
225 virtual bool CanExecuteScriptOnPage() OVERRIDE; 225 virtual bool CanExecuteScriptOnPage() OVERRIDE;
226 virtual ScriptExecutor* GetScriptExecutor() OVERRIDE; 226 virtual ScriptExecutor* GetScriptExecutor() OVERRIDE;
227 virtual bool IsWebView() const OVERRIDE; 227 virtual bool IsWebView() const OVERRIDE;
228 virtual const GURL& GetWebViewSrc() const OVERRIDE;
228 229
229 private: 230 private:
230 // Id of tab which executes code. 231 // Id of tab which executes code.
231 int execute_tab_id_; 232 int execute_tab_id_;
232 }; 233 };
233 234
234 class TabsExecuteScriptFunction : public ExecuteCodeInTabFunction { 235 class TabsExecuteScriptFunction : public ExecuteCodeInTabFunction {
235 protected: 236 protected:
236 virtual bool ShouldInsertCSS() const OVERRIDE; 237 virtual bool ShouldInsertCSS() const OVERRIDE;
237 238
(...skipping 14 matching lines...) Expand all
252 virtual ~TabsInsertCSSFunction() {} 253 virtual ~TabsInsertCSSFunction() {}
253 254
254 virtual bool ShouldInsertCSS() const OVERRIDE; 255 virtual bool ShouldInsertCSS() const OVERRIDE;
255 256
256 DECLARE_EXTENSION_FUNCTION("tabs.insertCSS", TABS_INSERTCSS) 257 DECLARE_EXTENSION_FUNCTION("tabs.insertCSS", TABS_INSERTCSS)
257 }; 258 };
258 259
259 } // namespace extensions 260 } // namespace extensions
260 261
261 #endif // CHROME_BROWSER_EXTENSIONS_API_TABS_TABS_API_H_ 262 #endif // CHROME_BROWSER_EXTENSIONS_API_TABS_TABS_API_H_
OLDNEW
« no previous file with comments | « chrome/browser/extensions/api/execute_code_function.cc ('k') | chrome/browser/extensions/api/tabs/tabs_api.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698