Bug 1426653 - Stop calling SchedulePaint uselessly when bumping the APZ focus sequence number. r?rhunt
MozReview-Commit-ID: Hq8QXLjDWL
--- a/layout/base/PresShell.cpp
+++ b/layout/base/PresShell.cpp
@@ -6900,22 +6900,20 @@ PresShell::HandleEvent(nsIFrame* aFrame,
type = SourceEventType::Key;
}
taskTracerEvent.emplace(type);
}
#endif
NS_ASSERTION(aFrame, "aFrame should be not null");
- // Update the latest focus sequence number with this new sequence number
+ // Update the latest focus sequence number with this new sequence number;
+ // the next transasction that gets sent to the compositor will carry this over
if (mAPZFocusSequenceNumber < aEvent->mFocusSequenceNumber) {
mAPZFocusSequenceNumber = aEvent->mFocusSequenceNumber;
-
- // Schedule an empty transaction to transmit this focus update
- aFrame->SchedulePaint(nsIFrame::PAINT_COMPOSITE_ONLY, false);
}
if (mIsDestroying ||
(sDisableNonTestMouseEvents && !aEvent->mFlags.mIsSynthesizedForTests &&
aEvent->HasMouseEventMessage())) {
return NS_OK;
}