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 #include "chrome/test/base/ui_test_utils.h" | 5 #include "chrome/test/base/ui_test_utils.h" |
6 | 6 |
7 #if defined(OS_WIN) | 7 #if defined(OS_WIN) |
8 #include <windows.h> | 8 #include <windows.h> |
9 #endif | 9 #endif |
10 | 10 |
(...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
200 | 200 |
201 virtual void FirstObjectAdded() { | 201 virtual void FirstObjectAdded() { |
202 AddRef(); | 202 AddRef(); |
203 } | 203 } |
204 | 204 |
205 virtual void LastObjectRemoved() { | 205 virtual void LastObjectRemoved() { |
206 Release(); | 206 Release(); |
207 } | 207 } |
208 | 208 |
209 private: | 209 private: |
| 210 friend class base::RefCounted<InProcessJavaScriptExecutionController>; |
| 211 virtual ~InProcessJavaScriptExecutionController() {} |
| 212 |
210 // Weak pointer to the associated RenderViewHost. | 213 // Weak pointer to the associated RenderViewHost. |
211 RenderViewHost* render_view_host_; | 214 RenderViewHost* render_view_host_; |
212 }; | 215 }; |
213 | 216 |
214 // Specifying a prototype so that we can add the WARN_UNUSED_RESULT attribute. | 217 // Specifying a prototype so that we can add the WARN_UNUSED_RESULT attribute. |
215 bool ExecuteJavaScriptHelper(RenderViewHost* render_view_host, | 218 bool ExecuteJavaScriptHelper(RenderViewHost* render_view_host, |
216 const std::wstring& frame_xpath, | 219 const std::wstring& frame_xpath, |
217 const std::wstring& original_script, | 220 const std::wstring& original_script, |
218 scoped_ptr<Value>* result) WARN_UNUSED_RESULT; | 221 scoped_ptr<Value>* result) WARN_UNUSED_RESULT; |
219 | 222 |
(...skipping 936 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1156 int state, | 1159 int state, |
1157 const base::Closure& followup) { | 1160 const base::Closure& followup) { |
1158 if (!followup.is_null()) | 1161 if (!followup.is_null()) |
1159 ui_controls::SendMouseEventsNotifyWhenDone(button, state, followup); | 1162 ui_controls::SendMouseEventsNotifyWhenDone(button, state, followup); |
1160 else | 1163 else |
1161 ui_controls::SendMouseEvents(button, state); | 1164 ui_controls::SendMouseEvents(button, state); |
1162 } | 1165 } |
1163 | 1166 |
1164 } // namespace internal | 1167 } // namespace internal |
1165 } // namespace ui_test_utils | 1168 } // namespace ui_test_utils |
OLD | NEW |