Bug 490909: Remove old layout debugging code, patch #2: remove 'VerifyTree' & related code. r+sr=dbaron

This commit is contained in:
Daniel Holbert 2009-05-12 12:03:09 -07:00
Родитель 660a2bbe8b
Коммит 70e1c3c3f2
11 изменённых файлов: 0 добавлений и 103 удалений

Просмотреть файл

@ -7033,13 +7033,6 @@ PresShell::DoReflow(nsIFrame* target, PRBool aInterruptible)
void void
PresShell::DoVerifyReflow() PresShell::DoVerifyReflow()
{ {
if (nsIFrameDebug::GetVerifyTreeEnable()) {
nsIFrame* rootFrame = FrameManager()->GetRootFrame();
nsIFrameDebug *frameDebug = do_QueryFrame(rootFrame);
if (frameDebug) {
frameDebug->VerifyTree();
}
}
if (GetVerifyReflowEnable()) { if (GetVerifyReflowEnable()) {
// First synchronously render what we have so far so that we can // First synchronously render what we have so far so that we can
// see it. // see it.

Просмотреть файл

@ -6395,21 +6395,6 @@ nsBlockFrame::ChildIsDirty(nsIFrame* aChild)
nsBlockFrameSuper::ChildIsDirty(aChild); nsBlockFrameSuper::ChildIsDirty(aChild);
} }
//////////////////////////////////////////////////////////////////////
// Start Debugging
#ifdef NS_DEBUG
NS_IMETHODIMP
nsBlockFrame::VerifyTree() const
{
// XXX rewrite this
return NS_OK;
}
#endif
// End Debugging
//////////////////////////////////////////////////////////////////////
NS_IMETHODIMP NS_IMETHODIMP
nsBlockFrame::Init(nsIContent* aContent, nsBlockFrame::Init(nsIContent* aContent,
nsIFrame* aParent, nsIFrame* aParent,

Просмотреть файл

@ -196,7 +196,6 @@ public:
NS_IMETHOD List(FILE* out, PRInt32 aIndent) const; NS_IMETHOD List(FILE* out, PRInt32 aIndent) const;
NS_IMETHOD_(nsFrameState) GetDebugStateBits() const; NS_IMETHOD_(nsFrameState) GetDebugStateBits() const;
NS_IMETHOD GetFrameName(nsAString& aResult) const; NS_IMETHOD GetFrameName(nsAString& aResult) const;
NS_IMETHOD VerifyTree() const;
#endif #endif
#ifdef ACCESSIBILITY #ifdef ACCESSIBILITY

Просмотреть файл

@ -202,28 +202,6 @@ PRBool nsIFrameDebug::GetShowEventTargetFrameBorder()
*/ */
static PRLogModuleInfo* gLogModule; static PRLogModuleInfo* gLogModule;
static PRLogModuleInfo* gFrameVerifyTreeLogModuleInfo;
static PRBool gFrameVerifyTreeEnable = PRBool(0x55);
PRBool
nsIFrameDebug::GetVerifyTreeEnable()
{
if (gFrameVerifyTreeEnable == PRBool(0x55)) {
if (nsnull == gFrameVerifyTreeLogModuleInfo) {
gFrameVerifyTreeLogModuleInfo = PR_NewLogModule("frameverifytree");
gFrameVerifyTreeEnable = 0 != gFrameVerifyTreeLogModuleInfo->level;
}
}
return gFrameVerifyTreeEnable;
}
void
nsIFrameDebug::SetVerifyTreeEnable(PRBool aEnabled)
{
gFrameVerifyTreeEnable = aEnabled;
}
static PRLogModuleInfo* gStyleVerifyTreeLogModuleInfo; static PRLogModuleInfo* gStyleVerifyTreeLogModuleInfo;
static PRBool gStyleVerifyTreeEnable = PRBool(0x55); static PRBool gStyleVerifyTreeEnable = PRBool(0x55);
@ -4479,13 +4457,6 @@ nsFrame::DumpBaseRegressionData(nsPresContext* aPresContext, FILE* out, PRInt32
list = GetAdditionalChildListName(listIndex++); list = GetAdditionalChildListName(listIndex++);
} while (nsnull != list); } while (nsnull != list);
} }
NS_IMETHODIMP
nsFrame::VerifyTree() const
{
NS_ASSERTION(0 == (mState & NS_FRAME_IN_REFLOW), "frame is in reflow");
return NS_OK;
}
#endif #endif
/*this method may.. invalidate if the state was changed or if aForceRedraw is PR_TRUE /*this method may.. invalidate if the state was changed or if aForceRedraw is PR_TRUE

Просмотреть файл

@ -235,7 +235,6 @@ public:
NS_IMETHOD GetFrameName(nsAString& aResult) const; NS_IMETHOD GetFrameName(nsAString& aResult) const;
NS_IMETHOD_(nsFrameState) GetDebugStateBits() const; NS_IMETHOD_(nsFrameState) GetDebugStateBits() const;
NS_IMETHOD DumpRegressionData(nsPresContext* aPresContext, FILE* out, PRInt32 aIndent); NS_IMETHOD DumpRegressionData(nsPresContext* aPresContext, FILE* out, PRInt32 aIndent);
NS_IMETHOD VerifyTree() const;
#endif #endif
NS_IMETHOD SetSelected(nsPresContext* aPresContext, nsIDOMRange *aRange,PRBool aSelected, nsSpread aSpread, SelectionType aType); NS_IMETHOD SetSelected(nsPresContext* aPresContext, nsIDOMRange *aRange,PRBool aSelected, nsSpread aSpread, SelectionType aType);

Просмотреть файл

@ -180,8 +180,6 @@ public:
NS_IMETHOD BeginSwapDocShells(nsIFrame* aOther); NS_IMETHOD BeginSwapDocShells(nsIFrame* aOther);
virtual void EndSwapDocShells(nsIFrame* aOther); virtual void EndSwapDocShells(nsIFrame* aOther);
NS_IMETHOD VerifyTree() const;
// nsIReflowCallback // nsIReflowCallback
virtual PRBool ReflowFinished(); virtual PRBool ReflowFinished();
virtual void ReflowCallbackCanceled(); virtual void ReflowCallbackCanceled();
@ -646,14 +644,6 @@ nsSubDocumentFrame::ReflowCallbackCanceled()
mPostedReflowCallback = PR_FALSE; mPostedReflowCallback = PR_FALSE;
} }
NS_IMETHODIMP
nsSubDocumentFrame::VerifyTree() const
{
// XXX Completely disabled for now; once pseud-frames are reworked
// then we can turn it back on.
return NS_OK;
}
NS_IMETHODIMP NS_IMETHODIMP
nsSubDocumentFrame::AttributeChanged(PRInt32 aNameSpaceID, nsSubDocumentFrame::AttributeChanged(PRInt32 aNameSpaceID,
nsIAtom* aAttribute, nsIAtom* aAttribute,

Просмотреть файл

@ -1467,15 +1467,6 @@ nsHTMLFramesetFrame::SetBorderResize(PRInt32* aChildTypes,
} }
} }
NS_IMETHODIMP
nsHTMLFramesetFrame::VerifyTree() const
{
// XXX Completely disabled for now; once pseud-frames are reworked
// then we can turn it back on.
return NS_OK;
}
void void
nsHTMLFramesetFrame::StartMouseDrag(nsPresContext* aPresContext, nsHTMLFramesetFrame::StartMouseDrag(nsPresContext* aPresContext,
nsHTMLFramesetBorderFrame* aBorder, nsHTMLFramesetBorderFrame* aBorder,

Просмотреть файл

@ -152,8 +152,6 @@ public:
virtual PRBool IsLeaf() const; virtual PRBool IsLeaf() const;
NS_IMETHOD VerifyTree() const;
void StartMouseDrag(nsPresContext* aPresContext, void StartMouseDrag(nsPresContext* aPresContext,
nsHTMLFramesetBorderFrame* aBorder, nsHTMLFramesetBorderFrame* aBorder,
nsGUIEvent* aEvent); nsGUIEvent* aEvent);

Просмотреть файл

@ -80,21 +80,6 @@ public:
*/ */
NS_IMETHOD DumpRegressionData(nsPresContext* aPresContext, FILE* out, PRInt32 aIndent) = 0; NS_IMETHOD DumpRegressionData(nsPresContext* aPresContext, FILE* out, PRInt32 aIndent) = 0;
NS_IMETHOD VerifyTree() const = 0;
/**
* See if tree verification is enabled. To enable tree verification add
* "frameverifytree:1" to your NSPR_LOG_MODULES environment variable
* (any non-zero debug level will work). Or, call SetVerifyTreeEnable
* with PR_TRUE.
*/
static PRBool GetVerifyTreeEnable();
/**
* Set the verify-tree enable flag.
*/
static void SetVerifyTreeEnable(PRBool aEnabled);
/** /**
* See if style tree verification is enabled. To enable style tree * See if style tree verification is enabled. To enable style tree
* verification add "styleverifytree:1" to your NSPR_LOG_MODULES * verification add "styleverifytree:1" to your NSPR_LOG_MODULES

Просмотреть файл

@ -1283,13 +1283,6 @@ NS_METHOD nsTableOuterFrame::Reflow(nsPresContext* aPresContext,
return rv; return rv;
} }
#ifdef NS_DEBUG
NS_METHOD nsTableOuterFrame::VerifyTree() const
{
return NS_OK;
}
#endif
nsIAtom* nsIAtom*
nsTableOuterFrame::GetType() const nsTableOuterFrame::GetType() const
{ {

Просмотреть файл

@ -205,13 +205,6 @@ protected:
* @see nsHTMLContainerFrame::GetSkipSides */ * @see nsHTMLContainerFrame::GetSkipSides */
virtual PRIntn GetSkipSides() const; virtual PRIntn GetSkipSides() const;
#ifdef NS_DEBUG
/** overridden here to handle special caption-table relationship
* @see nsContainerFrame::VerifyTree
*/
NS_IMETHOD VerifyTree() const;
#endif
PRUint8 GetCaptionSide(); // NS_STYLE_CAPTION_SIDE_* or NO_SIDE PRUint8 GetCaptionSide(); // NS_STYLE_CAPTION_SIDE_* or NO_SIDE
PRBool HasSideCaption() { PRBool HasSideCaption() {