Bug 1345202 part 3: Add a few more required 'using' and #include statements in layout/svg. r?TYLin
Specifically:
- SVGGeometryFrame.cpp has several uses the type SVGGeometryElement which is
really mozilla::dom::SVGGeometryElement. So I'm adding a 'using' decl for
the 'mozilla::dom' namespace (and I'm dropping a now-unnecessary explicit
dom:: prefix from another type there).
- SVGImageContext.cpp calls several functions on nsIFrame (PresContext() &
StyleSVG() at least). So I'm adding an #include for nsIFrame.h.
- nsSVGMarkerFrame.cpp uses the type SVGGeometryFrame, which is really
mozilla::SVGGeometryFrame. So I'm adding a 'using' decl for
the 'mozilla' namespace.
MozReview-Commit-ID: AlCrocHhPtr
--- a/layout/svg/SVGGeometryFrame.cpp
+++ b/layout/svg/SVGGeometryFrame.cpp
@@ -25,16 +25,17 @@
#include "SVGGeometryElement.h"
#include "nsSVGUtils.h"
#include "mozilla/ArrayUtils.h"
#include "SVGAnimatedTransformList.h"
#include "SVGContentUtils.h"
#include "SVGGraphicsElement.h"
using namespace mozilla;
+using namespace mozilla::dom;
using namespace mozilla::gfx;
using namespace mozilla::image;
//----------------------------------------------------------------------
// Implementation
nsIFrame*
NS_NewSVGGeometryFrame(nsIPresShell* aPresShell,
@@ -702,17 +703,17 @@ SVGGeometryFrame::GetBBoxContribution(co
// SVGGeometryFrame methods:
gfxMatrix
SVGGeometryFrame::GetCanvasTM()
{
NS_ASSERTION(GetParent(), "null parent");
nsSVGContainerFrame *parent = static_cast<nsSVGContainerFrame*>(GetParent());
- dom::SVGGraphicsElement *content = static_cast<dom::SVGGraphicsElement*>(mContent);
+ SVGGraphicsElement *content = static_cast<SVGGraphicsElement*>(mContent);
return content->PrependLocalTransformsTo(parent->GetCanvasTM());
}
SVGGeometryFrame::MarkerProperties
SVGGeometryFrame::GetMarkerProperties(SVGGeometryFrame *aFrame)
{
NS_ASSERTION(!aFrame->GetPrevContinuation(), "aFrame should be first continuation");
--- a/layout/svg/SVGImageContext.cpp
+++ b/layout/svg/SVGImageContext.cpp
@@ -5,16 +5,17 @@
// Main header first:
#include "SVGImageContext.h"
// Keep others in (case-insensitive) order:
#include "gfxUtils.h"
#include "mozilla/Preferences.h"
+#include "nsIFrame.h"
#include "nsPresContext.h"
namespace mozilla {
bool
SVGImageContext::MaybeStoreContextPaint(nsIFrame* aFromFrame)
{
static bool sEnabledForContent = false;