Changeset 286863 in webkit
- Timestamp:
- Dec 10, 2021, 11:26:14 AM (5 years ago)
- Location:
- branches/safari-613.1.11-branch/Source/WebKit
- Files:
-
- 2 edited
-
ChangeLog (modified) (1 diff)
-
WebProcess/WebPage/MomentumEventDispatcher.cpp (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/safari-613.1.11-branch/Source/WebKit/ChangeLog
r286710 r286863 1 2021-12-10 Russell Epstein <repstein@apple.com> 2 3 Cherry-pick r286805. rdar://problem/86331680 4 5 Momentum Generator: Scroll tail hiccup only when scrolling up on 60Hz displays 6 https://bugs.webkit.org/show_bug.cgi?id=234104 7 <rdar://problem/86291413> 8 9 Reviewed by Simon Fraser. 10 11 * WebProcess/WebPage/MomentumEventDispatcher.cpp: 12 (WebKit::MomentumEventDispatcher::equalizeTailGaps): 13 Sort in the correct direction based on the sign of the first delta... 14 15 16 git-svn-id: https://svn.webkit.org/repository/webkit/trunk@286805 268f45cc-cd09-0410-ab3c-d52691b4dbfc 17 18 2021-12-09 Tim Horton <timothy_horton@apple.com> 19 20 Momentum Generator: Scroll tail hiccup only when scrolling up on 60Hz displays 21 https://bugs.webkit.org/show_bug.cgi?id=234104 22 <rdar://problem/86291413> 23 24 Reviewed by Simon Fraser. 25 26 * WebProcess/WebPage/MomentumEventDispatcher.cpp: 27 (WebKit::MomentumEventDispatcher::equalizeTailGaps): 28 Sort in the correct direction based on the sign of the first delta... 29 1 30 2021-12-08 Russell Epstein <repstein@apple.com> 2 31 -
branches/safari-613.1.11-branch/Source/WebKit/WebProcess/WebPage/MomentumEventDispatcher.cpp
r286710 r286863 409 409 auto& table = m_currentGesture.tailDeltaTable; 410 410 size_t initialTableSize = table.size(); 411 if (!initialTableSize) 412 return; 411 413 412 414 enum Axis { Horizontal, Vertical }; … … 424 426 firstZeroIndex[Vertical] = i; 425 427 } 426 427 if (auto index = firstZeroIndex[Horizontal]) 428 std::sort(deltas[Horizontal].begin(), std::next(deltas[Horizontal].begin(), index)); 429 if (auto index = firstZeroIndex[Vertical]) 430 std::sort(deltas[Vertical].begin(), std::next(deltas[Vertical].begin(), index)); 428 429 auto sortDeltas = [&] (Axis axis) { 430 if (!firstZeroIndex[axis]) 431 return; 432 433 if (deltas[axis][0] > 0) 434 std::sort(deltas[axis].begin(), std::next(deltas[axis].begin(), firstZeroIndex[axis]), std::greater<float>()); 435 else 436 std::sort(deltas[axis].begin(), std::next(deltas[axis].begin(), firstZeroIndex[axis]), std::less<float>()); 437 }; 438 439 sortDeltas(Horizontal); 440 sortDeltas(Vertical); 431 441 432 442 // GapSize is a count of contiguous frames with zero deltas.
Note:
See TracChangeset
for help on using the changeset viewer.