| 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 "base/basictypes.h" | 5 #include "base/basictypes.h" |
| 6 #include "base/bind.h" | 6 #include "base/bind.h" |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/location.h" | 8 #include "base/location.h" |
| 9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "base/memory/shared_memory.h" | 10 #include "base/memory/shared_memory.h" |
| (...skipping 351 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 362 void HandleKeyboardEvent(const NativeWebKeyboardEvent& event) override { | 362 void HandleKeyboardEvent(const NativeWebKeyboardEvent& event) override { |
| 363 unhandled_keyboard_event_type_ = event.type; | 363 unhandled_keyboard_event_type_ = event.type; |
| 364 unhandled_keyboard_event_called_ = true; | 364 unhandled_keyboard_event_called_ = true; |
| 365 } | 365 } |
| 366 | 366 |
| 367 bool HandleWheelEvent(const blink::WebMouseWheelEvent& event) override { | 367 bool HandleWheelEvent(const blink::WebMouseWheelEvent& event) override { |
| 368 handle_wheel_event_called_ = true; | 368 handle_wheel_event_called_ = true; |
| 369 return handle_wheel_event_; | 369 return handle_wheel_event_; |
| 370 } | 370 } |
| 371 | 371 |
| 372 void Cut() override {} |
| 373 void Copy() override {} |
| 374 void Paste() override {} |
| 375 |
| 372 private: | 376 private: |
| 373 bool prehandle_keyboard_event_; | 377 bool prehandle_keyboard_event_; |
| 374 bool prehandle_keyboard_event_called_; | 378 bool prehandle_keyboard_event_called_; |
| 375 WebInputEvent::Type prehandle_keyboard_event_type_; | 379 WebInputEvent::Type prehandle_keyboard_event_type_; |
| 376 | 380 |
| 377 bool unhandled_keyboard_event_called_; | 381 bool unhandled_keyboard_event_called_; |
| 378 WebInputEvent::Type unhandled_keyboard_event_type_; | 382 WebInputEvent::Type unhandled_keyboard_event_type_; |
| 379 | 383 |
| 380 bool handle_wheel_event_; | 384 bool handle_wheel_event_; |
| 381 bool handle_wheel_event_called_; | 385 bool handle_wheel_event_called_; |
| (...skipping 1157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1539 // Having an initial size set means that the size information had been sent | 1543 // Having an initial size set means that the size information had been sent |
| 1540 // with the reqiest to new up the RenderView and so subsequent WasResized | 1544 // with the reqiest to new up the RenderView and so subsequent WasResized |
| 1541 // calls should not result in new IPC (unless the size has actually changed). | 1545 // calls should not result in new IPC (unless the size has actually changed). |
| 1542 host_->WasResized(); | 1546 host_->WasResized(); |
| 1543 EXPECT_FALSE(process_->sink().GetUniqueMessageMatching(ViewMsg_Resize::ID)); | 1547 EXPECT_FALSE(process_->sink().GetUniqueMessageMatching(ViewMsg_Resize::ID)); |
| 1544 EXPECT_EQ(initial_size_, host_->old_resize_params_->new_size); | 1548 EXPECT_EQ(initial_size_, host_->old_resize_params_->new_size); |
| 1545 EXPECT_TRUE(host_->resize_ack_pending_); | 1549 EXPECT_TRUE(host_->resize_ack_pending_); |
| 1546 } | 1550 } |
| 1547 | 1551 |
| 1548 } // namespace content | 1552 } // namespace content |
| OLD | NEW |