| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006, 2007, 2009, 2010, 2011 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2007, 2009, 2010, 2011 Apple Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 73 class RenderLayerScrollableArea; | 73 class RenderLayerScrollableArea; |
| 74 class RenderObject; | 74 class RenderObject; |
| 75 class ScrollableArea; | 75 class ScrollableArea; |
| 76 class Scrollbar; | 76 class Scrollbar; |
| 77 class TextEvent; | 77 class TextEvent; |
| 78 class VisibleSelection; | 78 class VisibleSelection; |
| 79 class WheelEvent; | 79 class WheelEvent; |
| 80 class Widget; | 80 class Widget; |
| 81 | 81 |
| 82 enum AppendTrailingWhitespace { ShouldAppendTrailingWhitespace, DontAppendTraili
ngWhitespace }; | 82 enum AppendTrailingWhitespace { ShouldAppendTrailingWhitespace, DontAppendTraili
ngWhitespace }; |
| 83 enum CheckDragHysteresis { ShouldCheckDragHysteresis, DontCheckDragHysteresis }; | 83 enum class DragInitiator; |
| 84 | 84 |
| 85 class EventHandler : public NoBaseWillBeGarbageCollectedFinalized<EventHandler>
{ | 85 class EventHandler : public NoBaseWillBeGarbageCollectedFinalized<EventHandler>
{ |
| 86 WTF_MAKE_NONCOPYABLE(EventHandler); | 86 WTF_MAKE_NONCOPYABLE(EventHandler); |
| 87 public: | 87 public: |
| 88 explicit EventHandler(LocalFrame*); | 88 explicit EventHandler(LocalFrame*); |
| 89 ~EventHandler(); | 89 ~EventHandler(); |
| 90 void trace(Visitor*); | 90 void trace(Visitor*); |
| 91 | 91 |
| 92 void clear(); | 92 void clear(); |
| 93 void nodeWillBeRemoved(Node&); | 93 void nodeWillBeRemoved(Node&); |
| (...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 269 | 269 |
| 270 void updateMouseEventTargetNode(Node*, const PlatformMouseEvent&, bool fireM
ouseOverOut); | 270 void updateMouseEventTargetNode(Node*, const PlatformMouseEvent&, bool fireM
ouseOverOut); |
| 271 | 271 |
| 272 MouseEventWithHitTestResults prepareMouseEvent(const HitTestRequest&, const
PlatformMouseEvent&); | 272 MouseEventWithHitTestResults prepareMouseEvent(const HitTestRequest&, const
PlatformMouseEvent&); |
| 273 | 273 |
| 274 bool dispatchMouseEvent(const AtomicString& eventType, Node* target, int cli
ckCount, const PlatformMouseEvent&, bool setUnder); | 274 bool dispatchMouseEvent(const AtomicString& eventType, Node* target, int cli
ckCount, const PlatformMouseEvent&, bool setUnder); |
| 275 bool dispatchDragEvent(const AtomicString& eventType, Node* target, const Pl
atformMouseEvent&, DataTransfer*); | 275 bool dispatchDragEvent(const AtomicString& eventType, Node* target, const Pl
atformMouseEvent&, DataTransfer*); |
| 276 | 276 |
| 277 void clearDragDataTransfer(); | 277 void clearDragDataTransfer(); |
| 278 | 278 |
| 279 bool handleDrag(const MouseEventWithHitTestResults&, CheckDragHysteresis); | 279 bool handleDrag(const MouseEventWithHitTestResults&, DragInitiator); |
| 280 bool tryStartDrag(const MouseEventWithHitTestResults&); | 280 bool tryStartDrag(const MouseEventWithHitTestResults&); |
| 281 void clearDragState(); | 281 void clearDragState(); |
| 282 | 282 |
| 283 bool dispatchDragSrcEvent(const AtomicString& eventType, const PlatformMouse
Event&); | 283 bool dispatchDragSrcEvent(const AtomicString& eventType, const PlatformMouse
Event&); |
| 284 | 284 |
| 285 bool dragHysteresisExceeded(const FloatPoint&) const; | 285 bool dragHysteresisExceeded(const FloatPoint&) const; |
| 286 bool dragHysteresisExceeded(const IntPoint&) const; | 286 bool dragHysteresisExceeded(const IntPoint&) const; |
| 287 | 287 |
| 288 bool passMousePressEventToSubframe(MouseEventWithHitTestResults&, LocalFrame
* subframe); | 288 bool passMousePressEventToSubframe(MouseEventWithHitTestResults&, LocalFrame
* subframe); |
| 289 bool passMouseMoveEventToSubframe(MouseEventWithHitTestResults&, LocalFrame*
subframe, HitTestResult* hoveredNode = nullptr); | 289 bool passMouseMoveEventToSubframe(MouseEventWithHitTestResults&, LocalFrame*
subframe, HitTestResult* hoveredNode = nullptr); |
| (...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 388 RefPtr<UserGestureToken> m_touchSequenceUserGestureToken; | 388 RefPtr<UserGestureToken> m_touchSequenceUserGestureToken; |
| 389 | 389 |
| 390 bool m_touchPressed; | 390 bool m_touchPressed; |
| 391 | 391 |
| 392 RefPtrWillBeMember<Node> m_scrollGestureHandlingNode; | 392 RefPtrWillBeMember<Node> m_scrollGestureHandlingNode; |
| 393 bool m_lastGestureScrollOverWidget; | 393 bool m_lastGestureScrollOverWidget; |
| 394 RefPtrWillBeMember<Node> m_previousGestureScrolledNode; | 394 RefPtrWillBeMember<Node> m_previousGestureScrolledNode; |
| 395 RefPtrWillBeMember<Scrollbar> m_scrollbarHandlingScrollGesture; | 395 RefPtrWillBeMember<Scrollbar> m_scrollbarHandlingScrollGesture; |
| 396 | 396 |
| 397 double m_maxMouseMovedDuration; | 397 double m_maxMouseMovedDuration; |
| 398 bool m_didStartDrag; | |
| 399 | 398 |
| 400 bool m_longTapShouldInvokeContextMenu; | 399 bool m_longTapShouldInvokeContextMenu; |
| 401 | 400 |
| 402 Timer<EventHandler> m_activeIntervalTimer; | 401 Timer<EventHandler> m_activeIntervalTimer; |
| 403 double m_lastShowPressTimestamp; | 402 double m_lastShowPressTimestamp; |
| 404 RefPtrWillBeMember<Element> m_lastDeferredTapElement; | 403 RefPtrWillBeMember<Element> m_lastDeferredTapElement; |
| 405 }; | 404 }; |
| 406 | 405 |
| 407 } // namespace blink | 406 } // namespace blink |
| 408 | 407 |
| 409 #endif // EventHandler_h | 408 #endif // EventHandler_h |
| OLD | NEW |