Chromium Code Reviews| OLD | NEW |
|---|---|
| 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 EXTENSIONS_RENDERER_SCRIPTS_RUN_INFO_H_ | 5 #ifndef EXTENSIONS_RENDERER_SCRIPTS_RUN_INFO_H_ |
| 6 #define EXTENSIONS_RENDERER_SCRIPTS_RUN_INFO_H_ | 6 #define EXTENSIONS_RENDERER_SCRIPTS_RUN_INFO_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 | 9 |
| 10 #include <map> | 10 #include <map> |
| (...skipping 22 matching lines...) Expand all Loading... | |
| 33 // The number of CSS scripts injected. | 33 // The number of CSS scripts injected. |
| 34 size_t num_css; | 34 size_t num_css; |
| 35 // The number of JS scripts injected. | 35 // The number of JS scripts injected. |
| 36 size_t num_js; | 36 size_t num_js; |
| 37 // The number of blocked JS scripts injected. | 37 // The number of blocked JS scripts injected. |
| 38 size_t num_blocking_js; | 38 size_t num_blocking_js; |
| 39 // A map of extension ids to executing script paths. | 39 // A map of extension ids to executing script paths. |
| 40 ExecutingScriptsMap executing_scripts; | 40 ExecutingScriptsMap executing_scripts; |
| 41 // The elapsed time since the ScriptsRunInfo was constructed. | 41 // The elapsed time since the ScriptsRunInfo was constructed. |
| 42 base::ElapsedTimer timer; | 42 base::ElapsedTimer timer; |
| 43 // A list of pathnames of executing scripts | |
|
Devlin
2016/07/12 23:32:36
nit: comment needs a period. Also, I'd probably r
catmullings
2016/07/13 17:25:34
Done.
| |
| 44 std::set<GURL> injected_scripts; | |
| 43 | 45 |
| 44 // Log information about a given script run. If |send_script_activity| is | 46 // Log information about a given script run. If |send_script_activity| is |
| 45 // true, this also informs the browser of the script run. | 47 // true, this also informs the browser of the script run. |
| 46 void LogRun(bool send_script_activity); | 48 void LogRun(bool send_script_activity); |
| 47 | 49 |
| 48 private: | 50 private: |
| 49 // The routinig id to use to notify the browser of any injections. Since the | 51 // The routinig id to use to notify the browser of any injections. Since the |
| 50 // frame may be deleted in injection, we don't hold on to a reference to it | 52 // frame may be deleted in injection, we don't hold on to a reference to it |
| 51 // directly. | 53 // directly. |
| 52 int routing_id_; | 54 int routing_id_; |
| 53 | 55 |
| 54 // The run location at which injection is happening. | 56 // The run location at which injection is happening. |
| 55 UserScript::RunLocation run_location_; | 57 UserScript::RunLocation run_location_; |
| 56 | 58 |
| 57 // The url of the frame, preserved for the same reason as the routing id. | 59 // The url of the frame, preserved for the same reason as the routing id. |
| 58 GURL frame_url_; | 60 GURL frame_url_; |
| 59 | 61 |
| 60 DISALLOW_COPY_AND_ASSIGN(ScriptsRunInfo); | 62 DISALLOW_COPY_AND_ASSIGN(ScriptsRunInfo); |
| 61 }; | 63 }; |
| 62 | 64 |
| 63 } // namespace extensions | 65 } // namespace extensions |
| 64 | 66 |
| 65 #endif // EXTENSIONS_RENDERER_SCRIPTS_RUN_INFO_H_ | 67 #endif // EXTENSIONS_RENDERER_SCRIPTS_RUN_INFO_H_ |
| OLD | NEW |