OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/render_view_test.h" | 5 #include "chrome/test/render_view_test.h" |
6 | 6 |
7 #include "chrome/browser/extensions/extension_function_dispatcher.h" | 7 #include "chrome/browser/extensions/extension_function_dispatcher.h" |
8 #include "chrome/common/extensions/extension.h" | 8 #include "chrome/common/extensions/extension.h" |
9 #include "chrome/common/print_messages.h" | 9 #include "chrome/common/print_messages.h" |
10 #include "chrome/common/render_messages.h" | 10 #include "chrome/common/render_messages.h" |
(...skipping 301 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
312 mouse_event.x = bounds.CenterPoint().x(); | 312 mouse_event.x = bounds.CenterPoint().x(); |
313 mouse_event.y = bounds.CenterPoint().y(); | 313 mouse_event.y = bounds.CenterPoint().y(); |
314 mouse_event.clickCount = 1; | 314 mouse_event.clickCount = 1; |
315 ViewMsg_HandleInputEvent input_event(0); | 315 ViewMsg_HandleInputEvent input_event(0); |
316 scoped_ptr<IPC::Message> input_message(new ViewMsg_HandleInputEvent(0)); | 316 scoped_ptr<IPC::Message> input_message(new ViewMsg_HandleInputEvent(0)); |
317 input_message->WriteData(reinterpret_cast<const char*>(&mouse_event), | 317 input_message->WriteData(reinterpret_cast<const char*>(&mouse_event), |
318 sizeof(WebMouseEvent)); | 318 sizeof(WebMouseEvent)); |
319 view_->OnMessageReceived(*input_message); | 319 view_->OnMessageReceived(*input_message); |
320 return true; | 320 return true; |
321 } | 321 } |
| 322 |
| 323 void RenderViewTest::ClearHistory() { |
| 324 view_->page_id_ = -1; |
| 325 view_->history_list_offset_ = -1; |
| 326 view_->history_list_length_ = 0; |
| 327 view_->history_page_ids_.clear(); |
| 328 } |
OLD | NEW |