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

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: Created 4 years, 9 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 350 matching lines...) Expand 10 before | Expand all | Expand 10 after
361 void setLastKnownMousePosition(const PlatformMouseEvent&); 361 void setLastKnownMousePosition(const PlatformMouseEvent&);
362 362
363 bool shouldTopControlsConsumeScroll(FloatSize) const; 363 bool shouldTopControlsConsumeScroll(FloatSize) const;
364 364
365 // If the given element is a shadow host and its root has delegatesFocus=fal se flag, 365 // If the given element is a shadow host and its root has delegatesFocus=fal se flag,
366 // slide focus to its inner element. Returns true if the resulting focus is different from 366 // slide focus to its inner element. Returns true if the resulting focus is different from
367 // the given element. 367 // the given element.
368 bool slideFocusOnShadowHostIfNecessary(const Element&); 368 bool slideFocusOnShadowHostIfNecessary(const Element&);
369 369
370 void dispatchPointerEvents(const PlatformTouchEvent&, WillBeHeapVector<Touch Info>&); 370 void dispatchPointerEvents(const PlatformTouchEvent&, WillBeHeapVector<Touch Info>&);
371 void sendPointerCancels(WillBeHeapVector<TouchInfo>&);
372 371
373 WebInputEventResult dispatchTouchEvents(const PlatformTouchEvent&, WillBeHea pVector<TouchInfo>&, bool, bool); 372 WebInputEventResult dispatchTouchEvents(const PlatformTouchEvent&, WillBeHea pVector<TouchInfo>&, bool, bool);
374 373
375 // NOTE: If adding a new field to this class please ensure that it is 374 // NOTE: If adding a new field to this class please ensure that it is
376 // cleared in |EventHandler::clear()|. 375 // cleared in |EventHandler::clear()|.
377 376
378 const RawPtrWillBeMember<LocalFrame> m_frame; 377 const RawPtrWillBeMember<LocalFrame> m_frame;
379 378
380 // Current button-press state for mouse/mouse-like-stylus. 379 // Current button-press state for mouse/mouse-like-stylus.
381 // TODO(crbug.com/563676): Buggy for chorded buttons. 380 // TODO(crbug.com/563676): Buggy for chorded buttons.
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
438 TouchTargetMap m_targetForTouchID; 437 TouchTargetMap m_targetForTouchID;
439 438
440 // If set, the document of the active touch sequence. Unset if no touch sequ ence active. 439 // If set, the document of the active touch sequence. Unset if no touch sequ ence active.
441 RefPtrWillBeMember<Document> m_touchSequenceDocument; 440 RefPtrWillBeMember<Document> m_touchSequenceDocument;
442 RefPtr<UserGestureToken> m_touchSequenceUserGestureToken; 441 RefPtr<UserGestureToken> m_touchSequenceUserGestureToken;
443 442
444 bool m_touchPressed; 443 bool m_touchPressed;
445 444
446 PointerEventManager m_pointerEventManager; 445 PointerEventManager m_pointerEventManager;
447 446
448 // This is set upon sending a pointercancel for touch, prevents PE dispatche s for touches until
449 // all touch-points become inactive.
450 // TODO(mustaq): Consider a state per pointerType, as in PointerIdManager? E xclude mouse?
451 bool m_inPointerCanceledState;
452
453 RefPtrWillBeMember<Node> m_scrollGestureHandlingNode; 447 RefPtrWillBeMember<Node> m_scrollGestureHandlingNode;
454 bool m_lastGestureScrollOverWidget; 448 bool m_lastGestureScrollOverWidget;
455 // The most recent element to scroll natively during this scroll 449 // The most recent element to scroll natively during this scroll
456 // sequence. Null if no native element has scrolled this scroll 450 // sequence. Null if no native element has scrolled this scroll
457 // sequence, or if the most recent element to scroll used scroll 451 // sequence, or if the most recent element to scroll used scroll
458 // customization. 452 // customization.
459 RefPtrWillBeMember<Node> m_previousGestureScrolledNode; 453 RefPtrWillBeMember<Node> m_previousGestureScrolledNode;
460 RefPtrWillBeMember<Scrollbar> m_scrollbarHandlingScrollGesture; 454 RefPtrWillBeMember<Scrollbar> m_scrollbarHandlingScrollGesture;
461 455
462 double m_maxMouseMovedDuration; 456 double m_maxMouseMovedDuration;
(...skipping 12 matching lines...) Expand all
475 // scroll which shouldn't propagate can't cause any element to 469 // scroll which shouldn't propagate can't cause any element to
476 // scroll other than the |m_previousGestureScrolledNode|. 470 // scroll other than the |m_previousGestureScrolledNode|.
477 bool m_deltaConsumedForScrollSequence; 471 bool m_deltaConsumedForScrollSequence;
478 }; 472 };
479 473
480 } // namespace blink 474 } // namespace blink
481 475
482 WTF_ALLOW_INIT_WITH_MEM_FUNCTIONS(blink::EventHandler::TouchInfo); 476 WTF_ALLOW_INIT_WITH_MEM_FUNCTIONS(blink::EventHandler::TouchInfo);
483 477
484 #endif // EventHandler_h 478 #endif // EventHandler_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698