Index: ui/aura/root_window.cc |
diff --git a/ui/aura/root_window.cc b/ui/aura/root_window.cc |
index 9fa87ce581ab36309546e6fc9e84cb1c5428400d..fa7760f51e49d8b9b8f251ed79ddf460fcfa3d26 100644 |
--- a/ui/aura/root_window.cc |
+++ b/ui/aura/root_window.cc |
@@ -778,21 +778,22 @@ bool RootWindow::OnHostScrollEvent(ui::ScrollEvent* event) { |
Window* target = mouse_pressed_handler_ ? |
mouse_pressed_handler_ : client::GetCaptureWindow(this); |
+ |
if (!target) |
target = GetEventHandlerForPoint(event->location()); |
- if (target && target->delegate()) { |
- int flags = event->flags(); |
- gfx::Point location_in_window = event->location(); |
- Window::ConvertPointToTarget(this, target, &location_in_window); |
- if (IsNonClientLocation(target, location_in_window)) |
- flags |= ui::EF_IS_NON_CLIENT; |
- event->set_flags(flags); |
- event->ConvertLocationToTarget(static_cast<Window*>(this), target); |
- ProcessEvent(target, event); |
- return event->handled(); |
- } |
- return false; |
+ if (!target) |
+ target = this; |
+ |
+ int flags = event->flags(); |
+ gfx::Point location_in_window = event->location(); |
+ Window::ConvertPointToTarget(this, target, &location_in_window); |
+ if (IsNonClientLocation(target, location_in_window)) |
+ flags |= ui::EF_IS_NON_CLIENT; |
+ event->set_flags(flags); |
+ event->ConvertLocationToTarget(static_cast<Window*>(this), target); |
+ ProcessEvent(target, event); |
+ return event->handled(); |
} |
bool RootWindow::OnHostTouchEvent(ui::TouchEvent* event) { |