diff options
Diffstat (limited to 'ui/aura')
-rw-r--r-- | ui/aura/root_window.cc | 6 | ||||
-rw-r--r-- | ui/aura/root_window_host_linux.cc | 1 |
2 files changed, 6 insertions, 1 deletions
diff --git a/ui/aura/root_window.cc b/ui/aura/root_window.cc index d79c6ec..2449873 100644 --- a/ui/aura/root_window.cc +++ b/ui/aura/root_window.cc @@ -803,7 +803,11 @@ bool RootWindow::OnHostTouchEvent(ui::TouchEvent* event) { Env::GetInstance()->set_touch_down(touch_ids_down_ != 0); break; - // Don't handle ET_TOUCH_CANCELLED since we always get a ET_TOUCH_RELEASED. + // Handle ET_TOUCH_CANCELLED only if it has a native event. + case ui::ET_TOUCH_CANCELLED: + if (!event->HasNativeEvent()) + break; + // fallthrough case ui::ET_TOUCH_RELEASED: touch_ids_down_ = (touch_ids_down_ | (1 << event->touch_id())) ^ (1 << event->touch_id()); diff --git a/ui/aura/root_window_host_linux.cc b/ui/aura/root_window_host_linux.cc index c15fad9..e3ececa 100644 --- a/ui/aura/root_window_host_linux.cc +++ b/ui/aura/root_window_host_linux.cc @@ -868,6 +868,7 @@ void RootWindowHostLinux::DispatchXI2Event(const base::NativeEvent& event) { xev = &last_event; // fallthrough case ui::ET_TOUCH_PRESSED: + case ui::ET_TOUCH_CANCELLED: case ui::ET_TOUCH_RELEASED: { ui::TouchEvent touchev(xev); #if defined(OS_CHROMEOS) |