Bug 330934. Set a nsIFrame's stylecontext in its constructor, to ensure that there's always one available for GetPresContext() to use even if Init hasn't been called. Patch by Marc Liddell, r+sr=roc
This commit is contained in:
@@ -68,7 +68,7 @@ class nsLegendFrame;
|
||||
class nsFieldSetFrame : public nsHTMLContainerFrame {
|
||||
public:
|
||||
|
||||
nsFieldSetFrame();
|
||||
nsFieldSetFrame(nsStyleContext* aContext);
|
||||
|
||||
NS_IMETHOD SetInitialChildList(nsPresContext* aPresContext,
|
||||
nsIAtom* aListName,
|
||||
@@ -120,13 +120,13 @@ protected:
|
||||
};
|
||||
|
||||
nsIFrame*
|
||||
NS_NewFieldSetFrame(nsIPresShell* aPresShell)
|
||||
NS_NewFieldSetFrame(nsIPresShell* aPresShell, nsStyleContext* aContext)
|
||||
{
|
||||
return new (aPresShell) nsFieldSetFrame;
|
||||
return new (aPresShell) nsFieldSetFrame(aContext);
|
||||
}
|
||||
|
||||
nsFieldSetFrame::nsFieldSetFrame()
|
||||
: nsHTMLContainerFrame()
|
||||
nsFieldSetFrame::nsFieldSetFrame(nsStyleContext* aContext)
|
||||
: nsHTMLContainerFrame(aContext)
|
||||
{
|
||||
mContentFrame = nsnull;
|
||||
mLegendFrame = nsnull;
|
||||
|
||||
Reference in New Issue
Block a user