OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 "core/input/TouchEventManager.h" | 5 #include "core/input/TouchEventManager.h" |
6 | 6 |
| 7 #include <memory> |
7 #include "core/dom/Document.h" | 8 #include "core/dom/Document.h" |
8 #include "core/events/TouchEvent.h" | 9 #include "core/events/TouchEvent.h" |
9 #include "core/frame/Deprecation.h" | 10 #include "core/frame/Deprecation.h" |
10 #include "core/frame/EventHandlerRegistry.h" | 11 #include "core/frame/EventHandlerRegistry.h" |
11 #include "core/frame/FrameView.h" | 12 #include "core/frame/FrameView.h" |
12 #include "core/html/HTMLCanvasElement.h" | 13 #include "core/html/HTMLCanvasElement.h" |
13 #include "core/input/EventHandlingUtil.h" | 14 #include "core/input/EventHandlingUtil.h" |
14 #include "core/input/TouchActionUtil.h" | 15 #include "core/input/TouchActionUtil.h" |
15 #include "core/layout/HitTestCanvasResult.h" | 16 #include "core/layout/HitTestCanvasResult.h" |
16 #include "core/page/ChromeClient.h" | 17 #include "core/page/ChromeClient.h" |
17 #include "core/page/Page.h" | 18 #include "core/page/Page.h" |
18 #include "platform/Histogram.h" | 19 #include "platform/Histogram.h" |
| 20 #include "platform/wtf/CurrentTime.h" |
| 21 #include "platform/wtf/PtrUtil.h" |
19 #include "public/platform/WebTouchEvent.h" | 22 #include "public/platform/WebTouchEvent.h" |
20 #include "wtf/CurrentTime.h" | |
21 #include "wtf/PtrUtil.h" | |
22 #include <memory> | |
23 | 23 |
24 namespace blink { | 24 namespace blink { |
25 | 25 |
26 namespace { | 26 namespace { |
27 | 27 |
28 bool HasTouchHandlers(const EventHandlerRegistry& registry) { | 28 bool HasTouchHandlers(const EventHandlerRegistry& registry) { |
29 return registry.HasEventHandlers( | 29 return registry.HasEventHandlers( |
30 EventHandlerRegistry::kTouchStartOrMoveEventBlocking) || | 30 EventHandlerRegistry::kTouchStartOrMoveEventBlocking) || |
31 registry.HasEventHandlers( | 31 registry.HasEventHandlers( |
32 EventHandlerRegistry::kTouchStartOrMoveEventPassive) || | 32 EventHandlerRegistry::kTouchStartOrMoveEventPassive) || |
(...skipping 485 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
518 } | 518 } |
519 | 519 |
520 return DispatchTouchEvents(event, touch_infos, all_touches_released); | 520 return DispatchTouchEvents(event, touch_infos, all_touches_released); |
521 } | 521 } |
522 | 522 |
523 bool TouchEventManager::IsAnyTouchActive() const { | 523 bool TouchEventManager::IsAnyTouchActive() const { |
524 return touch_pressed_; | 524 return touch_pressed_; |
525 } | 525 } |
526 | 526 |
527 } // namespace blink | 527 } // namespace blink |
OLD | NEW |