Bug 1264837 Part 21 - Remove nsSVGForeignObjectFrameBase.
MozReview-Commit-ID: IP7Z43hrcbc
--- a/layout/svg/nsSVGForeignObjectFrame.cpp
+++ b/layout/svg/nsSVGForeignObjectFrame.cpp
@@ -32,54 +32,54 @@ NS_NewSVGForeignObjectFrame(nsIPresShell
nsStyleContext *aContext)
{
return new (aPresShell) nsSVGForeignObjectFrame(aContext);
}
NS_IMPL_FRAMEARENA_HELPERS(nsSVGForeignObjectFrame)
nsSVGForeignObjectFrame::nsSVGForeignObjectFrame(nsStyleContext* aContext)
- : nsSVGForeignObjectFrameBase(aContext),
- mInReflow(false)
+ : nsContainerFrame(aContext)
+ , mInReflow(false)
{
AddStateBits(NS_FRAME_REFLOW_ROOT | NS_FRAME_MAY_BE_TRANSFORMED |
NS_FRAME_SVG_LAYOUT);
}
//----------------------------------------------------------------------
// nsIFrame methods
NS_QUERYFRAME_HEAD(nsSVGForeignObjectFrame)
NS_QUERYFRAME_ENTRY(nsISVGChildFrame)
-NS_QUERYFRAME_TAIL_INHERITING(nsSVGForeignObjectFrameBase)
+NS_QUERYFRAME_TAIL_INHERITING(nsContainerFrame)
void
nsSVGForeignObjectFrame::Init(nsIContent* aContent,
nsContainerFrame* aParent,
nsIFrame* aPrevInFlow)
{
NS_ASSERTION(aContent->IsSVGElement(nsGkAtoms::foreignObject),
"Content is not an SVG foreignObject!");
- nsSVGForeignObjectFrameBase::Init(aContent, aParent, aPrevInFlow);
+ nsContainerFrame::Init(aContent, aParent, aPrevInFlow);
AddStateBits(aParent->GetStateBits() & NS_STATE_SVG_CLIPPATH_CHILD);
AddStateBits(NS_FRAME_FONT_INFLATION_CONTAINER |
NS_FRAME_FONT_INFLATION_FLOW_ROOT);
if (!(mState & NS_FRAME_IS_NONDISPLAY)) {
nsSVGUtils::GetOuterSVGFrame(this)->RegisterForeignObject(this);
}
}
void nsSVGForeignObjectFrame::DestroyFrom(nsIFrame* aDestructRoot)
{
// Only unregister if we registered in the first place:
if (!(mState & NS_FRAME_IS_NONDISPLAY)) {
nsSVGUtils::GetOuterSVGFrame(this)->UnregisterForeignObject(this);
}
- nsSVGForeignObjectFrameBase::DestroyFrom(aDestructRoot);
+ nsContainerFrame::DestroyFrom(aDestructRoot);
}
nsIAtom *
nsSVGForeignObjectFrame::GetType() const
{
return nsGkAtoms::svgForeignObjectFrame;
}
--- a/layout/svg/nsSVGForeignObjectFrame.h
+++ b/layout/svg/nsSVGForeignObjectFrame.h
@@ -10,20 +10,18 @@
#include "nsContainerFrame.h"
#include "nsIPresShell.h"
#include "nsISVGChildFrame.h"
#include "nsRegion.h"
#include "nsSVGUtils.h"
class gfxContext;
-typedef nsContainerFrame nsSVGForeignObjectFrameBase;
-
-class nsSVGForeignObjectFrame : public nsSVGForeignObjectFrameBase,
- public nsISVGChildFrame
+class nsSVGForeignObjectFrame : public nsContainerFrame
+ , public nsISVGChildFrame
{
friend nsContainerFrame*
NS_NewSVGForeignObjectFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
protected:
explicit nsSVGForeignObjectFrame(nsStyleContext* aContext);
public:
NS_DECL_QUERYFRAME
@@ -55,17 +53,17 @@ public:
* Get the "type" of the frame
*
* @see nsGkAtoms::svgForeignObjectFrame
*/
virtual nsIAtom* GetType() const override;
virtual bool IsFrameOfType(uint32_t aFlags) const override
{
- return nsSVGForeignObjectFrameBase::IsFrameOfType(aFlags &
+ return nsContainerFrame::IsFrameOfType(aFlags &
~(nsIFrame::eSVG | nsIFrame::eSVGForeignObject));
}
virtual bool IsSVGTransformed(Matrix *aOwnTransform,
Matrix *aFromParentTransform) const override;
#ifdef DEBUG_FRAME_DUMP
virtual nsresult GetFrameName(nsAString& aResult) const override