Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(21)

Side by Side Diff: third_party/WebKit/Source/core/input/EventHandler.h

Issue 1800143002: Notify Blink about start of gesture scroll through a queued event. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 381 matching lines...) Expand 10 before | Expand all | Expand 10 after
392 void setLastKnownMousePosition(const PlatformMouseEvent&); 392 void setLastKnownMousePosition(const PlatformMouseEvent&);
393 393
394 bool shouldTopControlsConsumeScroll(FloatSize) const; 394 bool shouldTopControlsConsumeScroll(FloatSize) const;
395 395
396 // If the given element is a shadow host and its root has delegatesFocus=fal se flag, 396 // If the given element is a shadow host and its root has delegatesFocus=fal se flag,
397 // slide focus to its inner element. Returns true if the resulting focus is different from 397 // slide focus to its inner element. Returns true if the resulting focus is different from
398 // the given element. 398 // the given element.
399 bool slideFocusOnShadowHostIfNecessary(const Element&); 399 bool slideFocusOnShadowHostIfNecessary(const Element&);
400 400
401 void dispatchPointerEvents(const PlatformTouchEvent&, HeapVector<TouchInfo>& ); 401 void dispatchPointerEvents(const PlatformTouchEvent&, HeapVector<TouchInfo>& );
402 void sendPointerCancels(HeapVector<TouchInfo>&);
403 402
404 WebInputEventResult dispatchTouchEvents(const PlatformTouchEvent&, HeapVecto r<TouchInfo>&, bool, bool); 403 WebInputEventResult dispatchTouchEvents(const PlatformTouchEvent&, HeapVecto r<TouchInfo>&, bool);
405 404
406 // NOTE: If adding a new field to this class please ensure that it is 405 // NOTE: If adding a new field to this class please ensure that it is
407 // cleared in |EventHandler::clear()|. 406 // cleared in |EventHandler::clear()|.
408 407
409 const Member<LocalFrame> m_frame; 408 const Member<LocalFrame> m_frame;
410 409
411 // Current button-press state for mouse/mouse-like-stylus. 410 // Current button-press state for mouse/mouse-like-stylus.
412 // TODO(crbug.com/563676): Buggy for chorded buttons. 411 // TODO(crbug.com/563676): Buggy for chorded buttons.
413 bool m_mousePressed; 412 bool m_mousePressed;
414 413
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
471 TouchRegionMap m_regionForTouchID; 470 TouchRegionMap m_regionForTouchID;
472 471
473 // If set, the document of the active touch sequence. Unset if no touch sequ ence active. 472 // If set, the document of the active touch sequence. Unset if no touch sequ ence active.
474 Member<Document> m_touchSequenceDocument; 473 Member<Document> m_touchSequenceDocument;
475 RefPtr<UserGestureToken> m_touchSequenceUserGestureToken; 474 RefPtr<UserGestureToken> m_touchSequenceUserGestureToken;
476 475
477 bool m_touchPressed; 476 bool m_touchPressed;
478 477
479 PointerEventManager m_pointerEventManager; 478 PointerEventManager m_pointerEventManager;
480 479
481 // This is set upon sending a pointercancel for touch, prevents PE dispatche s for touches until
482 // all touch-points become inactive.
483 // TODO(mustaq): Consider a state per pointerType, as in PointerIdManager? E xclude mouse?
484 bool m_inPointerCanceledState;
485
486 Member<Node> m_scrollGestureHandlingNode; 480 Member<Node> m_scrollGestureHandlingNode;
487 bool m_lastGestureScrollOverWidget; 481 bool m_lastGestureScrollOverWidget;
488 // The most recent element to scroll natively during this scroll 482 // The most recent element to scroll natively during this scroll
489 // sequence. Null if no native element has scrolled this scroll 483 // sequence. Null if no native element has scrolled this scroll
490 // sequence, or if the most recent element to scroll used scroll 484 // sequence, or if the most recent element to scroll used scroll
491 // customization. 485 // customization.
492 Member<Node> m_previousGestureScrolledNode; 486 Member<Node> m_previousGestureScrolledNode;
493 Member<Scrollbar> m_scrollbarHandlingScrollGesture; 487 Member<Scrollbar> m_scrollbarHandlingScrollGesture;
494 488
495 double m_maxMouseMovedDuration; 489 double m_maxMouseMovedDuration;
(...skipping 12 matching lines...) Expand all
508 // scroll which shouldn't propagate can't cause any element to 502 // scroll which shouldn't propagate can't cause any element to
509 // scroll other than the |m_previousGestureScrolledNode|. 503 // scroll other than the |m_previousGestureScrolledNode|.
510 bool m_deltaConsumedForScrollSequence; 504 bool m_deltaConsumedForScrollSequence;
511 }; 505 };
512 506
513 } // namespace blink 507 } // namespace blink
514 508
515 WTF_ALLOW_INIT_WITH_MEM_FUNCTIONS(blink::EventHandler::TouchInfo); 509 WTF_ALLOW_INIT_WITH_MEM_FUNCTIONS(blink::EventHandler::TouchInfo);
516 510
517 #endif // EventHandler_h 511 #endif // EventHandler_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698