summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNew Tobin Paradigm <email@mattatobin.com>2020-05-01 18:03:44 -0400
committerGitHub <noreply@github.com>2020-05-01 18:03:44 -0400
commit2375e5ebe9bc7ae4135e9d81e345d62dcc244305 (patch)
tree50fe1caf6e895e67497a20347f2bd7dcf7888108
parentf1f9fdabf129e15b8fd5be7d93f61533617fed2e (diff)
parent0c175b93cfe4e4bb1e399c35c9e0259b43a2dab8 (diff)
downloadUXP-2375e5ebe9bc7ae4135e9d81e345d62dcc244305.tar
UXP-2375e5ebe9bc7ae4135e9d81e345d62dcc244305.tar.gz
UXP-2375e5ebe9bc7ae4135e9d81e345d62dcc244305.tar.lz
UXP-2375e5ebe9bc7ae4135e9d81e345d62dcc244305.tar.xz
UXP-2375e5ebe9bc7ae4135e9d81e345d62dcc244305.zip
Merge pull request #1526 from MoonchildProductions/deunify_layout
De-unify layout
-rw-r--r--layout/base/MaskLayerImageCache.h1
-rw-r--r--layout/base/MobileViewportManager.h3
-rw-r--r--layout/base/PositionedEventTargeting.cpp1
-rw-r--r--layout/base/RestyleManager.cpp7
-rw-r--r--layout/base/RestyleManager.h6
-rw-r--r--layout/base/RestyleManagerBase.cpp18
-rw-r--r--layout/base/ServoRestyleManager.cpp1
-rw-r--r--layout/base/TouchManager.cpp2
-rw-r--r--layout/base/moz.build11
-rw-r--r--layout/base/nsFrameTraversal.cpp1
-rw-r--r--layout/base/nsLayoutUtils.cpp1
-rw-r--r--layout/base/nsPresShell.cpp6
-rw-r--r--layout/generic/CSSAlignUtils.h1
-rw-r--r--layout/generic/ReflowOutput.cpp2
-rw-r--r--layout/generic/RubyUtils.h1
-rw-r--r--layout/generic/ScrollSnap.h2
-rw-r--r--layout/generic/moz.build11
-rw-r--r--layout/generic/nsAbsoluteContainingBlock.cpp1
-rw-r--r--layout/generic/nsBRFrame.cpp1
-rw-r--r--layout/generic/nsContainerFrame.cpp2
-rw-r--r--layout/generic/nsFrame.cpp1
-rw-r--r--layout/generic/nsRubyBaseContainerFrame.cpp1
-rw-r--r--layout/generic/nsTextFrameUtils.cpp2
-rw-r--r--layout/generic/nsTextRunTransformations.cpp1
-rw-r--r--layout/generic/nsTextRunTransformations.h2
-rw-r--r--layout/generic/nsViewportFrame.cpp1
-rw-r--r--layout/printing/ipc/RemotePrintJobParent.cpp1
-rw-r--r--layout/printing/ipc/RemotePrintJobParent.h2
-rw-r--r--layout/printing/moz.build3
-rw-r--r--layout/printing/nsPrintData.cpp2
-rw-r--r--layout/printing/nsPrintEngine.cpp3
-rw-r--r--layout/printing/nsPrintObject.cpp4
-rw-r--r--layout/style/CSSLexer.h1
-rw-r--r--layout/style/CSSStyleSheet.cpp1
-rw-r--r--layout/style/Declaration.cpp1
-rw-r--r--layout/style/DocumentStyleRootIterator.h1
-rw-r--r--layout/style/RuleProcessorCache.cpp1
-rw-r--r--layout/style/ServoStyleSet.cpp1
-rw-r--r--layout/style/ServoStyleSheet.cpp4
-rw-r--r--layout/style/StyleRule.cpp1
-rw-r--r--layout/style/StyleSheet.cpp3
-rw-r--r--layout/style/moz.build12
-rw-r--r--layout/style/nsCSSProps.h4
-rw-r--r--layout/style/nsCSSPseudoClassList.h2
-rw-r--r--layout/style/nsCSSPseudoClasses.cpp1
-rw-r--r--layout/style/nsCSSPseudoClasses.h2
-rw-r--r--layout/style/nsCSSRules.h1
-rw-r--r--layout/style/nsCSSScanner.cpp2
-rw-r--r--layout/style/nsCSSValue.cpp7
-rw-r--r--layout/style/nsComputedDOMStyle.cpp2
-rw-r--r--layout/style/nsDOMCSSAttrDeclaration.cpp5
-rw-r--r--layout/style/nsMediaFeatures.cpp1
-rw-r--r--layout/style/nsStyleContext.cpp3
-rw-r--r--layout/style/nsStyleStruct.cpp1
-rw-r--r--layout/svg/SVGTextFrame.cpp1
-rw-r--r--layout/svg/moz.build2
-rw-r--r--layout/svg/nsFilterInstance.cpp1
-rw-r--r--layout/svg/nsISVGChildFrame.h1
-rw-r--r--layout/svg/nsSVGContainerFrame.cpp1
-rw-r--r--layout/svg/nsSVGFilterInstance.cpp1
-rw-r--r--layout/svg/nsSVGIntegrationUtils.h1
-rw-r--r--layout/svg/nsSVGMarkerFrame.cpp1
-rw-r--r--layout/svg/nsSVGOuterSVGFrame.cpp3
-rw-r--r--layout/svg/nsSVGSwitchFrame.cpp1
-rw-r--r--layout/svg/nsSVGUtils.cpp1
-rw-r--r--layout/tables/FixedTableLayoutStrategy.cpp4
-rw-r--r--layout/tables/SpanningCellSorter.cpp2
-rw-r--r--layout/tables/moz.build2
-rw-r--r--layout/tables/nsTableFrame.cpp2
-rw-r--r--layout/xul/ContainerBoxObject.h1
-rw-r--r--layout/xul/grid/moz.build2
-rw-r--r--layout/xul/moz.build4
-rw-r--r--layout/xul/nsButtonBoxFrame.cpp1
-rw-r--r--layout/xul/nsMenuBarListener.cpp1
-rw-r--r--layout/xul/nsMenuFrame.cpp1
-rw-r--r--layout/xul/nsMenuPopupFrame.cpp3
-rw-r--r--layout/xul/nsResizerFrame.h3
-rw-r--r--layout/xul/tree/moz.build2
78 files changed, 153 insertions, 48 deletions
diff --git a/layout/base/MaskLayerImageCache.h b/layout/base/MaskLayerImageCache.h
index b18fe5aa1..61881de83 100644
--- a/layout/base/MaskLayerImageCache.h
+++ b/layout/base/MaskLayerImageCache.h
@@ -10,6 +10,7 @@
#include "nsAutoPtr.h"
#include "nsPresContext.h"
#include "mozilla/gfx/Matrix.h"
+#include "mozilla/layers/ShadowLayers.h"
namespace mozilla {
diff --git a/layout/base/MobileViewportManager.h b/layout/base/MobileViewportManager.h
index 63128b281..6324a8645 100644
--- a/layout/base/MobileViewportManager.h
+++ b/layout/base/MobileViewportManager.h
@@ -7,8 +7,11 @@
#define MobileViewportManager_h_
#include "mozilla/Maybe.h"
+#include "nsIDocument.h"
#include "nsIDOMEventListener.h"
+#include "nsIDOMEventTarget.h"
#include "nsIObserver.h"
+#include "nsViewportInfo.h"
#include "Units.h"
class nsIDOMEventTarget;
diff --git a/layout/base/PositionedEventTargeting.cpp b/layout/base/PositionedEventTargeting.cpp
index 8374ab9d2..668ff2938 100644
--- a/layout/base/PositionedEventTargeting.cpp
+++ b/layout/base/PositionedEventTargeting.cpp
@@ -8,6 +8,7 @@
#include "mozilla/EventStates.h"
#include "mozilla/MouseEvents.h"
#include "mozilla/Preferences.h"
+#include "nsIContentInlines.h"
#include "nsLayoutUtils.h"
#include "nsGkAtoms.h"
#include "nsFontMetrics.h"
diff --git a/layout/base/RestyleManager.cpp b/layout/base/RestyleManager.cpp
index 5c599e1ef..9e80ef7bc 100644
--- a/layout/base/RestyleManager.cpp
+++ b/layout/base/RestyleManager.cpp
@@ -241,11 +241,6 @@ RestyleManager::AnimationsWithDestroyedFrame::StopAnimationsWithoutFrame(
}
}
-static inline dom::Element*
-ElementForStyleContext(nsIContent* aParentContent,
- nsIFrame* aFrame,
- CSSPseudoElementType aPseudoType);
-
// Forwarded nsIDocumentObserver method, to handle restyling (and
// passing the notification to the frame).
void
@@ -1009,7 +1004,7 @@ RestyleManager::TryInitiatingTransition(nsPresContext* aPresContext,
return *aNewStyleContext != sc;
}
-static dom::Element*
+dom::Element*
ElementForStyleContext(nsIContent* aParentContent,
nsIFrame* aFrame,
CSSPseudoElementType aPseudoType)
diff --git a/layout/base/RestyleManager.h b/layout/base/RestyleManager.h
index 3b60b331a..dd58f4bb4 100644
--- a/layout/base/RestyleManager.h
+++ b/layout/base/RestyleManager.h
@@ -191,6 +191,7 @@ public:
MOZ_ASSERT(false, "unexpected aPseudoType");
return nullptr;
}
+
private:
RestyleManager* mRestyleManager;
AutoRestore<ReframingStyleContexts*> mRestorePointer;
@@ -880,6 +881,11 @@ private:
AutoTArray<mozilla::dom::Element*, 4> mAncestors;
};
+dom::Element*
+ElementForStyleContext(nsIContent* aParentContent,
+ nsIFrame* aFrame,
+ CSSPseudoElementType aPseudoType);
+
} // namespace mozilla
#endif /* mozilla_RestyleManager_h */
diff --git a/layout/base/RestyleManagerBase.cpp b/layout/base/RestyleManagerBase.cpp
index 1a3cae4bf..69c2d9899 100644
--- a/layout/base/RestyleManagerBase.cpp
+++ b/layout/base/RestyleManagerBase.cpp
@@ -5,8 +5,26 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "mozilla/RestyleManagerBase.h"
+#include "mozilla/RestyleManager.h"
#include "mozilla/StyleSetHandle.h"
+#include "mozilla/StyleSetHandleInlines.h" // for Ptr::HasStateDependentStyle
+#include "ActiveLayerTracker.h"
+#include "nsCSSFrameConstructor.h"
+#include "nsCSSRendering.h"
#include "nsIFrame.h"
+#include "nsIFrameInlines.h" // for IsAbsPosContainingBlock
+#include "nsPlaceholderFrame.h"
+#include "nsStyleChangeList.h"
+#include "nsStyleStructInlines.h" // for HasTransform
+#include "nsSVGEffects.h"
+#include "nsSVGIntegrationUtils.h"
+#include "nsSVGUtils.h"
+#include "nsViewportFrame.h"
+#include "StickyScrollContainer.h"
+#include "SVGTextFrame.h"
+
+using namespace mozilla;
+using namespace mozilla::layers;
namespace mozilla {
diff --git a/layout/base/ServoRestyleManager.cpp b/layout/base/ServoRestyleManager.cpp
index 0659ab857..e7b295845 100644
--- a/layout/base/ServoRestyleManager.cpp
+++ b/layout/base/ServoRestyleManager.cpp
@@ -9,6 +9,7 @@
#include "mozilla/ServoStyleSet.h"
#include "mozilla/dom/ChildIterator.h"
#include "nsContentUtils.h"
+#include "nsCSSFrameConstructor.h"
#include "nsPrintfCString.h"
#include "nsStyleChangeList.h"
diff --git a/layout/base/TouchManager.cpp b/layout/base/TouchManager.cpp
index 5167ca588..e7972d5af 100644
--- a/layout/base/TouchManager.cpp
+++ b/layout/base/TouchManager.cpp
@@ -12,6 +12,8 @@
#include "nsPresShell.h"
#include "nsView.h"
+using namespace mozilla::dom;
+
namespace mozilla {
nsDataHashtable<nsUint32HashKey, TouchManager::TouchInfo>* TouchManager::sCaptureTouchList;
diff --git a/layout/base/moz.build b/layout/base/moz.build
index afc683665..f115280ce 100644
--- a/layout/base/moz.build
+++ b/layout/base/moz.build
@@ -119,7 +119,7 @@ EXPORTS.mozilla += [
'StaticPresData.h',
]
-UNIFIED_SOURCES += [
+SOURCES += [
'AccessibleCaret.cpp',
'AccessibleCaretEventHub.cpp',
'AccessibleCaretManager.cpp',
@@ -151,9 +151,11 @@ UNIFIED_SOURCES += [
'nsLayoutDebugger.cpp',
'nsLayoutHistoryState.cpp',
'nsLayoutUtils.cpp',
+ 'nsPresArena.cpp',
'nsPresContext.cpp',
'nsPresShell.cpp',
'nsQuoteList.cpp',
+ 'nsRefreshDriver.cpp',
'nsStyleChangeList.cpp',
'nsStyleSheetService.cpp',
'PaintTracker.cpp',
@@ -169,13 +171,6 @@ UNIFIED_SOURCES += [
'ZoomConstraintsClient.cpp',
]
-# nsPresArena.cpp needs to be built separately because it uses plarena.h.
-# nsRefreshDriver.cpp needs to be built separately because of name clashes in the OS X headers
-SOURCES += [
- 'nsPresArena.cpp',
- 'nsRefreshDriver.cpp',
-]
-
if CONFIG['ENABLE_TESTS']:
DIRS += ['gtest']
diff --git a/layout/base/nsFrameTraversal.cpp b/layout/base/nsFrameTraversal.cpp
index 76dd40af1..0c6a655a2 100644
--- a/layout/base/nsFrameTraversal.cpp
+++ b/layout/base/nsFrameTraversal.cpp
@@ -10,6 +10,7 @@
#include "nsPlaceholderFrame.h"
#include "nsContainerFrame.h"
+using namespace mozilla;
class nsFrameIterator : public nsIFrameEnumerator
{
diff --git a/layout/base/nsLayoutUtils.cpp b/layout/base/nsLayoutUtils.cpp
index 7496a4946..710463a5f 100644
--- a/layout/base/nsLayoutUtils.cpp
+++ b/layout/base/nsLayoutUtils.cpp
@@ -118,6 +118,7 @@
#include "mozilla/StyleSetHandleInlines.h"
#include "RegionBuilder.h"
#include "SVGSVGElement.h"
+#include "nsDocument.h"
#ifdef MOZ_XUL
#include "nsXULPopupManager.h"
diff --git a/layout/base/nsPresShell.cpp b/layout/base/nsPresShell.cpp
index bd5125637..8b469185f 100644
--- a/layout/base/nsPresShell.cpp
+++ b/layout/base/nsPresShell.cpp
@@ -58,6 +58,7 @@
#include "nsNameSpaceManager.h" // for Pref-related rule management (bugs 22963,20760,31816)
#include "nsFrame.h"
#include "FrameLayerBuilder.h"
+#include "FrameMetrics.h" // for ViewID
#include "nsViewManager.h"
#include "nsView.h"
#include "nsCRTGlue.h"
@@ -162,11 +163,12 @@
#endif
-#include "mozilla/layers/CompositorBridgeChild.h"
#include "GeckoProfiler.h"
#include "gfxPlatform.h"
#include "Layers.h"
#include "LayerTreeInvalidation.h"
+#include "ClientLayerManager.h"
+#include "mozilla/layers/CompositorBridgeChild.h"
#include "mozilla/css/ImageLoader.h"
#include "mozilla/dom/DocumentTimeline.h"
#include "mozilla/Preferences.h"
@@ -221,6 +223,8 @@ using namespace mozilla::gfx;
using namespace mozilla::layout;
using PaintFrameFlags = nsLayoutUtils::PaintFrameFlags;
+typedef FrameMetrics::ViewID ViewID;
+
CapturingContentInfo nsIPresShell::gCaptureInfo =
{ false /* mAllowed */, false /* mPointerLock */, false /* mRetargetToElement */,
false /* mPreventDrag */ };
diff --git a/layout/generic/CSSAlignUtils.h b/layout/generic/CSSAlignUtils.h
index 3693038b2..a258f4103 100644
--- a/layout/generic/CSSAlignUtils.h
+++ b/layout/generic/CSSAlignUtils.h
@@ -9,6 +9,7 @@
#define mozilla_CSSAlignUtils_h
#include "mozilla/WritingModes.h"
+#include "ReflowInput.h"
namespace mozilla {
diff --git a/layout/generic/ReflowOutput.cpp b/layout/generic/ReflowOutput.cpp
index e64e41dc5..1c61484e7 100644
--- a/layout/generic/ReflowOutput.cpp
+++ b/layout/generic/ReflowOutput.cpp
@@ -8,6 +8,8 @@
#include "mozilla/ReflowOutput.h"
#include "mozilla/ReflowInput.h"
+using namespace mozilla;
+
void
nsOverflowAreas::UnionWith(const nsOverflowAreas& aOther)
{
diff --git a/layout/generic/RubyUtils.h b/layout/generic/RubyUtils.h
index 8c9545f70..9bba89d0b 100644
--- a/layout/generic/RubyUtils.h
+++ b/layout/generic/RubyUtils.h
@@ -10,6 +10,7 @@
#include "nsTArray.h"
#include "nsGkAtoms.h"
#include "nsCSSAnonBoxes.h"
+#include "nsIFrame.h"
#define RTC_ARRAY_SIZE 1
diff --git a/layout/generic/ScrollSnap.h b/layout/generic/ScrollSnap.h
index a2877564d..37609017b 100644
--- a/layout/generic/ScrollSnap.h
+++ b/layout/generic/ScrollSnap.h
@@ -6,6 +6,8 @@
#ifndef mozilla_layout_ScrollSnap_h_
#define mozilla_layout_ScrollSnap_h_
+#include "nsIScrollableFrame.h"
+
namespace mozilla {
namespace layers {
diff --git a/layout/generic/moz.build b/layout/generic/moz.build
index 0fe98afec..ad186ef7a 100644
--- a/layout/generic/moz.build
+++ b/layout/generic/moz.build
@@ -123,7 +123,7 @@ EXPORTS.mozilla.layout += [
'FrameChildList.h',
]
-UNIFIED_SOURCES += [
+SOURCES += [
'AsyncScrollBase.cpp',
'BlockReflowInput.cpp',
'CSSAlignUtils.cpp',
@@ -157,9 +157,11 @@ UNIFIED_SOURCES += [
'nsIntervalSet.cpp',
'nsLeafFrame.cpp',
'nsLineBox.cpp',
+ 'nsLineLayout.cpp',
'nsPageContentFrame.cpp',
'nsPageFrame.cpp',
'nsPlaceholderFrame.cpp',
+ 'nsPluginFrame.cpp',
'nsRubyBaseContainerFrame.cpp',
'nsRubyBaseFrame.cpp',
'nsRubyContentFrame.cpp',
@@ -185,13 +187,6 @@ UNIFIED_SOURCES += [
'TextOverflow.cpp',
]
-# nsLineLayout.cpp needs to be built separately because it uses plarena.h.
-# nsPluginFrame.cpp needs to be built separately because of name clashes in the OS X headers.
-SOURCES += [
- 'nsLineLayout.cpp',
- 'nsPluginFrame.cpp',
-]
-
include('/ipc/chromium/chromium-config.mozbuild')
FINAL_LIBRARY = 'xul'
diff --git a/layout/generic/nsAbsoluteContainingBlock.cpp b/layout/generic/nsAbsoluteContainingBlock.cpp
index a92a2062d..f444757e8 100644
--- a/layout/generic/nsAbsoluteContainingBlock.cpp
+++ b/layout/generic/nsAbsoluteContainingBlock.cpp
@@ -18,6 +18,7 @@
#include "nsPresContext.h"
#include "nsCSSFrameConstructor.h"
#include "nsGridContainerFrame.h"
+#include "nsPlaceholderFrame.h"
#include "mozilla/Sprintf.h"
diff --git a/layout/generic/nsBRFrame.cpp b/layout/generic/nsBRFrame.cpp
index 057210350..08c0fe3dd 100644
--- a/layout/generic/nsBRFrame.cpp
+++ b/layout/generic/nsBRFrame.cpp
@@ -6,6 +6,7 @@
/* rendering object for HTML <br> elements */
#include "nsCOMPtr.h"
+#include "nsContainerFrame.h"
#include "nsFontMetrics.h"
#include "nsFrame.h"
#include "nsPresContext.h"
diff --git a/layout/generic/nsContainerFrame.cpp b/layout/generic/nsContainerFrame.cpp
index e2537968c..3ec93b762 100644
--- a/layout/generic/nsContainerFrame.cpp
+++ b/layout/generic/nsContainerFrame.cpp
@@ -29,10 +29,12 @@
#include "nsBoxLayoutState.h"
#include "nsCSSFrameConstructor.h"
#include "nsBlockFrame.h"
+#include "nsBulletFrame.h"
#include "nsPlaceholderFrame.h"
#include "mozilla/AutoRestore.h"
#include "nsIFrameInlines.h"
#include "nsPrintfCString.h"
+#include "nsAttrValueInlines.h"
#include <algorithm>
using namespace mozilla;
diff --git a/layout/generic/nsFrame.cpp b/layout/generic/nsFrame.cpp
index ea29c6945..024cc39bd 100644
--- a/layout/generic/nsFrame.cpp
+++ b/layout/generic/nsFrame.cpp
@@ -53,6 +53,7 @@
#include "nsGkAtoms.h"
#include "nsHtml5Atoms.h"
#include "nsCSSAnonBoxes.h"
+#include "nsGenericHTMLElement.h"
#include "nsFrameTraversal.h"
#include "nsRange.h"
diff --git a/layout/generic/nsRubyBaseContainerFrame.cpp b/layout/generic/nsRubyBaseContainerFrame.cpp
index 401b7d576..566dee14f 100644
--- a/layout/generic/nsRubyBaseContainerFrame.cpp
+++ b/layout/generic/nsRubyBaseContainerFrame.cpp
@@ -22,6 +22,7 @@
#include "RubyUtils.h"
using namespace mozilla;
+using namespace mozilla::gfx;
//----------------------------------------------------------------------
diff --git a/layout/generic/nsTextFrameUtils.cpp b/layout/generic/nsTextFrameUtils.cpp
index d07400f2b..8562839cc 100644
--- a/layout/generic/nsTextFrameUtils.cpp
+++ b/layout/generic/nsTextFrameUtils.cpp
@@ -13,6 +13,8 @@
#include "nsUnicharUtils.h"
#include <algorithm>
+using namespace mozilla;
+
static bool IsDiscardable(char16_t ch, uint32_t* aFlags)
{
// Unlike IS_DISCARDABLE, we don't discard \r. \r will be ignored by gfxTextRun
diff --git a/layout/generic/nsTextRunTransformations.cpp b/layout/generic/nsTextRunTransformations.cpp
index 84d669ed6..ac3edd0b9 100644
--- a/layout/generic/nsTextRunTransformations.cpp
+++ b/layout/generic/nsTextRunTransformations.cpp
@@ -20,6 +20,7 @@
#include "IrishCasing.h"
using namespace mozilla;
+using namespace mozilla::gfx;
// Unicode characters needing special casing treatment in tr/az languages
#define LATIN_CAPITAL_LETTER_I_WITH_DOT_ABOVE 0x0130
diff --git a/layout/generic/nsTextRunTransformations.h b/layout/generic/nsTextRunTransformations.h
index 662a5d2f8..db29c7315 100644
--- a/layout/generic/nsTextRunTransformations.h
+++ b/layout/generic/nsTextRunTransformations.h
@@ -12,6 +12,8 @@
#include "gfxTextRun.h"
#include "nsStyleContext.h"
+using namespace mozilla;
+
class nsTransformedTextRun;
struct nsTransformedCharStyle final {
diff --git a/layout/generic/nsViewportFrame.cpp b/layout/generic/nsViewportFrame.cpp
index 39491a0ed..20378e766 100644
--- a/layout/generic/nsViewportFrame.cpp
+++ b/layout/generic/nsViewportFrame.cpp
@@ -16,6 +16,7 @@
#include "nsAbsoluteContainingBlock.h"
#include "GeckoProfiler.h"
#include "nsIMozBrowserFrame.h"
+#include "nsPlaceholderFrame.h"
using namespace mozilla;
typedef nsAbsoluteContainingBlock::AbsPosReflowFlags AbsPosReflowFlags;
diff --git a/layout/printing/ipc/RemotePrintJobParent.cpp b/layout/printing/ipc/RemotePrintJobParent.cpp
index 2f4dbd56e..d49927da3 100644
--- a/layout/printing/ipc/RemotePrintJobParent.cpp
+++ b/layout/printing/ipc/RemotePrintJobParent.cpp
@@ -18,7 +18,6 @@
#include "nsIDeviceContextSpec.h"
#include "nsIPrintSettings.h"
#include "nsIWebProgressListener.h"
-#include "PrintTranslator.h"
namespace mozilla {
namespace layout {
diff --git a/layout/printing/ipc/RemotePrintJobParent.h b/layout/printing/ipc/RemotePrintJobParent.h
index a96cc7eaa..752ef601e 100644
--- a/layout/printing/ipc/RemotePrintJobParent.h
+++ b/layout/printing/ipc/RemotePrintJobParent.h
@@ -13,11 +13,11 @@
#include "nsCOMPtr.h"
#include "mozilla/RefPtr.h"
#include "mozilla/UniquePtr.h"
+#include "mozilla/layout/PrintTranslator.h"
class nsDeviceContext;
class nsIPrintSettings;
class nsIWebProgressListener;
-class PrintTranslator;
namespace mozilla {
namespace layout {
diff --git a/layout/printing/moz.build b/layout/printing/moz.build
index 1a82d7cdb..745c45c4b 100644
--- a/layout/printing/moz.build
+++ b/layout/printing/moz.build
@@ -13,11 +13,12 @@ XPIDL_SOURCES += [
EXPORTS.mozilla.layout += [
'ipc/RemotePrintJobChild.h',
'ipc/RemotePrintJobParent.h',
+ 'PrintTranslator.h',
]
XPIDL_MODULE = 'layout_printing'
-UNIFIED_SOURCES += [
+SOURCES += [
'ipc/RemotePrintJobChild.cpp',
'ipc/RemotePrintJobParent.cpp',
'nsPagePrintTimer.cpp',
diff --git a/layout/printing/nsPrintData.cpp b/layout/printing/nsPrintData.cpp
index 1914f779b..d760f7f0a 100644
--- a/layout/printing/nsPrintData.cpp
+++ b/layout/printing/nsPrintData.cpp
@@ -7,9 +7,11 @@
#include "nsIStringBundle.h"
#include "nsIServiceManager.h"
+#include "nsPIDOMWindow.h"
#include "nsPrintObject.h"
#include "nsPrintPreviewListener.h"
#include "nsIWebProgressListener.h"
+#include "nsIWidget.h"
#include "mozilla/Services.h"
//-----------------------------------------------------
diff --git a/layout/printing/nsPrintEngine.cpp b/layout/printing/nsPrintEngine.cpp
index 0c455f563..732a7dc92 100644
--- a/layout/printing/nsPrintEngine.cpp
+++ b/layout/printing/nsPrintEngine.cpp
@@ -16,6 +16,7 @@
#include "nsPIDOMWindow.h"
#include "nsIDocShell.h"
#include "nsIURI.h"
+#include "nsIFile.h"
#include "nsITextToSubURI.h"
#include "nsError.h"
@@ -143,7 +144,7 @@ using namespace mozilla::dom;
#define DUMP_LAYOUT_LEVEL 9 // this turns on the dumping of each doucment's layout info
#ifndef PR_PL
-static mozilla::LazyLogModule gPrintingLog("printing")
+static mozilla::LazyLogModule gPrintingLog("printing");
#define PR_PL(_p1) MOZ_LOG(gPrintingLog, mozilla::LogLevel::Debug, _p1);
#endif
diff --git a/layout/printing/nsPrintObject.cpp b/layout/printing/nsPrintObject.cpp
index 9165374c2..fe9622a1c 100644
--- a/layout/printing/nsPrintObject.cpp
+++ b/layout/printing/nsPrintObject.cpp
@@ -6,6 +6,7 @@
#include "nsPrintObject.h"
#include "nsIContentViewer.h"
#include "nsIDOMDocument.h"
+#include "nsIDOMElement.h"
#include "nsContentUtils.h" // for nsAutoScriptBlocker
#include "nsIInterfaceRequestorUtils.h"
#include "nsPIDOMWindow.h"
@@ -14,6 +15,9 @@
#include "nsIDocShellTreeItem.h"
#include "nsIBaseWindow.h"
#include "nsIDocument.h"
+#include "nsIWidget.h"
+#include "mozilla/Unused.h"
+#include "mozilla/dom/Element.h"
//---------------------------------------------------
//-- nsPrintObject Class Impl
diff --git a/layout/style/CSSLexer.h b/layout/style/CSSLexer.h
index 8b41d2778..4eff7a528 100644
--- a/layout/style/CSSLexer.h
+++ b/layout/style/CSSLexer.h
@@ -9,6 +9,7 @@
#include "mozilla/UniquePtr.h"
#include "nsCSSScanner.h"
#include "mozilla/dom/CSSLexerBinding.h"
+#include "mozilla/dom/NonRefcountedDOMObject.h"
namespace mozilla {
namespace dom {
diff --git a/layout/style/CSSStyleSheet.cpp b/layout/style/CSSStyleSheet.cpp
index 43d47100d..40a4ee4d8 100644
--- a/layout/style/CSSStyleSheet.cpp
+++ b/layout/style/CSSStyleSheet.cpp
@@ -47,6 +47,7 @@
#include "mozilla/RuleProcessorCache.h"
#include "nsIStyleSheetLinkingElement.h"
#include "nsDOMWindowUtils.h"
+#include "nsStyleSet.h"
using namespace mozilla;
using namespace mozilla::dom;
diff --git a/layout/style/Declaration.cpp b/layout/style/Declaration.cpp
index b2de159ed..9d7ca312c 100644
--- a/layout/style/Declaration.cpp
+++ b/layout/style/Declaration.cpp
@@ -14,6 +14,7 @@
#include "mozilla/css/Declaration.h"
#include "nsPrintfCString.h"
#include "gfxFontConstants.h"
+#include "nsCSSRules.h"
#include "nsStyleUtil.h"
namespace mozilla {
diff --git a/layout/style/DocumentStyleRootIterator.h b/layout/style/DocumentStyleRootIterator.h
index 7dcdc7fa1..98d9fd32f 100644
--- a/layout/style/DocumentStyleRootIterator.h
+++ b/layout/style/DocumentStyleRootIterator.h
@@ -8,6 +8,7 @@
#define DocumentStyleRootIterator_h
#include "nsTArray.h"
+#include "mozilla/dom/Element.h"
class nsIContent;
class nsIDocument;
diff --git a/layout/style/RuleProcessorCache.cpp b/layout/style/RuleProcessorCache.cpp
index 23832c230..e2e788c56 100644
--- a/layout/style/RuleProcessorCache.cpp
+++ b/layout/style/RuleProcessorCache.cpp
@@ -13,6 +13,7 @@
#include <algorithm>
#include "nsCSSRuleProcessor.h"
#include "nsThreadUtils.h"
+#include "CSSStyleSheet.h"
using namespace mozilla;
diff --git a/layout/style/ServoStyleSet.cpp b/layout/style/ServoStyleSet.cpp
index 331e2322a..38e02e66d 100644
--- a/layout/style/ServoStyleSet.cpp
+++ b/layout/style/ServoStyleSet.cpp
@@ -6,6 +6,7 @@
#include "mozilla/ServoStyleSet.h"
+#include "ServoBindings.h"
#include "mozilla/ServoRestyleManager.h"
#include "mozilla/dom/ChildIterator.h"
#include "nsCSSAnonBoxes.h"
diff --git a/layout/style/ServoStyleSheet.cpp b/layout/style/ServoStyleSheet.cpp
index 5f2a925b5..e03ad2865 100644
--- a/layout/style/ServoStyleSheet.cpp
+++ b/layout/style/ServoStyleSheet.cpp
@@ -4,8 +4,12 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
+#include "ServoBindings.h"
#include "mozilla/ServoStyleSheet.h"
#include "mozilla/StyleBackendType.h"
+#include "CSSRuleList.h"
+
+using namespace mozilla::dom;
namespace mozilla {
diff --git a/layout/style/StyleRule.cpp b/layout/style/StyleRule.cpp
index aca97a505..8fde72534 100644
--- a/layout/style/StyleRule.cpp
+++ b/layout/style/StyleRule.cpp
@@ -36,6 +36,7 @@ class nsIDOMCSSStyleDeclaration;
class nsIDOMCSSStyleSheet;
using namespace mozilla;
+using namespace mozilla::dom;
#define NS_IF_CLONE(member_) \
PR_BEGIN_MACRO \
diff --git a/layout/style/StyleSheet.cpp b/layout/style/StyleSheet.cpp
index f125cf97e..d4bc94186 100644
--- a/layout/style/StyleSheet.cpp
+++ b/layout/style/StyleSheet.cpp
@@ -6,6 +6,7 @@
#include "mozilla/StyleSheet.h"
+#include "mozilla/dom/BindingDeclarations.h" // for Optional<>
#include "mozilla/dom/CSSRuleList.h"
#include "mozilla/dom/ShadowRoot.h"
#include "mozilla/ServoStyleSheet.h"
@@ -16,6 +17,8 @@
#include "nsIMediaList.h"
#include "nsNullPrincipal.h"
+using namespace mozilla::dom;
+
namespace mozilla {
StyleSheet::StyleSheet(StyleBackendType aType, css::SheetParsingMode aParsingMode)
diff --git a/layout/style/moz.build b/layout/style/moz.build
index 40b9fd659..74caf94df 100644
--- a/layout/style/moz.build
+++ b/layout/style/moz.build
@@ -140,7 +140,7 @@ EXPORTS.mozilla.css += [
'StyleRule.h',
]
-UNIFIED_SOURCES += [
+SOURCES += [
'AnimationCollection.cpp',
'AnimationCommon.cpp',
'CounterStyleManager.cpp',
@@ -171,6 +171,7 @@ UNIFIED_SOURCES += [
'nsCSSProps.cpp',
'nsCSSPseudoClasses.cpp',
'nsCSSPseudoElements.cpp',
+ 'nsCSSRuleProcessor.cpp',
'nsCSSRules.cpp',
'nsCSSScanner.cpp',
'nsCSSValue.cpp',
@@ -183,6 +184,7 @@ UNIFIED_SOURCES += [
'nsFontFaceUtils.cpp',
'nsHTMLCSSStyleSheet.cpp',
'nsHTMLStyleSheet.cpp',
+ 'nsLayoutStylesheetCache.cpp',
'nsMediaFeatures.cpp',
'nsNthIndexCache.cpp',
'nsROCSSPrimitiveValue.cpp',
@@ -208,14 +210,6 @@ UNIFIED_SOURCES += [
'SVGAttrAnimationRuleProcessor.cpp',
]
-# nsCSSRuleProcessor.cpp needs to be built separately because it uses plarena.h.
-# nsLayoutStylesheetCache.cpp needs to be built separately because it uses
-# nsExceptionHandler.h, which includes windows.h.
-SOURCES += [
- 'nsCSSRuleProcessor.cpp',
- 'nsLayoutStylesheetCache.cpp',
-]
-
EXTRA_COMPONENTS += [
'CSSUnprefixingService.js',
'CSSUnprefixingService.manifest',
diff --git a/layout/style/nsCSSProps.h b/layout/style/nsCSSProps.h
index e67e1d41d..aabbac07a 100644
--- a/layout/style/nsCSSProps.h
+++ b/layout/style/nsCSSProps.h
@@ -345,7 +345,7 @@ public:
// KTableEntry objects can be initialized either with an int16_t value
// or a value of an enumeration type that can fit within an int16_t.
- constexpr KTableEntry(nsCSSKeyword aKeyword, int16_t aValue)
+ KTableEntry(nsCSSKeyword aKeyword, int16_t aValue)
: mKeyword(aKeyword)
, mValue(aValue)
{
@@ -353,7 +353,7 @@ public:
template<typename T,
typename = typename std::enable_if<std::is_enum<T>::value>::type>
- constexpr KTableEntry(nsCSSKeyword aKeyword, T aValue)
+ KTableEntry(nsCSSKeyword aKeyword, T aValue)
: mKeyword(aKeyword)
, mValue(static_cast<int16_t>(aValue))
{
diff --git a/layout/style/nsCSSPseudoClassList.h b/layout/style/nsCSSPseudoClassList.h
index 12f43af5b..7f620ec32 100644
--- a/layout/style/nsCSSPseudoClassList.h
+++ b/layout/style/nsCSSPseudoClassList.h
@@ -38,6 +38,8 @@
* automatically defined to CSS_PSEUDO_CLASS.
*/
+#include "nsCSSPseudoElements.h"
+
// OUTPUT_CLASS=nsCSSPseudoClasses
// MACRO_NAME=CSS_PSEUDO_CLASS
diff --git a/layout/style/nsCSSPseudoClasses.cpp b/layout/style/nsCSSPseudoClasses.cpp
index 9b26459dd..a174525b1 100644
--- a/layout/style/nsCSSPseudoClasses.cpp
+++ b/layout/style/nsCSSPseudoClasses.cpp
@@ -13,6 +13,7 @@
#include "nsString.h"
using namespace mozilla;
+using namespace mozilla::css;
// define storage for all atoms
#define CSS_PSEUDO_CLASS(_name, _value, _flags, _pref) \
diff --git a/layout/style/nsCSSPseudoClasses.h b/layout/style/nsCSSPseudoClasses.h
index ca1cb2f39..55e5bf9d2 100644
--- a/layout/style/nsCSSPseudoClasses.h
+++ b/layout/style/nsCSSPseudoClasses.h
@@ -9,6 +9,8 @@
#define nsCSSPseudoClasses_h___
#include "nsStringFwd.h"
+#include "mozilla/CSSEnabledState.h"
+#include "nsStyleStruct.h"
// The following two flags along with the pref defines where this pseudo
// class can be used:
diff --git a/layout/style/nsCSSRules.h b/layout/style/nsCSSRules.h
index 1bd468cb6..1c6361c3e 100644
--- a/layout/style/nsCSSRules.h
+++ b/layout/style/nsCSSRules.h
@@ -41,7 +41,6 @@ namespace mozilla {
namespace dom {
class DocGroup;
-class DocGroup;
} // namespace dom
class ErrorResult;
diff --git a/layout/style/nsCSSScanner.cpp b/layout/style/nsCSSScanner.cpp
index 2110be78c..b1524a3bb 100644
--- a/layout/style/nsCSSScanner.cpp
+++ b/layout/style/nsCSSScanner.cpp
@@ -14,6 +14,8 @@
#include "mozilla/Likely.h"
#include <algorithm>
+using mozilla::IsNaN;
+
/* Character class tables and related helper functions. */
static const uint8_t IS_HEX_DIGIT = 0x01;
diff --git a/layout/style/nsCSSValue.cpp b/layout/style/nsCSSValue.cpp
index baf5b7897..0a905a055 100644
--- a/layout/style/nsCSSValue.cpp
+++ b/layout/style/nsCSSValue.cpp
@@ -6,11 +6,12 @@
/* representation of simple property values within CSS declarations */
+#include "mozilla/ArrayUtils.h"
+
#include "nsCSSValue.h"
#include "mozilla/StyleSheetInlines.h"
#include "mozilla/Likely.h"
-#include "mozilla/MemoryReporting.h"
#include "mozilla/Move.h"
#include "mozilla/css/ImageLoader.h"
#include "CSSCalc.h"
@@ -18,8 +19,6 @@
#include "imgIRequest.h"
#include "imgRequestProxy.h"
#include "nsIDocument.h"
-#include "nsIPrincipal.h"
-#include "nsCSSProps.h"
#include "nsNetUtil.h"
#include "nsPresContext.h"
#include "nsStyleUtil.h"
@@ -27,7 +26,9 @@
#include "nsStyleSet.h"
#include "nsContentUtils.h"
+
using namespace mozilla;
+using namespace mozilla::css;
static bool
IsLocalRefURL(nsStringBuffer* aString)
diff --git a/layout/style/nsComputedDOMStyle.cpp b/layout/style/nsComputedDOMStyle.cpp
index 20e5651bd..1032be651 100644
--- a/layout/style/nsComputedDOMStyle.cpp
+++ b/layout/style/nsComputedDOMStyle.cpp
@@ -54,6 +54,8 @@
using namespace mozilla;
using namespace mozilla::dom;
+typedef nsCSSProps::KTableEntry KTableEntry;
+
#if defined(DEBUG_bzbarsky) || defined(DEBUG_caillon)
#define DEBUG_ComputedDOMStyle
#endif
diff --git a/layout/style/nsDOMCSSAttrDeclaration.cpp b/layout/style/nsDOMCSSAttrDeclaration.cpp
index 7b659a8cc..652bd4ad1 100644
--- a/layout/style/nsDOMCSSAttrDeclaration.cpp
+++ b/layout/style/nsDOMCSSAttrDeclaration.cpp
@@ -10,6 +10,7 @@
#include "mozilla/css/Declaration.h"
#include "mozilla/css/StyleRule.h"
#include "mozilla/dom/Element.h"
+#include "mozilla/dom/DocGroup.h"
#include "nsIDocument.h"
#include "nsIDOMMutationEvent.h"
#include "nsIURI.h"
@@ -17,8 +18,12 @@
#include "nsWrapperCacheInlines.h"
#include "nsIFrame.h"
#include "ActiveLayerTracker.h"
+#include "ServoDeclarationBlock.h"
+#include "StyleSetHandle.h"
+#include "DeclarationBlockInlines.h"
using namespace mozilla;
+using namespace mozilla::dom;
nsDOMCSSAttributeDeclaration::nsDOMCSSAttributeDeclaration(dom::Element* aElement,
bool aIsSMILOverride)
diff --git a/layout/style/nsMediaFeatures.cpp b/layout/style/nsMediaFeatures.cpp
index 854236e51..f33f8dd33 100644
--- a/layout/style/nsMediaFeatures.cpp
+++ b/layout/style/nsMediaFeatures.cpp
@@ -19,6 +19,7 @@
#include "nsDeviceContext.h"
#include "nsIBaseWindow.h"
#include "nsIDocument.h"
+#include "nsIWidget.h"
#include "nsContentUtils.h"
#include "mozilla/StyleSheet.h"
#include "mozilla/StyleSheetInlines.h"
diff --git a/layout/style/nsStyleContext.cpp b/layout/style/nsStyleContext.cpp
index 7ad260f1b..4b1a14897 100644
--- a/layout/style/nsStyleContext.cpp
+++ b/layout/style/nsStyleContext.cpp
@@ -12,6 +12,8 @@
#include "nsCSSAnonBoxes.h"
#include "nsCSSPseudoElements.h"
#include "nsStyleConsts.h"
+#include "nsStyleStruct.h"
+#include "nsStyleStructInlines.h"
#include "nsString.h"
#include "nsPresContext.h"
#include "nsIStyleRule.h"
@@ -35,6 +37,7 @@
#include "mozilla/ReflowInput.h"
#include "nsLayoutUtils.h"
#include "nsCoord.h"
+#include "nsFontMetrics.h"
// Ensure the binding function declarations in nsStyleContext.h matches
// those in ServoBindings.h.
diff --git a/layout/style/nsStyleStruct.cpp b/layout/style/nsStyleStruct.cpp
index 72c103724..200f934c5 100644
--- a/layout/style/nsStyleStruct.cpp
+++ b/layout/style/nsStyleStruct.cpp
@@ -40,6 +40,7 @@
#include <algorithm>
using namespace mozilla;
+using namespace mozilla::dom;
static_assert((((1 << nsStyleStructID_Length) - 1) &
~(NS_STYLE_INHERIT_MASK)) == 0,
diff --git a/layout/svg/SVGTextFrame.cpp b/layout/svg/SVGTextFrame.cpp
index 6ba267ee8..ebb5298b7 100644
--- a/layout/svg/SVGTextFrame.cpp
+++ b/layout/svg/SVGTextFrame.cpp
@@ -37,6 +37,7 @@
#include "nsTextNode.h"
#include "SVGAnimatedNumberList.h"
#include "SVGContentUtils.h"
+#include "SVGContextPaint.h"
#include "SVGLengthList.h"
#include "SVGNumberList.h"
#include "SVGPathElement.h"
diff --git a/layout/svg/moz.build b/layout/svg/moz.build
index b1481f4ef..69d5d2a3b 100644
--- a/layout/svg/moz.build
+++ b/layout/svg/moz.build
@@ -21,7 +21,7 @@ EXPORTS.mozilla += [
'SVGContextPaint.h',
]
-UNIFIED_SOURCES += [
+SOURCES += [
'nsCSSClipPathInstance.cpp',
'nsCSSFilterInstance.cpp',
'nsFilterInstance.cpp',
diff --git a/layout/svg/nsFilterInstance.cpp b/layout/svg/nsFilterInstance.cpp
index fe52b8a8f..0735807ce 100644
--- a/layout/svg/nsFilterInstance.cpp
+++ b/layout/svg/nsFilterInstance.cpp
@@ -28,6 +28,7 @@
using namespace mozilla;
using namespace mozilla::dom;
using namespace mozilla::gfx;
+using namespace mozilla::image;
FilterDescription
nsFilterInstance::GetFilterDescription(nsIContent* aFilteredElement,
diff --git a/layout/svg/nsISVGChildFrame.h b/layout/svg/nsISVGChildFrame.h
index c9fd0f12a..f74ff89c0 100644
--- a/layout/svg/nsISVGChildFrame.h
+++ b/layout/svg/nsISVGChildFrame.h
@@ -8,6 +8,7 @@
#include "gfxRect.h"
#include "nsQueryFrame.h"
+#include "imgIContainer.h"
class gfxContext;
class gfxMatrix;
diff --git a/layout/svg/nsSVGContainerFrame.cpp b/layout/svg/nsSVGContainerFrame.cpp
index 750dcc9da..15af5da99 100644
--- a/layout/svg/nsSVGContainerFrame.cpp
+++ b/layout/svg/nsSVGContainerFrame.cpp
@@ -17,6 +17,7 @@
#include "SVGTextFrame.h"
using namespace mozilla;
+using namespace mozilla::image;
NS_QUERYFRAME_HEAD(nsSVGContainerFrame)
NS_QUERYFRAME_ENTRY(nsSVGContainerFrame)
diff --git a/layout/svg/nsSVGFilterInstance.cpp b/layout/svg/nsSVGFilterInstance.cpp
index 59b5a27ba..462c0098b 100644
--- a/layout/svg/nsSVGFilterInstance.cpp
+++ b/layout/svg/nsSVGFilterInstance.cpp
@@ -13,6 +13,7 @@
#include "mozilla/dom/HTMLCanvasElement.h"
#include "mozilla/dom/SVGFilterElement.h"
#include "nsReferencedElement.h"
+#include "nsSVGEffects.h"
#include "nsSVGFilterFrame.h"
#include "nsSVGUtils.h"
#include "SVGContentUtils.h"
diff --git a/layout/svg/nsSVGIntegrationUtils.h b/layout/svg/nsSVGIntegrationUtils.h
index e3eb3c5f2..471e3fb04 100644
--- a/layout/svg/nsSVGIntegrationUtils.h
+++ b/layout/svg/nsSVGIntegrationUtils.h
@@ -10,6 +10,7 @@
#include "gfxRect.h"
#include "nsRegionFwd.h"
#include "mozilla/gfx/Rect.h"
+#include "imgIContainer.h"
class gfxContext;
class gfxDrawable;
diff --git a/layout/svg/nsSVGMarkerFrame.cpp b/layout/svg/nsSVGMarkerFrame.cpp
index 93b76b17f..af19cc025 100644
--- a/layout/svg/nsSVGMarkerFrame.cpp
+++ b/layout/svg/nsSVGMarkerFrame.cpp
@@ -15,6 +15,7 @@
using namespace mozilla::dom;
using namespace mozilla::gfx;
+using namespace mozilla::image;
nsContainerFrame*
NS_NewSVGMarkerFrame(nsIPresShell* aPresShell, nsStyleContext* aContext)
diff --git a/layout/svg/nsSVGOuterSVGFrame.cpp b/layout/svg/nsSVGOuterSVGFrame.cpp
index b1ee54eb9..306b3de7a 100644
--- a/layout/svg/nsSVGOuterSVGFrame.cpp
+++ b/layout/svg/nsSVGOuterSVGFrame.cpp
@@ -18,9 +18,12 @@
#include "mozilla/dom/SVGSVGElement.h"
#include "mozilla/dom/SVGViewElement.h"
#include "nsSubDocumentFrame.h"
+#include "gfxMatrix.h"
using namespace mozilla;
using namespace mozilla::dom;
+using namespace mozilla::gfx;
+using namespace mozilla::image;
//----------------------------------------------------------------------
// Implementation helpers
diff --git a/layout/svg/nsSVGSwitchFrame.cpp b/layout/svg/nsSVGSwitchFrame.cpp
index 26e77071b..e68043228 100644
--- a/layout/svg/nsSVGSwitchFrame.cpp
+++ b/layout/svg/nsSVGSwitchFrame.cpp
@@ -11,6 +11,7 @@
#include "nsSVGUtils.h"
using namespace mozilla::gfx;
+using namespace mozilla::image;
class nsSVGSwitchFrame : public nsSVGGFrame
{
diff --git a/layout/svg/nsSVGUtils.cpp b/layout/svg/nsSVGUtils.cpp
index c3394e292..103a4ce1a 100644
--- a/layout/svg/nsSVGUtils.cpp
+++ b/layout/svg/nsSVGUtils.cpp
@@ -58,6 +58,7 @@
using namespace mozilla;
using namespace mozilla::dom;
using namespace mozilla::gfx;
+using namespace mozilla::image;
static bool sSVGPathCachingEnabled;
static bool sSVGDisplayListHitTestingEnabled;
diff --git a/layout/tables/FixedTableLayoutStrategy.cpp b/layout/tables/FixedTableLayoutStrategy.cpp
index 427765795..d69946a33 100644
--- a/layout/tables/FixedTableLayoutStrategy.cpp
+++ b/layout/tables/FixedTableLayoutStrategy.cpp
@@ -15,6 +15,10 @@
#include "nsTableCellFrame.h"
#include <algorithm>
+#include "mozilla/WritingModes.h"
+
+using namespace mozilla;
+
FixedTableLayoutStrategy::FixedTableLayoutStrategy(nsTableFrame *aTableFrame)
: nsITableLayoutStrategy(nsITableLayoutStrategy::Fixed)
, mTableFrame(aTableFrame)
diff --git a/layout/tables/SpanningCellSorter.cpp b/layout/tables/SpanningCellSorter.cpp
index c67d784bb..686b02d89 100644
--- a/layout/tables/SpanningCellSorter.cpp
+++ b/layout/tables/SpanningCellSorter.cpp
@@ -12,6 +12,8 @@
#include "nsQuickSort.h"
#include "nsIPresShell.h"
+using mozilla::fallible;
+
//#define DEBUG_SPANNING_CELL_SORTER
SpanningCellSorter::SpanningCellSorter()
diff --git a/layout/tables/moz.build b/layout/tables/moz.build
index e28e21ee0..554ffebec 100644
--- a/layout/tables/moz.build
+++ b/layout/tables/moz.build
@@ -13,7 +13,7 @@ EXPORTS += [
'nsITableCellLayout.h',
]
-UNIFIED_SOURCES += [
+SOURCES += [
'BasicTableLayoutStrategy.cpp',
'FixedTableLayoutStrategy.cpp',
'nsCellMap.cpp',
diff --git a/layout/tables/nsTableFrame.cpp b/layout/tables/nsTableFrame.cpp
index e5a48139a..648fa7ddf 100644
--- a/layout/tables/nsTableFrame.cpp
+++ b/layout/tables/nsTableFrame.cpp
@@ -41,6 +41,7 @@
#include "nsCSSFrameConstructor.h"
#include "mozilla/StyleSetHandle.h"
#include "mozilla/StyleSetHandleInlines.h"
+#include "mozilla/gfx/Helpers.h"
#include "nsDisplayList.h"
#include "nsIScrollableFrame.h"
#include "nsCSSProps.h"
@@ -48,6 +49,7 @@
#include <algorithm>
using namespace mozilla;
+using namespace mozilla::gfx;
using namespace mozilla::image;
using namespace mozilla::layout;
diff --git a/layout/xul/ContainerBoxObject.h b/layout/xul/ContainerBoxObject.h
index b3da97991..d9da164ea 100644
--- a/layout/xul/ContainerBoxObject.h
+++ b/layout/xul/ContainerBoxObject.h
@@ -8,6 +8,7 @@
#define mozilla_dom_ContainerBoxObject_h
#include "mozilla/dom/BoxObject.h"
+#include "nsIDocShell.h"
namespace mozilla {
namespace dom {
diff --git a/layout/xul/grid/moz.build b/layout/xul/grid/moz.build
index 074985aaf..049489ab2 100644
--- a/layout/xul/grid/moz.build
+++ b/layout/xul/grid/moz.build
@@ -19,7 +19,7 @@ EXPORTS += [
'nsIGridPart.h',
]
-UNIFIED_SOURCES += [
+SOURCES += [
'nsGrid.cpp',
'nsGridCell.cpp',
'nsGridLayout2.cpp',
diff --git a/layout/xul/moz.build b/layout/xul/moz.build
index 8ed304c9f..18b120b34 100644
--- a/layout/xul/moz.build
+++ b/layout/xul/moz.build
@@ -44,7 +44,7 @@ EXPORTS.mozilla.dom += [
'ScrollBoxObject.h',
]
-UNIFIED_SOURCES += [
+SOURCES += [
'BoxObject.cpp',
'nsBox.cpp',
'nsBoxFrame.cpp',
@@ -64,7 +64,7 @@ UNIFIED_SOURCES += [
]
if CONFIG['MOZ_XUL']:
- UNIFIED_SOURCES += [
+ SOURCES += [
'ContainerBoxObject.cpp',
'ListBoxObject.cpp',
'MenuBoxObject.cpp',
diff --git a/layout/xul/nsButtonBoxFrame.cpp b/layout/xul/nsButtonBoxFrame.cpp
index 45d934516..e69c91929 100644
--- a/layout/xul/nsButtonBoxFrame.cpp
+++ b/layout/xul/nsButtonBoxFrame.cpp
@@ -12,6 +12,7 @@
#include "nsPresContext.h"
#include "nsIPresShell.h"
#include "nsIDOMElement.h"
+#include "nsIDOMEvent.h"
#include "nsDisplayList.h"
#include "nsContentUtils.h"
#include "mozilla/dom/Element.h"
diff --git a/layout/xul/nsMenuBarListener.cpp b/layout/xul/nsMenuBarListener.cpp
index 0fce497b8..23df81937 100644
--- a/layout/xul/nsMenuBarListener.cpp
+++ b/layout/xul/nsMenuBarListener.cpp
@@ -21,6 +21,7 @@
#include "mozilla/BasicEvents.h"
#include "mozilla/Preferences.h"
#include "mozilla/TextEvents.h"
+#include "mozilla/dom/Event.h"
using namespace mozilla;
diff --git a/layout/xul/nsMenuFrame.cpp b/layout/xul/nsMenuFrame.cpp
index 67fcdbe43..cb12dfc0a 100644
--- a/layout/xul/nsMenuFrame.cpp
+++ b/layout/xul/nsMenuFrame.cpp
@@ -48,6 +48,7 @@
#include <algorithm>
using namespace mozilla;
+using namespace mozilla::dom;
#define NS_MENU_POPUP_LIST_INDEX 0
diff --git a/layout/xul/nsMenuPopupFrame.cpp b/layout/xul/nsMenuPopupFrame.cpp
index 6e706e49c..3f934b208 100644
--- a/layout/xul/nsMenuPopupFrame.cpp
+++ b/layout/xul/nsMenuPopupFrame.cpp
@@ -18,6 +18,7 @@
#include "nsMenuBarFrame.h"
#include "nsPopupSetFrame.h"
#include "nsPIDOMWindow.h"
+#include "nsIDOMEvent.h"
#include "nsIDOMKeyEvent.h"
#include "nsIDOMScreen.h"
#include "nsIPresShell.h"
@@ -45,6 +46,7 @@
#include "nsThemeConstants.h"
#include "nsTransitionManager.h"
#include "nsDisplayList.h"
+#include "nsIDOMXULMenuListElement.h"
#include "nsIDOMXULSelectCntrlItemEl.h"
#include "mozilla/EventDispatcher.h"
#include "mozilla/EventStateManager.h"
@@ -53,6 +55,7 @@
#include "mozilla/LookAndFeel.h"
#include "mozilla/MouseEvents.h"
#include "mozilla/dom/Element.h"
+#include "mozilla/dom/Event.h"
#include "mozilla/dom/PopupBoxObject.h"
#include <algorithm>
diff --git a/layout/xul/nsResizerFrame.h b/layout/xul/nsResizerFrame.h
index 92656bc76..41efa79a7 100644
--- a/layout/xul/nsResizerFrame.h
+++ b/layout/xul/nsResizerFrame.h
@@ -8,9 +8,12 @@
#include "mozilla/Attributes.h"
#include "mozilla/EventForwards.h"
#include "nsTitleBarFrame.h"
+#include "Units.h"
class nsIBaseWindow;
+using namespace mozilla;
+
class nsResizerFrame : public nsTitleBarFrame
{
protected:
diff --git a/layout/xul/tree/moz.build b/layout/xul/tree/moz.build
index ccac5bde9..7d150881a 100644
--- a/layout/xul/tree/moz.build
+++ b/layout/xul/tree/moz.build
@@ -27,7 +27,7 @@ EXPORTS.mozilla.dom += [
'TreeBoxObject.h'
]
-UNIFIED_SOURCES += [
+SOURCES += [
'nsTreeBodyFrame.cpp',
'nsTreeColFrame.cpp',
'nsTreeColumns.cpp',