Bug 1223228 - Remove unused nsFrameManagerBase::mStyleSet. r=dholbert

This commit is contained in:
Cameron McCormack 2015-11-10 12:27:47 +11:00
parent 95d123a5d7
commit edcec9eefe
6 changed files with 6 additions and 13 deletions

View File

@ -1453,10 +1453,9 @@ MoveChildrenTo(nsPresContext* aPresContext,
//----------------------------------------------------------------------
nsCSSFrameConstructor::nsCSSFrameConstructor(nsIDocument *aDocument,
nsIPresShell *aPresShell,
nsStyleSet* aStyleSet)
: nsFrameManager(aPresShell, aStyleSet)
nsCSSFrameConstructor::nsCSSFrameConstructor(nsIDocument* aDocument,
nsIPresShell* aPresShell)
: nsFrameManager(aPresShell)
, mDocument(aDocument)
, mRootElementFrame(nullptr)
, mRootElementStyleFrame(nullptr)

View File

@ -55,8 +55,7 @@ public:
friend class mozilla::RestyleManager;
nsCSSFrameConstructor(nsIDocument *aDocument, nsIPresShell* aPresShell,
nsStyleSet* aStyleSet);
nsCSSFrameConstructor(nsIDocument* aDocument, nsIPresShell* aPresShell);
~nsCSSFrameConstructor(void) {
NS_ASSERTION(mUpdateCount == 0, "Dying in the middle of our own update?");
}

View File

@ -78,7 +78,6 @@ static const PLDHashTableOps PlaceholderMapOps = {
nsFrameManagerBase::nsFrameManagerBase()
: mPresShell(nullptr)
, mStyleSet(nullptr)
, mRootFrame(nullptr)
, mPlaceholderMap(&PlaceholderMapOps, sizeof(PlaceholderMapEntry))
, mUndisplayedMap(nullptr)

View File

@ -82,11 +82,9 @@ class nsFrameManager : public nsFrameManagerBase
typedef mozilla::layout::FrameChildListID ChildListID;
public:
nsFrameManager(nsIPresShell *aPresShell, nsStyleSet* aStyleSet) {
explicit nsFrameManager(nsIPresShell* aPresShell) {
mPresShell = aPresShell;
mStyleSet = aStyleSet;
MOZ_ASSERT(mPresShell, "need a pres shell");
MOZ_ASSERT(mStyleSet, "need a style set");
}
~nsFrameManager();

View File

@ -53,8 +53,6 @@ protected:
// weak link, because the pres shell owns us
nsIPresShell* MOZ_NON_OWNING_REF mPresShell;
// the pres shell owns the style set
nsStyleSet* mStyleSet;
nsIFrame* mRootFrame;
PLDHashTable mPlaceholderMap;
UndisplayedMap* mUndisplayedMap;

View File

@ -860,7 +860,7 @@ PresShell::Init(nsIDocument* aDocument,
mViewManager = aViewManager;
// Create our frame constructor.
mFrameConstructor = new nsCSSFrameConstructor(mDocument, this, aStyleSet);
mFrameConstructor = new nsCSSFrameConstructor(mDocument, this);
mFrameManager = mFrameConstructor;