зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1450099 - Add a fast-path to FindScrollThumbNode() for when the drag metrics has not been initialized. r=kats
MozReview-Commit-ID: IGhP2KW9WC --HG-- extra : rebase_source : b3d77febfb9bcbf03ae821147e8301b09e00d8f2
This commit is contained in:
Родитель
1c7db68b8d
Коммит
28afde2e13
|
@ -2553,6 +2553,12 @@ APZCTreeManager::SetLongTapEnabled(bool aLongTapEnabled)
|
|||
RefPtr<HitTestingTreeNode>
|
||||
APZCTreeManager::FindScrollThumbNode(const AsyncDragMetrics& aDragMetrics)
|
||||
{
|
||||
if (!aDragMetrics.mDirection) {
|
||||
// The AsyncDragMetrics has not been initialized yet - there will be
|
||||
// no matching node, so don't bother searching the tree.
|
||||
return RefPtr<HitTestingTreeNode>();
|
||||
}
|
||||
|
||||
RecursiveMutexAutoLock lock(mTreeLock);
|
||||
|
||||
return DepthFirstSearch<ReverseIterator>(mRootNode.get(),
|
||||
|
|
Загрузка…
Ссылка в новой задаче