Bug 1781034 - Remove layout debugger's visual debugging. r=layout-reviewers,dshin

Differential Revision: https://phabricator.services.mozilla.com/D152628
This commit is contained in:
Emilio Cobos Álvarez
2022-07-26 15:06:30 +00:00
parent 8e2098ec8a
commit fe32378bf5
12 changed files with 1 additions and 221 deletions

View File

@@ -2231,12 +2231,6 @@ void PresShell::NotifyDestroyingFrame(nsIFrame* aFrame) {
mCurrentEventFrame = nullptr;
}
#ifdef DEBUG
if (aFrame == mDrawEventTargetFrame) {
mDrawEventTargetFrame = nullptr;
}
#endif
for (unsigned int i = 0; i < mCurrentEventFrameStack.Length(); i++) {
if (aFrame == mCurrentEventFrameStack.ElementAt(i)) {
// One of our stack frames was deleted. Get its content so that when we
@@ -7112,9 +7106,6 @@ nsresult PresShell::EventHandler::HandleEventUsingCoordinates(
nsresult rv = eventHandler.HandleEventWithCurrentEventInfo(
aGUIEvent, aEventStatus, true,
MOZ_KnownLive(eventTargetData.mOverrideClickTarget));
#ifdef DEBUG
eventTargetData.mPresShell->ShowEventTargetDebug();
#endif
return rv;
}
@@ -7911,11 +7902,6 @@ nsresult PresShell::EventHandler::HandleEventAtFocusedContent(
nsresult rv =
HandleEventWithCurrentEventInfo(aGUIEvent, aEventStatus, true, nullptr);
#ifdef DEBUG
mPresShell->ShowEventTargetDebug();
#endif
return rv;
}
@@ -8017,10 +8003,6 @@ nsresult PresShell::EventHandler::HandleEventWithFrameForPresShell(
HandleEventWithCurrentEventInfo(aGUIEvent, aEventStatus, true, nullptr);
}
#ifdef DEBUG
mPresShell->ShowEventTargetDebug();
#endif
return rv;
}
@@ -8052,19 +8034,6 @@ Document* PresShell::GetPrimaryContentDocument() {
return childDocShell->GetExtantDocument();
}
#ifdef DEBUG
void PresShell::ShowEventTargetDebug() {
if (nsIFrame::GetShowEventTargetFrameBorder() && GetCurrentEventFrame()) {
if (mDrawEventTargetFrame) {
mDrawEventTargetFrame->InvalidateFrame();
}
mDrawEventTargetFrame = mCurrentEventFrame;
mDrawEventTargetFrame->InvalidateFrame();
}
}
#endif
nsresult PresShell::EventHandler::HandleEventWithTarget(
WidgetEvent* aEvent, nsIFrame* aNewEventFrame, nsIContent* aNewEventContent,
nsEventStatus* aEventStatus, bool aIsHandlingNativeEvent,