Style Context listing should include the SC parent

RESOLVED FIXED in mozilla0.9.7

Status

()

Core
CSS Parsing and Computation
P3
normal
RESOLVED FIXED
17 years ago
15 years ago

People

(Reporter: Marc Attinasi, Assigned: Marc Attinasi)

Tracking

Trunk
mozilla0.9.7
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [whitebox])

(Assignee)

Description

17 years ago
Trying to track the style context tree from Viewer's 'Dump Style Contexts'
command is difficult without the SC parent. I added the mParent to the list
method to make it easier.

Index: nsStyleContext.cpp
===================================================================
RCS file: /cvsroot/mozilla/content/base/src/nsStyleContext.cpp,v
retrieving revision 3.186
diff -r3.186 nsStyleContext.cpp
911c911
<   fprintf(out, "%p(%d) ", (void*)this, mRefCnt);
---
>   fprintf(out, "%p(%d) parent=%p ", (void*)this, mRefCnt, (void *)mParent);
(Assignee)

Comment 1

17 years ago
Anyone wanna review this so I can check it in (DEBUG only)?
Status: NEW → ASSIGNED
Priority: -- → P3
Target Milestone: --- → mozilla0.9.7
r=dbaron, although could you add "diff -u" to your .cvsrc so you always get
unified diffs?  (That even works on windows, if you put the .cvsrc in the right
place.)
(Assignee)

Comment 3

16 years ago
Thanks for the tip david. BTW: the right place on Windows is the $HOME
directory, where the .cvspass file is stored.

*Unified diff*
Index: nsStyleContext.cpp
===================================================================
RCS file: /cvsroot/mozilla/content/base/src/nsStyleContext.cpp,v
retrieving revision 3.186
diff -u -r3.186 nsStyleContext.cpp
--- nsStyleContext.cpp  14 Nov 2001 08:29:11 -0000      3.186
+++ nsStyleContext.cpp  5 Dec 2001 20:47:20 -0000
@@ -908,7 +908,7 @@
   // Indent
   PRInt32 ix;
   for (ix = aIndent; --ix >= 0; ) fputs("  ", out);
-  fprintf(out, "%p(%d) ", (void*)this, mRefCnt);
+  fprintf(out, "%p(%d) parent=%p ", (void*)this, mRefCnt, (void *)mParent);
   if (nsnull != mPseudoTag) {
     nsAutoString  buffer;
     mPseudoTag->ToString(buffer);

Comment 4

16 years ago
sr=kin
(Assignee)

Comment 5

16 years ago
Fixed:
Checking in nsStyleContext.cpp;
/cvsroot/mozilla/content/base/src/nsStyleContext.cpp,v  <--  nsStyleContext.cpp
new revision: 3.189; previous revision: 3.188
Status: ASSIGNED → RESOLVED
Last Resolved: 16 years ago
Resolution: --- → FIXED

Updated

15 years ago
Whiteboard: [whitebox]
You need to log in before you can comment on or make changes to this bug.