| OLD | NEW |
| 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_EXECUTE_CODE_IN_TAB_FUNCTION_H__ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_API_TABS_EXECUTE_CODE_IN_TAB_FUNCTION_H__ |
| 6 #define CHROME_BROWSER_EXTENSIONS_API_TABS_EXECUTE_CODE_IN_TAB_FUNCTION_H__ | 6 #define CHROME_BROWSER_EXTENSIONS_API_TABS_EXECUTE_CODE_IN_TAB_FUNCTION_H__ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "chrome/browser/extensions/extension_function.h" | 10 #include "chrome/browser/extensions/extension_function.h" |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 52 | 52 |
| 53 // Contains extension resource built from path of file which is | 53 // Contains extension resource built from path of file which is |
| 54 // specified in JSON arguments. | 54 // specified in JSON arguments. |
| 55 ExtensionResource resource_; | 55 ExtensionResource resource_; |
| 56 | 56 |
| 57 // If all_frames_ is true, script or CSS text would be injected | 57 // If all_frames_ is true, script or CSS text would be injected |
| 58 // to all frames; Otherwise only injected to top main frame. | 58 // to all frames; Otherwise only injected to top main frame. |
| 59 bool all_frames_; | 59 bool all_frames_; |
| 60 | 60 |
| 61 // The intended time to run the script. | 61 // The intended time to run the script. |
| 62 UserScript::RunLocation run_at_; | 62 extensions::UserScript::RunLocation run_at_; |
| 63 }; | 63 }; |
| 64 | 64 |
| 65 class TabsExecuteScriptFunction : public ExecuteCodeInTabFunction { | 65 class TabsExecuteScriptFunction : public ExecuteCodeInTabFunction { |
| 66 private: | 66 private: |
| 67 virtual ~TabsExecuteScriptFunction() {} | 67 virtual ~TabsExecuteScriptFunction() {} |
| 68 | 68 |
| 69 DECLARE_EXTENSION_FUNCTION_NAME("tabs.executeScript") | 69 DECLARE_EXTENSION_FUNCTION_NAME("tabs.executeScript") |
| 70 }; | 70 }; |
| 71 | 71 |
| 72 class TabsInsertCSSFunction : public ExecuteCodeInTabFunction { | 72 class TabsInsertCSSFunction : public ExecuteCodeInTabFunction { |
| 73 private: | 73 private: |
| 74 virtual ~TabsInsertCSSFunction() {} | 74 virtual ~TabsInsertCSSFunction() {} |
| 75 | 75 |
| 76 DECLARE_EXTENSION_FUNCTION_NAME("tabs.insertCSS") | 76 DECLARE_EXTENSION_FUNCTION_NAME("tabs.insertCSS") |
| 77 }; | 77 }; |
| 78 | 78 |
| 79 #endif // CHROME_BROWSER_EXTENSIONS_API_TABS_EXECUTE_CODE_IN_TAB_FUNCTION_H__ | 79 #endif // CHROME_BROWSER_EXTENSIONS_API_TABS_EXECUTE_CODE_IN_TAB_FUNCTION_H__ |
| OLD | NEW |