Chromium Code Reviews| 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 "views/widget/root_view.h" | 5 #include "views/widget/root_view.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "base/message_loop.h" | 10 #include "base/message_loop.h" |
| (...skipping 367 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 378 | 378 |
| 379 if (gesture_manager_->ProcessTouchEventForGesture(e, this, status)) | 379 if (gesture_manager_->ProcessTouchEventForGesture(e, this, status)) |
| 380 status = ui::TOUCH_STATUS_SYNTH_MOUSE; | 380 status = ui::TOUCH_STATUS_SYNTH_MOUSE; |
| 381 return status; | 381 return status; |
| 382 } | 382 } |
| 383 | 383 |
| 384 // Reset touch_pressed_handler_ to indicate that no processing is occurring. | 384 // Reset touch_pressed_handler_ to indicate that no processing is occurring. |
| 385 touch_pressed_handler_ = NULL; | 385 touch_pressed_handler_ = NULL; |
| 386 | 386 |
| 387 // Give the touch event to the gesture manager. | 387 // Give the touch event to the gesture manager. |
| 388 if (gesture_manager_->ProcessTouchEventForGesture(e, this, status)) | 388 if (gesture_manager_->ProcessTouchEventForGesture(e, this, status)) |
|
rjkroege
2011/10/24 17:41:09
to bring this code more closely int how the WebKit
Gajen
2011/10/25 14:32:29
Then, do we need to change PTEFG signature in GM t
| |
| 389 status = ui::TOUCH_STATUS_SYNTH_MOUSE; | 389 status = ui::TOUCH_STATUS_SYNTH_MOUSE; |
| 390 return status; | 390 return status; |
| 391 } | 391 } |
| 392 | 392 |
| 393 bool RootView::OnTouchEvent(const TouchEvent& event) { | |
|
rjkroege
2011/10/24 17:41:09
I am reasonably strongly convinced that this is wr
Gajen
2011/10/25 14:32:29
My Bad..Now Removed this function as no longer req
| |
| 394 // TODO(Gajen): In next patch. | |
| 395 } | |
| 396 | |
| 393 void RootView::SetMouseHandler(View *new_mh) { | 397 void RootView::SetMouseHandler(View *new_mh) { |
| 394 // If we're clearing the mouse handler, clear explicit_mouse_handler_ as well. | 398 // If we're clearing the mouse handler, clear explicit_mouse_handler_ as well. |
| 395 explicit_mouse_handler_ = (new_mh != NULL); | 399 explicit_mouse_handler_ = (new_mh != NULL); |
| 396 mouse_pressed_handler_ = new_mh; | 400 mouse_pressed_handler_ = new_mh; |
| 397 } | 401 } |
| 398 | 402 |
| 399 void RootView::GetAccessibleState(ui::AccessibleViewState* state) { | 403 void RootView::GetAccessibleState(ui::AccessibleViewState* state) { |
| 400 state->role = ui::AccessibilityTypes::ROLE_APPLICATION; | 404 state->role = ui::AccessibilityTypes::ROLE_APPLICATION; |
| 401 } | 405 } |
| 402 | 406 |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 448 } | 452 } |
| 449 | 453 |
| 450 void RootView::SetMouseLocationAndFlags(const MouseEvent& event) { | 454 void RootView::SetMouseLocationAndFlags(const MouseEvent& event) { |
| 451 last_mouse_event_flags_ = event.flags(); | 455 last_mouse_event_flags_ = event.flags(); |
| 452 last_mouse_event_x_ = event.x(); | 456 last_mouse_event_x_ = event.x(); |
| 453 last_mouse_event_y_ = event.y(); | 457 last_mouse_event_y_ = event.y(); |
| 454 } | 458 } |
| 455 | 459 |
| 456 } // namespace internal | 460 } // namespace internal |
| 457 } // namespace views | 461 } // namespace views |
| OLD | NEW |