Changeset 238280 in webkit
- Timestamp:
- Nov 16, 2018, 7:07:17 AM (8 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 3 edited
-
LayoutTests/ChangeLog (modified) (1 diff)
-
LayoutTests/fast/events/touch/ios/click-instead-of-hover-simple-expected.txt (added)
-
LayoutTests/fast/events/touch/ios/click-instead-of-hover-simple.html (added)
-
Source/WebCore/ChangeLog (modified) (1 diff)
-
Source/WebCore/rendering/updating/RenderTreeUpdater.cpp (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r238279 r238280 1 2018-11-16 Zalan Bujtas <zalan@apple.com> 2 3 [iOS] 2 subsequent taps are required to trigger certain tasks on the desktop version of YouTube.com 4 https://bugs.webkit.org/show_bug.cgi?id=191712 5 <rdar://problem/45612900> 6 7 Reviewed by Simon Fraser. 8 9 * fast/events/touch/ios/click-instead-of-hover-simple-expected.txt: Added. 10 * fast/events/touch/ios/click-instead-of-hover-simple.html: Added. 11 1 12 2018-11-16 Zalan Bujtas <zalan@apple.com> 2 13 -
trunk/Source/WebCore/ChangeLog
r238279 r238280 1 2018-11-16 Zalan Bujtas <zalan@apple.com> 2 3 [iOS] 2 subsequent taps are required to trigger certain tasks on the desktop version of YouTube.com (hover vs click). 4 https://bugs.webkit.org/show_bug.cgi?id=191712 5 <rdar://problem/45612900> 6 7 Reviewed by Simon Fraser. 8 9 In handleSyntheticClick() we use WKContentObservation to figure out whether the tap should be treated as a hover or a click. 10 In general, if the mouse-move event triggers a visible content change, we assume we hit a hover-like drop down menu (or something similar) 11 and no need to dispatch a click event. 12 The idea here is that if the new content (result of the mouse-move event) does not respond to mouse click, it is most likely 13 only for tooltip-like reasons and it's ok to proceed with the click event. 14 15 Test: fast/events/touch/ios/click-instead-of-hover-simple.html 16 17 * rendering/updating/RenderTreeUpdater.cpp: 18 (WebCore::CheckForVisibilityChange::~CheckForVisibilityChange): 19 1 20 2018-11-16 Zalan Bujtas <zalan@apple.com> 2 21 -
trunk/Source/WebCore/rendering/updating/RenderTreeUpdater.cpp
r237468 r238280 680 680 if (!WKObservingContentChanges()) 681 681 return; 682 if (m_element.isInUserAgentShadowTree()) 683 return; 682 684 683 auto* style = m_element.renderStyle(); 685 if (!style) 684 685 auto qualifiesForVisibilityCheck = [&] { 686 if (!style) 687 return false; 688 if (m_element.isInUserAgentShadowTree()) 689 return false; 690 if (!const_cast<Element&>(m_element).willRespondToMouseClickEvents()) 691 return false; 692 return true; 693 }; 694 695 if (!qualifiesForVisibilityCheck()) 686 696 return; 687 697 if ((m_previousDisplay == DisplayType::None && style->display() != DisplayType::None) || (m_previousVisibility == Visibility::Hidden && style->visibility() != Visibility::Hidden)
Note:
See TracChangeset
for help on using the changeset viewer.