diff --git a/content/base/src/nsObjectLoadingContent.cpp b/content/base/src/nsObjectLoadingContent.cpp index a763f5a6e3e5..e642bb12b09d 100644 --- a/content/base/src/nsObjectLoadingContent.cpp +++ b/content/base/src/nsObjectLoadingContent.cpp @@ -82,6 +82,13 @@ #include "mozilla/dom/BindingUtils.h" #include "mozilla/Telemetry.h" +#ifdef XP_WIN +// Thanks so much, Microsoft! :( +#ifdef CreateEvent +#undef CreateEvent +#endif +#endif // XP_WIN + static NS_DEFINE_CID(kAppShellCID, NS_APPSHELL_CID); using namespace mozilla; diff --git a/content/html/content/src/HTMLMediaElement.cpp b/content/html/content/src/HTMLMediaElement.cpp index 39bf5d679ec7..7de7d8586d7c 100644 --- a/content/html/content/src/HTMLMediaElement.cpp +++ b/content/html/content/src/HTMLMediaElement.cpp @@ -76,6 +76,7 @@ #include "ImageContainer.h" #include "nsIPowerManagerService.h" +#include "nsRange.h" #include #ifdef PR_LOGGING diff --git a/layout/generic/ScrollbarActivity.cpp b/layout/generic/ScrollbarActivity.cpp index ca411672da50..d88a6dbcb89c 100644 --- a/layout/generic/ScrollbarActivity.cpp +++ b/layout/generic/ScrollbarActivity.cpp @@ -6,7 +6,6 @@ #include "ScrollbarActivity.h" #include "nsIScrollbarOwner.h" #include "nsIDOMEvent.h" -#include "nsIDOMNSEvent.h" #include "nsIDOMElementCSSInlineStyle.h" #include "nsIDOMCSSStyleDeclaration.h" #include "nsIFrame.h" diff --git a/layout/generic/TextOverflow.cpp b/layout/generic/TextOverflow.cpp index 68ea7eda39db..30fd0448c01a 100644 --- a/layout/generic/TextOverflow.cpp +++ b/layout/generic/TextOverflow.cpp @@ -19,7 +19,6 @@ #include "nsRect.h" #include "nsRenderingContext.h" #include "nsTextFrame.h" -#include "nsStyleStructInlines.h" #include "mozilla/Util.h" #include "mozilla/Likely.h" diff --git a/layout/generic/TextOverflow.h b/layout/generic/TextOverflow.h index f9ecffc96d47..7c4e069a7343 100644 --- a/layout/generic/TextOverflow.h +++ b/layout/generic/TextOverflow.h @@ -8,14 +8,13 @@ #define TextOverflow_h_ #include "nsDisplayList.h" -#include "nsLineBox.h" -#include "nsStyleStruct.h" #include "nsTHashtable.h" #include "mozilla/Likely.h" #include class nsIScrollableFrame; class gfxTextRun; +class nsLineBox; namespace mozilla { namespace css { diff --git a/layout/generic/nsAbsoluteContainingBlock.cpp b/layout/generic/nsAbsoluteContainingBlock.cpp index 8e52bc421fef..3a7fdf691870 100644 --- a/layout/generic/nsAbsoluteContainingBlock.cpp +++ b/layout/generic/nsAbsoluteContainingBlock.cpp @@ -13,12 +13,9 @@ #include "nsContainerFrame.h" #include "nsGkAtoms.h" #include "nsIPresShell.h" -#include "nsHTMLParts.h" #include "nsHTMLReflowState.h" #include "nsPresContext.h" -#include "nsFrameManager.h" #include "nsCSSFrameConstructor.h" -#include "nsIDocumentInlines.h" #ifdef DEBUG #include "nsBlockFrame.h" diff --git a/layout/generic/nsBRFrame.cpp b/layout/generic/nsBRFrame.cpp index 43acb9fa6c2b..91fc3b9c184c 100644 --- a/layout/generic/nsBRFrame.cpp +++ b/layout/generic/nsBRFrame.cpp @@ -7,7 +7,6 @@ #include "nsCOMPtr.h" #include "nsFrame.h" -#include "nsHTMLParts.h" #include "nsPresContext.h" #include "nsLineLayout.h" #include "nsStyleConsts.h" @@ -17,7 +16,6 @@ //FOR SELECTION #include "nsIContent.h" -#include "nsFrameSelection.h" //END INCLUDES FOR SELECTION using namespace mozilla; diff --git a/layout/generic/nsBlockFrame.cpp b/layout/generic/nsBlockFrame.cpp index 7c9964c09345..d3790b48b813 100644 --- a/layout/generic/nsBlockFrame.cpp +++ b/layout/generic/nsBlockFrame.cpp @@ -10,7 +10,6 @@ */ #include "mozilla/DebugOnly.h" -#include "mozilla/Likely.h" #include "mozilla/Util.h" #include "nsCOMPtr.h" @@ -20,7 +19,6 @@ #include "nsBlockReflowState.h" #include "nsBulletFrame.h" #include "nsLineBox.h" -#include "nsInlineFrame.h" #include "nsLineLayout.h" #include "nsPlaceholderFrame.h" #include "nsStyleConsts.h" @@ -28,23 +26,16 @@ #include "nsPresContext.h" #include "nsIPresShell.h" #include "nsStyleContext.h" -#include "nsView.h" #include "nsHTMLParts.h" #include "nsGkAtoms.h" -#include "nsIDOMEvent.h" #include "nsGenericHTMLElement.h" #include "nsAttrValueInlines.h" #include "prprf.h" -#include "nsStyleChangeList.h" -#include "nsFrameSelection.h" #include "nsFloatManager.h" -#include "nsIntervalSet.h" #include "prenv.h" #include "plstr.h" -#include "nsGUIEvent.h" #include "nsError.h" #include "nsAutoPtr.h" -#include "nsIServiceManager.h" #include "nsIScrollableFrame.h" #include #ifdef ACCESSIBILITY @@ -54,18 +45,13 @@ #include "nsDisplayList.h" #include "nsCSSAnonBoxes.h" #include "nsCSSFrameConstructor.h" -#include "nsCSSRendering.h" -#include "FrameLayerBuilder.h" #include "nsRenderingContext.h" #include "TextOverflow.h" -#include "nsStyleStructInlines.h" #ifdef IBMBIDI #include "nsBidiPresUtils.h" #endif // IBMBIDI -#include "nsIDOMHTMLHtmlElement.h" - static const int MIN_LINES_NEEDING_CURSOR = 20; static const PRUnichar kDiscCharacter = 0x2022; diff --git a/layout/generic/nsBlockFrame.h b/layout/generic/nsBlockFrame.h index 21b4d3cec8a9..5254fd6967db 100644 --- a/layout/generic/nsBlockFrame.h +++ b/layout/generic/nsBlockFrame.h @@ -44,9 +44,7 @@ enum LineReflowStatus { class nsBlockReflowState; class nsBlockInFlowLineIterator; class nsBulletFrame; -class nsLineBox; class nsFirstLineFrame; -class nsIntervalSet; /** * Some invariants: diff --git a/layout/generic/nsBlockReflowContext.cpp b/layout/generic/nsBlockReflowContext.cpp index a73f1f0da0f3..08589a2c2125 100644 --- a/layout/generic/nsBlockReflowContext.cpp +++ b/layout/generic/nsBlockReflowContext.cpp @@ -7,17 +7,11 @@ /* class that a parent frame uses to reflow a block frame */ #include "nsBlockReflowContext.h" -#include "nsLineLayout.h" +#include "nsBlockReflowState.h" #include "nsFloatManager.h" -#include "nsPresContext.h" -#include "nsFrameManager.h" -#include "nsIContent.h" -#include "nsStyleContext.h" #include "nsContainerFrame.h" #include "nsBlockFrame.h" #include "nsLineBox.h" -#include "nsGkAtoms.h" -#include "nsCOMPtr.h" #include "nsLayoutUtils.h" #ifdef DEBUG diff --git a/layout/generic/nsBlockReflowContext.h b/layout/generic/nsBlockReflowContext.h index 8dcb7cc75649..a7fb8ff8a8b0 100644 --- a/layout/generic/nsBlockReflowContext.h +++ b/layout/generic/nsBlockReflowContext.h @@ -16,10 +16,8 @@ class nsBlockFrame; class nsBlockReflowState; struct nsHTMLReflowState; class nsLineBox; -class nsIFrame; class nsPresContext; class nsLineLayout; -struct nsStylePosition; struct nsBlockHorizontalAlign; /** diff --git a/layout/generic/nsBlockReflowState.cpp b/layout/generic/nsBlockReflowState.cpp index e483738cfc54..c572a3eb5f7d 100644 --- a/layout/generic/nsBlockReflowState.cpp +++ b/layout/generic/nsBlockReflowState.cpp @@ -6,21 +6,13 @@ /* state used in reflow of block frames */ -#include "nsBlockReflowState.h" - #include "mozilla/DebugOnly.h" -#include "nsBlockReflowContext.h" #include "nsBlockFrame.h" #include "nsLineLayout.h" #include "nsPresContext.h" -#include "nsGkAtoms.h" #include "nsIFrame.h" -#include "nsFrameManager.h" #include "mozilla/AutoRestore.h" -#include "FrameLayerBuilder.h" - -#include "nsINameSpaceManager.h" #include #ifdef DEBUG diff --git a/layout/generic/nsBlockReflowState.h b/layout/generic/nsBlockReflowState.h index 881586adcefd..6926d7b7a6cf 100644 --- a/layout/generic/nsBlockReflowState.h +++ b/layout/generic/nsBlockReflowState.h @@ -10,10 +10,10 @@ #include "nsFloatManager.h" #include "nsLineBox.h" -#include "nsFrameList.h" #include "nsHTMLReflowState.h" class nsBlockFrame; +class nsFrameList; class nsOverflowContinuationTracker; // block reflow state flags diff --git a/layout/generic/nsBulletFrame.cpp b/layout/generic/nsBulletFrame.cpp index ffb6377cd309..ad75a1b68f08 100644 --- a/layout/generic/nsBulletFrame.cpp +++ b/layout/generic/nsBulletFrame.cpp @@ -8,27 +8,19 @@ #include "nsCOMPtr.h" #include "nsBulletFrame.h" #include "nsGkAtoms.h" -#include "nsHTMLParts.h" -#include "nsContainerFrame.h" #include "nsGenericHTMLElement.h" #include "nsAttrValueInlines.h" #include "nsPresContext.h" #include "nsIPresShell.h" #include "nsIDocument.h" #include "nsRenderingContext.h" -#include "nsILoadGroup.h" -#include "nsIURL.h" -#include "nsNetUtil.h" #include "prprf.h" #include "nsDisplayList.h" #include "nsCounterManager.h" -#include "imgILoader.h" #include "imgIContainer.h" #include "imgRequestProxy.h" -#include "nsIServiceManager.h" -#include "nsIComponentManager.h" #include #ifdef ACCESSIBILITY diff --git a/layout/generic/nsBulletFrame.h b/layout/generic/nsBulletFrame.h index de8718e4eb33..70514bc07e22 100644 --- a/layout/generic/nsBulletFrame.h +++ b/layout/generic/nsBulletFrame.h @@ -10,9 +10,7 @@ #include "mozilla/Attributes.h" #include "nsFrame.h" -#include "nsStyleContext.h" -#include "imgIRequest.h" #include "imgINotificationObserver.h" class imgIContainer; diff --git a/layout/generic/nsCanvasFrame.cpp b/layout/generic/nsCanvasFrame.cpp index 41555a46f023..89cf596c706b 100644 --- a/layout/generic/nsCanvasFrame.cpp +++ b/layout/generic/nsCanvasFrame.cpp @@ -6,26 +6,22 @@ /* rendering object that goes directly inside the document's scrollbars */ #include "nsCanvasFrame.h" -#include "nsIServiceManager.h" -#include "nsHTMLParts.h" #include "nsContainerFrame.h" #include "nsCSSRendering.h" #include "nsPresContext.h" #include "nsStyleContext.h" #include "nsRenderingContext.h" -#include "nsGUIEvent.h" -#include "nsStyleConsts.h" #include "nsGkAtoms.h" -#include "nsEventStateManager.h" #include "nsIPresShell.h" -#include "nsIScrollPositionListener.h" #include "nsDisplayList.h" #include "nsCSSFrameConstructor.h" #include "nsFrameManager.h" // for focus #include "nsIScrollableFrame.h" +#ifdef DEBUG_CANVAS_FOCUS #include "nsIDocShell.h" +#endif //#define DEBUG_CANVAS_FOCUS diff --git a/layout/generic/nsCanvasFrame.h b/layout/generic/nsCanvasFrame.h index dedf8899d2a8..57348480b00c 100644 --- a/layout/generic/nsCanvasFrame.h +++ b/layout/generic/nsCanvasFrame.h @@ -12,7 +12,6 @@ #include "nsContainerFrame.h" #include "nsIScrollPositionListener.h" #include "nsDisplayList.h" -#include "nsGkAtoms.h" class nsPresContext; class nsRenderingContext; diff --git a/layout/generic/nsColumnSetFrame.cpp b/layout/generic/nsColumnSetFrame.cpp index b81213924c15..a4422666460c 100644 --- a/layout/generic/nsColumnSetFrame.cpp +++ b/layout/generic/nsColumnSetFrame.cpp @@ -6,6 +6,8 @@ /* rendering object for css3 multi-column layout */ #include "nsColumnSetFrame.h" +#include "nsCSSRendering.h" +#include "nsDisplayList.h" using namespace mozilla; using namespace mozilla::layout; diff --git a/layout/generic/nsColumnSetFrame.h b/layout/generic/nsColumnSetFrame.h index e125fdca688d..31ad6cac64b1 100644 --- a/layout/generic/nsColumnSetFrame.h +++ b/layout/generic/nsColumnSetFrame.h @@ -7,19 +7,6 @@ #include "mozilla/Attributes.h" #include "nsContainerFrame.h" -#include "nsIContent.h" -#include "nsIFrame.h" -#include "nsISupports.h" -#include "nsIAtom.h" -#include "nsPresContext.h" -#include "nsHTMLParts.h" -#include "nsGkAtoms.h" -#include "nsStyleConsts.h" -#include "nsCOMPtr.h" -#include "nsLayoutUtils.h" -#include "nsDisplayList.h" -#include "nsCSSRendering.h" -#include class nsColumnSetFrame : public nsContainerFrame { public: diff --git a/layout/generic/nsContainerFrame.cpp b/layout/generic/nsContainerFrame.cpp index 8eba88728266..3903e7578a28 100644 --- a/layout/generic/nsContainerFrame.cpp +++ b/layout/generic/nsContainerFrame.cpp @@ -8,37 +8,26 @@ #include "nsContainerFrame.h" #include "nsAbsoluteContainingBlock.h" -#include "nsIContent.h" #include "nsIDocument.h" #include "nsPresContext.h" #include "nsStyleContext.h" #include "nsRect.h" #include "nsPoint.h" -#include "nsGUIEvent.h" #include "nsStyleConsts.h" #include "nsView.h" -#include "nsFrameManager.h" #include "nsIPresShell.h" #include "nsCOMPtr.h" #include "nsGkAtoms.h" -#include "nsCSSAnonBoxes.h" #include "nsViewManager.h" #include "nsIWidget.h" -#include "nsGfxCIID.h" -#include "nsIServiceManager.h" #include "nsCSSRendering.h" -#include "nsTransform2D.h" -#include "nsRegion.h" #include "nsError.h" #include "nsDisplayList.h" -#include "nsListControlFrame.h" #include "nsIBaseWindow.h" -#include "nsThemeConstants.h" #include "nsBoxLayoutState.h" -#include "nsRenderingContext.h" #include "nsCSSFrameConstructor.h" +#include "nsBlockFrame.h" #include "mozilla/AutoRestore.h" -#include "mozilla/dom/Element.h" #include #ifdef DEBUG diff --git a/layout/generic/nsFirstLetterFrame.cpp b/layout/generic/nsFirstLetterFrame.cpp index 3740eab87654..576152dc72fd 100644 --- a/layout/generic/nsFirstLetterFrame.cpp +++ b/layout/generic/nsFirstLetterFrame.cpp @@ -5,7 +5,6 @@ /* rendering object for CSS :first-letter pseudo-element */ -#include "nsCOMPtr.h" #include "nsFirstLetterFrame.h" #include "nsPresContext.h" #include "nsStyleContext.h" diff --git a/layout/generic/nsFlexContainerFrame.cpp b/layout/generic/nsFlexContainerFrame.cpp index a40b92dd4e0b..c377f9bba6bf 100644 --- a/layout/generic/nsFlexContainerFrame.cpp +++ b/layout/generic/nsFlexContainerFrame.cpp @@ -993,7 +993,6 @@ private: // Utility class for managing our position along the cross axis along // the whole flex container (at a higher level than a single line) -class SingleLineCrossAxisPositionTracker; class MOZ_STACK_CLASS CrossAxisPositionTracker : public PositionTracker { public: CrossAxisPositionTracker(nsFlexContainerFrame* aFlexContainerFrame, diff --git a/layout/generic/nsFlexContainerFrame.h b/layout/generic/nsFlexContainerFrame.h index 618187c878d0..2661b740bc1f 100644 --- a/layout/generic/nsFlexContainerFrame.h +++ b/layout/generic/nsFlexContainerFrame.h @@ -11,8 +11,6 @@ #define nsFlexContainerFrame_h___ #include "nsContainerFrame.h" -#include "nsTArray.h" -#include "mozilla/Types.h" nsIFrame* NS_NewFlexContainerFrame(nsIPresShell* aPresShell, nsStyleContext* aContext); @@ -23,6 +21,7 @@ class FlexItem; class FlexboxAxisTracker; class MainAxisPositionTracker; class SingleLineCrossAxisPositionTracker; +template class nsTArray; class nsFlexContainerFrame : public nsFlexContainerFrameSuper { NS_DECL_FRAMEARENA_HELPERS diff --git a/layout/generic/nsFontInflationData.cpp b/layout/generic/nsFontInflationData.cpp index 2675925586f8..89260ab52ac6 100644 --- a/layout/generic/nsFontInflationData.cpp +++ b/layout/generic/nsFontInflationData.cpp @@ -7,8 +7,6 @@ #include "nsFontInflationData.h" #include "FramePropertyTable.h" -#include "nsTextFragment.h" -#include "nsIFormControlFrame.h" #include "nsTextControlFrame.h" #include "nsListControlFrame.h" #include "nsComboboxControlFrame.h" diff --git a/layout/generic/nsFontInflationData.h b/layout/generic/nsFontInflationData.h index b7378d93da92..59cb23619ae6 100644 --- a/layout/generic/nsFontInflationData.h +++ b/layout/generic/nsFontInflationData.h @@ -9,8 +9,6 @@ #define nsFontInflationData_h_ #include "nsIFrame.h" -#include "nsLayoutUtils.h" -#include "nsBlockFrame.h" struct nsHTMLReflowState; diff --git a/layout/generic/nsFrame.cpp b/layout/generic/nsFrame.cpp index 4b0c016d6795..6a9285d3929a 100644 --- a/layout/generic/nsFrame.cpp +++ b/layout/generic/nsFrame.cpp @@ -13,7 +13,6 @@ #include "nsFrame.h" #include "nsFrameList.h" #include "nsPlaceholderFrame.h" -#include "nsLineLayout.h" #include "nsIContent.h" #include "nsContentUtils.h" #include "nsIAtom.h" @@ -25,9 +24,7 @@ #include "nsViewManager.h" #include "nsIScrollableFrame.h" #include "nsPresContext.h" -#include "nsCRT.h" #include "nsGUIEvent.h" -#include "nsIDOMEvent.h" #include "nsAsyncDOMEvent.h" #include "nsStyleConsts.h" #include "nsIPresShell.h" @@ -35,7 +32,6 @@ #include "prprf.h" #include #include "nsFrameManager.h" -#include "nsCSSRendering.h" #include "nsLayoutUtils.h" #include "nsIDOMNode.h" @@ -43,17 +39,11 @@ #include "nsISelection.h" #include "nsISelectionPrivate.h" #include "nsFrameSelection.h" -#include "nsHTMLParts.h" #include "nsGkAtoms.h" #include "nsCSSAnonBoxes.h" -#include "nsCSSPseudoElements.h" -#include "nsCSSFrameConstructor.h" #include "nsFrameTraversal.h" -#include "nsStyleChangeList.h" -#include "nsIDOMRange.h" #include "nsRange.h" -#include "nsITableCellLayout.h"// " #include "nsITextControlFrame.h" #include "nsINameSpaceManager.h" #include "nsIPercentHeightObserver.h" @@ -65,33 +55,25 @@ #endif // For triple-click pref -#include "nsIServiceManager.h" #include "imgIContainer.h" #include "imgIRequest.h" -#include "nsLayoutCID.h" -#include "nsUnicharUtils.h" #include "nsError.h" #include "nsContainerFrame.h" #include "nsBoxLayoutState.h" #include "nsBlockFrame.h" #include "nsDisplayList.h" -#include "nsIObjectLoadingContent.h" #include "nsExpirationTracker.h" #include "nsSVGIntegrationUtils.h" #include "nsSVGEffects.h" #include "nsChangeHint.h" #include "nsDeckFrame.h" -#include "nsTableFrame.h" #include "nsSubDocumentFrame.h" #include "nsSVGTextFrame2.h" #include "gfxContext.h" #include "nsRenderingContext.h" -#include "CSSCalc.h" #include "nsAbsoluteContainingBlock.h" #include "nsFontInflationData.h" -#include "nsAnimationManager.h" -#include "nsTransitionManager.h" #include "mozilla/Preferences.h" #include "mozilla/LookAndFeel.h" diff --git a/layout/generic/nsFrame.h b/layout/generic/nsFrame.h index b466c5a0a22b..bca3b109ab73 100644 --- a/layout/generic/nsFrame.h +++ b/layout/generic/nsFrame.h @@ -12,14 +12,12 @@ #include "mozilla/Likely.h" #include "nsBox.h" #include "nsRect.h" -#include "nsString.h" #include "prlog.h" #include "nsIPresShell.h" -#include "nsFrameSelection.h" #include "nsHTMLReflowState.h" -#include "nsHTMLReflowMetrics.h" #include "nsHTMLParts.h" +#include "nsISelectionDisplay.h" /** * nsFrame logging constants. We redefine the nspr diff --git a/layout/generic/nsFrameList.cpp b/layout/generic/nsFrameList.cpp index 7a63edec6b13..46a17cb1ada6 100644 --- a/layout/generic/nsFrameList.cpp +++ b/layout/generic/nsFrameList.cpp @@ -10,7 +10,6 @@ #include "nsIPresShell.h" #ifdef IBMBIDI -#include "nsCOMPtr.h" #include "nsGkAtoms.h" #include "nsILineIterator.h" #include "nsBidiPresUtils.h" diff --git a/layout/generic/nsFrameList.h b/layout/generic/nsFrameList.h index 006747cf566f..ec32f762914e 100644 --- a/layout/generic/nsFrameList.h +++ b/layout/generic/nsFrameList.h @@ -6,15 +6,13 @@ #ifndef nsFrameList_h___ #define nsFrameList_h___ -#include "nscore.h" -#include "nsTraceRefcnt.h" #include /* for FILE* */ #include "nsDebug.h" -#include "nsTArray.h" class nsIFrame; class nsIPresShell; class nsPresContext; +template class nsTArray; namespace mozilla { namespace layout { diff --git a/layout/generic/nsFrameSetFrame.cpp b/layout/generic/nsFrameSetFrame.cpp index 0ff16fb649a1..03b97ee4f68d 100644 --- a/layout/generic/nsFrameSetFrame.cpp +++ b/layout/generic/nsFrameSetFrame.cpp @@ -8,7 +8,6 @@ #include "mozilla/DebugOnly.h" #include "mozilla/Likely.h" -#include "nsCOMPtr.h" #include "nsFrameSetFrame.h" #include "nsGenericHTMLElement.h" #include "nsAttrValueInlines.h" @@ -16,22 +15,12 @@ #include "nsContainerFrame.h" #include "nsPresContext.h" #include "nsIPresShell.h" -#include "nsIComponentManager.h" -#include "nsIStreamListener.h" -#include "nsIURL.h" -#include "nsIDocument.h" -#include "nsINodeInfo.h" -#include "nsView.h" -#include "nsViewManager.h" -#include "nsWidgetsCID.h" #include "nsGkAtoms.h" -#include "nsStyleCoord.h" #include "nsStyleConsts.h" #include "nsStyleContext.h" #include "nsHTMLParts.h" #include "nsGUIEvent.h" #include "nsRenderingContext.h" -#include "nsIServiceManager.h" #include "nsIDOMMutationEvent.h" #include "nsINameSpaceManager.h" #include "nsCSSAnonBoxes.h" diff --git a/layout/generic/nsFrameSetFrame.h b/layout/generic/nsFrameSetFrame.h index a9edde62fc38..fd693ba3e5f5 100644 --- a/layout/generic/nsFrameSetFrame.h +++ b/layout/generic/nsFrameSetFrame.h @@ -9,16 +9,11 @@ #define nsHTMLFrameset_h___ #include "mozilla/Attributes.h" -#include "nsGkAtoms.h" #include "nsContainerFrame.h" #include "nsColor.h" -#include "nsIObserver.h" -#include "nsWeakPtr.h" class nsIContent; -class nsIFrame; class nsPresContext; -class nsRenderingContext; struct nsRect; struct nsHTMLReflowState; struct nsSize; diff --git a/layout/generic/nsGfxScrollFrame.cpp b/layout/generic/nsGfxScrollFrame.cpp index a3edadb91b39..acf5dd0ad252 100644 --- a/layout/generic/nsGfxScrollFrame.cpp +++ b/layout/generic/nsGfxScrollFrame.cpp @@ -7,12 +7,9 @@ #include "base/compiler_specific.h" #include "nsCOMPtr.h" -#include "nsHTMLParts.h" #include "nsPresContext.h" -#include "nsIServiceManager.h" #include "nsView.h" #include "nsIScrollable.h" -#include "nsViewManager.h" #include "nsContainerFrame.h" #include "nsGfxScrollFrame.h" #include "nsGkAtoms.h" @@ -20,7 +17,6 @@ #include "nsContentList.h" #include "nsIDocumentInlines.h" #include "nsFontMetrics.h" -#include "nsIDocumentObserver.h" #include "nsBoxLayoutState.h" #include "nsINodeInfo.h" #include "nsScrollbarFrame.h" @@ -28,24 +24,19 @@ #include "nsITextControlFrame.h" #include "nsIDOMHTMLTextAreaElement.h" #include "nsNodeInfoManager.h" -#include "nsIURI.h" #include "nsGUIEvent.h" #include "nsContentCreatorFunctions.h" -#include "nsISupportsPrimitives.h" #include "nsAutoPtr.h" #include "nsPresState.h" -#include "nsDocShellCID.h" #include "nsIHTMLDocument.h" #include "nsEventDispatcher.h" #include "nsContentUtils.h" #include "nsLayoutUtils.h" #include "nsBidiUtils.h" -#include "nsFrameManager.h" #include "mozilla/Preferences.h" #include "mozilla/LookAndFeel.h" #include "mozilla/dom/Element.h" #include -#include "mozilla/Util.h" #include "mozilla/MathAlgorithms.h" #include "FrameLayerBuilder.h" #include "nsSMILKeySpline.h" @@ -54,8 +45,9 @@ #include "mozilla/Attributes.h" #include "ScrollbarActivity.h" #include "nsRefreshDriver.h" -#include "nsContentList.h" #include "nsThemeConstants.h" +#include "nsSVGIntegrationUtils.h" +#include "nsIScrollPositionListener.h" #include #include // for std::abs(int/long) #include // for std::abs(float/double) diff --git a/layout/generic/nsGfxScrollFrame.h b/layout/generic/nsGfxScrollFrame.h index a45271f7e0ce..b145d1a2f43f 100644 --- a/layout/generic/nsGfxScrollFrame.h +++ b/layout/generic/nsGfxScrollFrame.h @@ -12,25 +12,21 @@ #include "nsContainerFrame.h" #include "nsIAnonymousContentCreator.h" #include "nsBoxFrame.h" -#include "nsDisplayList.h" #include "nsIScrollableFrame.h" -#include "nsIScrollPositionListener.h" #include "nsIStatefulFrame.h" #include "nsThreadUtils.h" #include "nsIReflowCallback.h" #include "nsBoxLayoutState.h" #include "nsQueryFrame.h" -#include "nsCOMArray.h" -#include "nsSVGIntegrationUtils.h" #include "nsExpirationTracker.h" class nsPresContext; class nsIPresShell; class nsIContent; class nsIAtom; -class nsIDocument; class nsIScrollFrameInternal; class nsPresState; +class nsIScrollPositionListener; struct ScrollReflowState; namespace mozilla { diff --git a/layout/generic/nsHTMLCanvasFrame.cpp b/layout/generic/nsHTMLCanvasFrame.cpp index bd3828a437f8..d75fe3ea69ca 100644 --- a/layout/generic/nsHTMLCanvasFrame.cpp +++ b/layout/generic/nsHTMLCanvasFrame.cpp @@ -5,20 +5,13 @@ /* rendering object for the HTML element */ -#include "nsHTMLParts.h" -#include "nsCOMPtr.h" -#include "nsIServiceManager.h" #include "nsGkAtoms.h" - #include "nsHTMLCanvasFrame.h" #include "mozilla/dom/HTMLCanvasElement.h" #include "nsDisplayList.h" #include "nsLayoutUtils.h" #include "Layers.h" -#include "nsTransform2D.h" - -#include "gfxContext.h" #include using namespace mozilla; diff --git a/layout/generic/nsHTMLCanvasFrame.h b/layout/generic/nsHTMLCanvasFrame.h index 363b6457d659..1601ba06775c 100644 --- a/layout/generic/nsHTMLCanvasFrame.h +++ b/layout/generic/nsHTMLCanvasFrame.h @@ -10,9 +10,6 @@ #include "mozilla/Attributes.h" #include "nsContainerFrame.h" -#include "nsString.h" -#include "nsAString.h" -#include "nsIIOService.h" #include "FrameLayerBuilder.h" namespace mozilla { @@ -24,6 +21,7 @@ class LayerManager; class nsPresContext; class nsDisplayItem; +class nsAString; nsIFrame* NS_NewHTMLCanvasFrame (nsIPresShell* aPresShell, nsStyleContext* aContext); diff --git a/layout/generic/nsHTMLReflowMetrics.h b/layout/generic/nsHTMLReflowMetrics.h index a7f796f2ee37..e219fe06a3f4 100644 --- a/layout/generic/nsHTMLReflowMetrics.h +++ b/layout/generic/nsHTMLReflowMetrics.h @@ -8,9 +8,6 @@ #ifndef nsHTMLReflowMetrics_h___ #define nsHTMLReflowMetrics_h___ -#include -#include "nsISupports.h" -#include "nsMargin.h" #include "nsRect.h" #include "nsBoundingMetrics.h" diff --git a/layout/generic/nsHTMLReflowState.cpp b/layout/generic/nsHTMLReflowState.cpp index 1c54e7b483cf..9ede7ffaae3e 100644 --- a/layout/generic/nsHTMLReflowState.cpp +++ b/layout/generic/nsHTMLReflowState.cpp @@ -5,7 +5,6 @@ /* struct containing the input to nsIFrame::Reflow */ -#include "nsCOMPtr.h" #include "nsStyleConsts.h" #include "nsCSSAnonBoxes.h" #include "nsFrame.h" @@ -20,11 +19,9 @@ #include "nsImageFrame.h" #include "nsTableFrame.h" #include "nsTableCellFrame.h" -#include "nsIServiceManager.h" #include "nsIPercentHeightObserver.h" #include "nsLayoutUtils.h" #include "mozilla/Preferences.h" -#include "nsBidiUtils.h" #include "nsFontInflationData.h" #include diff --git a/layout/generic/nsHTMLReflowState.h b/layout/generic/nsHTMLReflowState.h index c793f6d904d1..4bb8bf1c4f5f 100644 --- a/layout/generic/nsHTMLReflowState.h +++ b/layout/generic/nsHTMLReflowState.h @@ -20,14 +20,6 @@ class nsRenderingContext; class nsFloatManager; class nsLineLayout; class nsIPercentHeightObserver; - -struct nsStyleDisplay; -struct nsStyleVisibility; -struct nsStylePosition; -struct nsStyleBorder; -struct nsStyleMargin; -struct nsStylePadding; -struct nsStyleText; struct nsHypotheticalBox; diff --git a/layout/generic/nsImageFrame.cpp b/layout/generic/nsImageFrame.cpp index aed7a1b163af..1ce8e609f544 100644 --- a/layout/generic/nsImageFrame.cpp +++ b/layout/generic/nsImageFrame.cpp @@ -7,7 +7,6 @@ #include "mozilla/DebugOnly.h" -#include "nsHTMLParts.h" #include "nsCOMPtr.h" #include "nsImageFrame.h" #include "nsIImageLoadingContent.h" @@ -18,7 +17,6 @@ #include "nsIPresShell.h" #include "nsGkAtoms.h" #include "nsIDocument.h" -#include "nsINodeInfo.h" #include "nsContentUtils.h" #include "nsCSSAnonBoxes.h" #include "nsStyleContext.h" @@ -26,22 +24,13 @@ #include "nsStyleCoord.h" #include "nsTransform2D.h" #include "nsImageMap.h" -#include "nsILinkHandler.h" -#include "nsIURL.h" #include "nsIIOService.h" #include "nsILoadGroup.h" #include "nsISupportsPriority.h" -#include "nsIServiceManager.h" #include "nsNetUtil.h" -#include "nsContainerFrame.h" -#include "prprf.h" #include "nsCSSRendering.h" #include "nsIDOMHTMLAnchorElement.h" -#include "nsIDOMHTMLImageElement.h" #include "nsINameSpaceManager.h" -#include "nsTextFragment.h" -#include "nsIDOMHTMLMapElement.h" -#include "nsIScriptSecurityManager.h" #include #ifdef ACCESSIBILITY #include "nsAccessibilityService.h" @@ -58,8 +47,6 @@ #include "nsCSSFrameConstructor.h" #include "nsIDOMRange.h" -#include "nsIContentPolicy.h" -#include "nsContentPolicyUtils.h" #include "nsEventStates.h" #include "nsError.h" #include "nsBidiUtils.h" diff --git a/layout/generic/nsImageFrame.h b/layout/generic/nsImageFrame.h index d982907da171..6900a0b8f536 100644 --- a/layout/generic/nsImageFrame.h +++ b/layout/generic/nsImageFrame.h @@ -18,19 +18,16 @@ #include "imgIContainer.h" #include "mozilla/Attributes.h" -class nsIFrame; class nsImageMap; class nsIURI; class nsILoadGroup; struct nsHTMLReflowState; struct nsHTMLReflowMetrics; -struct nsSize; class nsDisplayImage; class nsPresContext; class nsImageFrame; class nsTransform2D; class nsImageLoadingContent; -class imgRequestProxy; namespace mozilla { namespace layers { diff --git a/layout/generic/nsImageMap.cpp b/layout/generic/nsImageMap.cpp index 8cc50b8e7096..ad4499d4f434 100644 --- a/layout/generic/nsImageMap.cpp +++ b/layout/generic/nsImageMap.cpp @@ -12,18 +12,11 @@ #include "nsReadableUtils.h" #include "nsRenderingContext.h" #include "nsPresContext.h" -#include "nsIURL.h" -#include "nsIServiceManager.h" -#include "nsNetUtil.h" -#include "nsTextFragment.h" #include "mozilla/dom/Element.h" -#include "nsIDocument.h" #include "nsINameSpaceManager.h" #include "nsGkAtoms.h" -#include "nsIPresShell.h" #include "nsImageFrame.h" #include "nsCoord.h" -#include "nsIConsoleService.h" #include "nsIScriptError.h" #include "nsIStringBundle.h" #include "nsContentUtils.h" diff --git a/layout/generic/nsImageMap.h b/layout/generic/nsImageMap.h index 5d7f642eba7a..9fcbc40ae6aa 100644 --- a/layout/generic/nsImageMap.h +++ b/layout/generic/nsImageMap.h @@ -8,17 +8,18 @@ #ifndef nsImageMap_h #define nsImageMap_h -#include "nsISupports.h" +#include "nsCOMPtr.h" #include "nsCoord.h" #include "nsTArray.h" #include "nsStubMutationObserver.h" #include "nsIDOMEventListener.h" -#include "nsIFrame.h" +#include "nsRect.h" class Area; -class nsIDOMEvent; class nsRenderingContext; class nsImageFrame; +class nsIFrame; +class nsIContent; class nsImageMap : public nsStubMutationObserver, public nsIDOMEventListener diff --git a/layout/generic/nsInlineFrame.cpp b/layout/generic/nsInlineFrame.cpp index 3368a01abfcd..ef40aba27374 100644 --- a/layout/generic/nsInlineFrame.cpp +++ b/layout/generic/nsInlineFrame.cpp @@ -6,14 +6,11 @@ /* rendering object for CSS display:inline objects */ #include "nsInlineFrame.h" -#include "nsCOMPtr.h" #include "nsLineLayout.h" #include "nsBlockFrame.h" #include "nsPlaceholderFrame.h" #include "nsGkAtoms.h" -#include "nsHTMLParts.h" #include "nsStyleContext.h" -#include "nsIPresShell.h" #include "nsPresContext.h" #include "nsRenderingContext.h" #include "nsCSSAnonBoxes.h" diff --git a/layout/generic/nsIntervalSet.cpp b/layout/generic/nsIntervalSet.cpp index 92cd8c2989e9..cc72a811e692 100644 --- a/layout/generic/nsIntervalSet.cpp +++ b/layout/generic/nsIntervalSet.cpp @@ -7,7 +7,6 @@ /* a set of ranges on a number-line */ #include "nsIntervalSet.h" -#include "nsAlgorithm.h" #include #include diff --git a/layout/generic/nsIntervalSet.h b/layout/generic/nsIntervalSet.h index 5f4d02b7c054..9941df447373 100644 --- a/layout/generic/nsIntervalSet.h +++ b/layout/generic/nsIntervalSet.h @@ -10,7 +10,6 @@ #define nsIntervalSet_h___ #include "nsCoord.h" -#include "nsDebug.h" typedef void * (* IntervalSetAlloc)(size_t aBytes, void *aClosure); diff --git a/layout/generic/nsLeafFrame.cpp b/layout/generic/nsLeafFrame.cpp index 52ca4484dca2..7802ae78aa7d 100644 --- a/layout/generic/nsLeafFrame.cpp +++ b/layout/generic/nsLeafFrame.cpp @@ -5,10 +5,7 @@ /* base class for rendering objects that do not have child lists */ -#include "nsCOMPtr.h" #include "nsLeafFrame.h" -#include "nsContainerFrame.h" -#include "nsHTMLParts.h" #include "nsPresContext.h" nsLeafFrame::~nsLeafFrame() diff --git a/layout/generic/nsLineBox.cpp b/layout/generic/nsLineBox.cpp index 425f3574764f..cb484a724ee4 100644 --- a/layout/generic/nsLineBox.cpp +++ b/layout/generic/nsLineBox.cpp @@ -7,15 +7,12 @@ /* representation of one line within a block frame, a CSS line box */ #include "nsLineBox.h" -#include "nsLineLayout.h" #include "prprf.h" -#include "nsBlockFrame.h" -#include "nsIFrame.h" +#include "nsFrame.h" #include "nsPresArena.h" #ifdef IBMBIDI #include "nsBidiPresUtils.h" #endif -#include "nsStyleStructInlines.h" #include "mozilla/Assertions.h" #include "mozilla/Likely.h" diff --git a/layout/generic/nsLineLayout.cpp b/layout/generic/nsLineLayout.cpp index 7b538bb91bb5..c1b089f9ec69 100644 --- a/layout/generic/nsLineLayout.cpp +++ b/layout/generic/nsLineLayout.cpp @@ -9,10 +9,8 @@ #include "plarena.h" #include "mozilla/Util.h" -#include "nsCOMPtr.h" #include "nsLineLayout.h" #include "nsBlockFrame.h" -#include "nsInlineFrame.h" #include "nsStyleConsts.h" #include "nsContainerFrame.h" #include "nsFloatManager.h" @@ -20,13 +18,9 @@ #include "nsPresContext.h" #include "nsRenderingContext.h" #include "nsGkAtoms.h" -#include "nsPlaceholderFrame.h" #include "nsIContent.h" -#include "nsTextFragment.h" -#include "nsBidiUtils.h" #include "nsLayoutUtils.h" #include "nsTextFrame.h" -#include "nsCSSRendering.h" #include #ifdef DEBUG diff --git a/layout/generic/nsLineLayout.h b/layout/generic/nsLineLayout.h index d1ce47024889..ecb3e996558a 100644 --- a/layout/generic/nsLineLayout.h +++ b/layout/generic/nsLineLayout.h @@ -17,17 +17,12 @@ #ifndef nsLineLayout_h___ #define nsLineLayout_h___ -#include "nsFrame.h" -#include "nsDeque.h" #include "nsLineBox.h" #include "nsBlockReflowState.h" #include "plarena.h" #include "gfxTypes.h" -class nsBlockFrame; - class nsFloatManager; -class nsPlaceholderFrame; struct nsStyleText; class nsLineLayout { diff --git a/layout/generic/nsObjectFrame.cpp b/layout/generic/nsObjectFrame.cpp index 50d064ddfecd..76070019485a 100644 --- a/layout/generic/nsObjectFrame.cpp +++ b/layout/generic/nsObjectFrame.cpp @@ -6,7 +6,10 @@ /* rendering objects for replaced elements implemented by a plugin */ +#ifdef XP_WIN +// This is needed for DoublePassRenderingEvent. #include "mozilla/plugins/PluginMessageUtils.h" +#endif #include "nscore.h" #include "nsCOMPtr.h" @@ -15,89 +18,40 @@ #include "nsWidgetsCID.h" #include "nsView.h" #include "nsViewManager.h" -#include "nsIDOMEventListener.h" -#include "nsIDOMDragEvent.h" -#include "nsPluginHost.h" #include "nsString.h" -#include "nsReadableUtils.h" #include "nsGkAtoms.h" -#include "nsIAppShell.h" -#include "nsIDocument.h" -#include "nsINodeInfo.h" -#include "nsIURL.h" -#include "nsNetUtil.h" #include "nsIPluginInstanceOwner.h" #include "nsNPAPIPluginInstance.h" -#include "nsIPluginTagInfo.h" -#include "plstr.h" -#include "nsILinkHandler.h" -#include "nsIScrollPositionListener.h" -#include "nsITimer.h" -#include "nsIDocShellTreeItem.h" -#include "nsIDocShellTreeOwner.h" -#include "nsDocShellCID.h" -#include "nsIWebBrowserChrome.h" #include "nsIDOMElement.h" -#include "nsIDOMNodeList.h" -#include "nsIDOMHTMLObjectElement.h" -#include "nsIDOMHTMLEmbedElement.h" -#include "nsIDOMHTMLAppletElement.h" -#include "nsIDOMWindow.h" -#include "nsIDocumentEncoder.h" -#include "nsXPIDLString.h" -#include "nsIDOMRange.h" -#include "nsIPluginWidget.h" #include "nsGUIEvent.h" #include "nsRenderingContext.h" #include "npapi.h" -#include "nsTransform2D.h" -#include "nsIImageLoadingContent.h" #include "nsIObjectLoadingContent.h" -#include "nsPIDOMWindow.h" #include "nsContentUtils.h" #include "nsDisplayList.h" -#include "nsAttrName.h" -#include "nsDataHashtable.h" -#include "nsDOMClassInfo.h" #include "nsFocusManager.h" #include "nsLayoutUtils.h" #include "nsFrameManager.h" -#include "nsComponentManagerUtils.h" #include "nsIObserverService.h" -#include "nsIScrollableFrame.h" -#include "mozilla/Preferences.h" #include "GeckoProfiler.h" #include -// headers for plugin scriptability -#include "nsIScriptGlobalObject.h" -#include "nsIScriptContext.h" -#include "nsIXPConnect.h" -#include "nsIXPCScriptable.h" -#include "nsIClassInfo.h" -#include "nsIDOMClientRect.h" - #include "nsObjectFrame.h" #include "nsIObjectFrame.h" #include "nsPluginNativeWindow.h" -#include "nsIPluginDocument.h" #include "FrameLayerBuilder.h" -#include "nsThreadUtils.h" - -#include "gfxContext.h" -#include "gfxPlatform.h" #include "ImageLayers.h" +#include "nsPluginInstanceOwner.h" #ifdef XP_WIN #include "gfxWindowsNativeDrawing.h" #include "gfxWindowsSurface.h" #endif -#include "gfxImageSurface.h" -#include "gfxUtils.h" #include "Layers.h" #include "ReadbackLayer.h" +#include "ImageContainer.h" // accessibility support #ifdef ACCESSIBILITY @@ -109,9 +63,6 @@ #endif /* MOZ_LOGGING */ #include "prlog.h" -#include - -#include "nsContentCID.h" static NS_DEFINE_CID(kAppShellCID, NS_APPSHELL_CID); #ifdef XP_MACOSX @@ -120,13 +71,6 @@ static NS_DEFINE_CID(kAppShellCID, NS_APPSHELL_CID); #include "mozilla/gfx/QuartzSupport.h" #endif -#if defined(MOZ_WIDGET_GTK) -#include -#include -#include -#include "gfxXlibNativeRenderer.h" -#endif - #ifdef MOZ_X11 #include "mozilla/X11Util.h" using mozilla::DefaultXDisplay; diff --git a/layout/generic/nsObjectFrame.h b/layout/generic/nsObjectFrame.h index e27240169e84..29d7066aa919 100644 --- a/layout/generic/nsObjectFrame.h +++ b/layout/generic/nsObjectFrame.h @@ -9,19 +9,22 @@ #define nsObjectFrame_h___ #include "mozilla/Attributes.h" -#include "nsPluginInstanceOwner.h" #include "nsIObjectFrame.h" #include "nsFrame.h" #include "nsRegion.h" #include "nsDisplayList.h" #include "nsIReflowCallback.h" -class nsPluginHost; +#ifdef XP_WIN +#include // For HWND :( +#endif + class nsPresContext; class nsRootPresContext; class nsDisplayPlugin; class nsIOSurface; class PluginBackgroundSink; +class nsPluginInstanceOwner; namespace mozilla { namespace layers { diff --git a/layout/generic/nsPageContentFrame.cpp b/layout/generic/nsPageContentFrame.cpp index ff55ae5d1785..05095d6b89e2 100644 --- a/layout/generic/nsPageContentFrame.cpp +++ b/layout/generic/nsPageContentFrame.cpp @@ -3,18 +3,11 @@ * 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 "nsPageContentFrame.h" -#include "nsPageFrame.h" -#include "nsPlaceholderFrame.h" #include "nsCSSFrameConstructor.h" -#include "nsContainerFrame.h" -#include "nsHTMLParts.h" -#include "nsIContent.h" #include "nsPresContext.h" #include "nsGkAtoms.h" #include "nsIPresShell.h" -#include "nsReadableUtils.h" #include "nsSimplePageSequence.h" -#include "nsDisplayList.h" nsIFrame* NS_NewPageContentFrame(nsIPresShell* aPresShell, nsStyleContext* aContext) diff --git a/layout/generic/nsPageFrame.cpp b/layout/generic/nsPageFrame.cpp index a8207b8a90a8..f712ca45ed60 100644 --- a/layout/generic/nsPageFrame.cpp +++ b/layout/generic/nsPageFrame.cpp @@ -5,23 +5,18 @@ #include "nsPageFrame.h" #include "nsPresContext.h" -#include "nsStyleContext.h" #include "nsRenderingContext.h" #include "nsGkAtoms.h" #include "nsIPresShell.h" -#include "nsCSSFrameConstructor.h" -#include "nsReadableUtils.h" #include "nsPageContentFrame.h" #include "nsDisplayList.h" #include "nsLayoutUtils.h" // for function BinarySearchForPosition -#include "nsCSSRendering.h" #include "nsSimplePageSequence.h" // for nsSharedPageData #include "nsTextFormatter.h" // for page number localization formatting #ifdef IBMBIDI #include "nsBidiUtils.h" #endif #include "nsIPrintSettings.h" -#include "nsRegion.h" #include "prlog.h" #ifdef PR_LOGGING diff --git a/layout/generic/nsSelection.cpp b/layout/generic/nsSelection.cpp index d98acd169670..889f00d4f23e 100644 --- a/layout/generic/nsSelection.cpp +++ b/layout/generic/nsSelection.cpp @@ -13,23 +13,17 @@ #include "mozilla/Attributes.h" #include "nsCOMPtr.h" -#include "nsWeakReference.h" -#include "nsIFactory.h" #include "nsString.h" -#include "nsReadableUtils.h" #include "nsFrameSelection.h" #include "nsISelectionListener.h" -#include "nsIComponentManager.h" #include "nsContentCID.h" #include "nsIContent.h" -#include "nsIDOMElement.h" #include "nsIDOMNode.h" #include "nsRange.h" #include "nsCOMArray.h" #include "nsGUIEvent.h" #include "nsIDOMKeyEvent.h" #include "nsITableCellLayout.h" -#include "nsIDOMNodeList.h" #include "nsTArray.h" #include "nsTableOuterFrame.h" #include "nsTableCellFrame.h" @@ -41,8 +35,6 @@ #include // for IBMBIDI -#include "nsFrameTraversal.h" -#include "nsILineIterator.h" #include "nsGkAtoms.h" #include "nsIFrameTraversal.h" #include "nsLayoutUtils.h" @@ -65,7 +57,6 @@ static NS_DEFINE_CID(kFrameTraversalCID, NS_FRAMETRAVERSAL_CID); #include "nsITimer.h" -#include "nsIServiceManager.h" #include "nsFrameManager.h" // notifications #include "nsIDOMDocument.h" @@ -89,10 +80,6 @@ using namespace mozilla; static NS_DEFINE_IID(kCContentIteratorCID, NS_CONTENTITERATOR_CID); -//PROTOTYPES -class nsFrameSelection; -class nsAutoScrollTimer; - static bool IsValidSelectionPoint(nsFrameSelection *aFrameSel, nsINode *aNode); static nsIAtom *GetTag(nsINode *aNode); diff --git a/layout/generic/nsSimplePageSequence.cpp b/layout/generic/nsSimplePageSequence.cpp index 4cf3a11d6fce..a1723334f2d7 100644 --- a/layout/generic/nsSimplePageSequence.cpp +++ b/layout/generic/nsSimplePageSequence.cpp @@ -2,8 +2,7 @@ /* This Source Code Form is subject to the terms of the Mozilla Public * 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 "nsCOMPtr.h" -#include "nsReadableUtils.h" +#include "nsCOMPtr.h" #include "nsSimplePageSequence.h" #include "nsPresContext.h" #include "gfxContext.h" @@ -13,15 +12,15 @@ #include "nsIPrintSettings.h" #include "nsPageFrame.h" #include "nsSubDocumentFrame.h" -#include "nsStyleConsts.h" #include "nsRegion.h" #include "nsCSSFrameConstructor.h" #include "nsContentUtils.h" #include "nsDisplayList.h" -#include "mozilla/Preferences.h" #include "nsHTMLCanvasFrame.h" #include "mozilla/dom/HTMLCanvasElement.h" #include "nsICanvasRenderingContextInternal.h" +#include "nsIDateTimeFormat.h" +#include "nsServiceManagerUtils.h" #include // DateTime Includes @@ -31,8 +30,6 @@ // Print Options #include "nsIPrintOptions.h" -#include "nsGfxCIID.h" -#include "nsIServiceManager.h" using namespace mozilla; using namespace mozilla::dom; diff --git a/layout/generic/nsSimplePageSequence.h b/layout/generic/nsSimplePageSequence.h index d17ff1d231d8..0333c48472d8 100644 --- a/layout/generic/nsSimplePageSequence.h +++ b/layout/generic/nsSimplePageSequence.h @@ -10,8 +10,16 @@ #include "nsContainerFrame.h" #include "nsIPrintSettings.h" #include "nsIPrintOptions.h" -#include "nsIDateTimeFormat.h" -#include "mozilla/dom/HTMLCanvasElement.h" + +class nsIDateTimeFormat; + +namespace mozilla { +namespace dom { + +class HTMLCanvasElement; + +} +} //----------------------------------------------- // This class maintains all the data that diff --git a/layout/generic/nsSplittableFrame.cpp b/layout/generic/nsSplittableFrame.cpp index d28e93bd244f..20b948014a57 100644 --- a/layout/generic/nsSplittableFrame.cpp +++ b/layout/generic/nsSplittableFrame.cpp @@ -9,9 +9,6 @@ */ #include "nsSplittableFrame.h" -#include "nsIContent.h" -#include "nsPresContext.h" -#include "nsStyleContext.h" #include "nsContainerFrame.h" NS_IMPL_FRAMEARENA_HELPERS(nsSplittableFrame) diff --git a/layout/generic/nsSubDocumentFrame.cpp b/layout/generic/nsSubDocumentFrame.cpp index f547844299a0..bb2c36b17dc8 100644 --- a/layout/generic/nsSubDocumentFrame.cpp +++ b/layout/generic/nsSubDocumentFrame.cpp @@ -15,46 +15,25 @@ #include "nsGenericHTMLElement.h" #include "nsAttrValueInlines.h" #include "nsIDocShell.h" -#include "nsIDocShellLoadInfo.h" -#include "nsIDocShellTreeItem.h" -#include "nsIDocShellTreeNode.h" -#include "nsIDocShellTreeOwner.h" -#include "nsIBaseWindow.h" #include "nsIContentViewer.h" #include "nsPresContext.h" #include "nsIPresShell.h" -#include "nsIComponentManager.h" -#include "nsFrameManager.h" -#include "nsIStreamListener.h" -#include "nsIURL.h" -#include "nsNetUtil.h" #include "nsIDocument.h" #include "nsView.h" #include "nsViewManager.h" #include "nsGkAtoms.h" -#include "nsStyleCoord.h" -#include "nsStyleContext.h" #include "nsStyleConsts.h" #include "nsFrameSetFrame.h" #include "nsIDOMHTMLFrameElement.h" -#include "nsIDOMHTMLIFrameElement.h" -#include "nsIDOMXULElement.h" -#include "nsIScriptSecurityManager.h" -#include "nsXPIDLString.h" #include "nsIScrollable.h" #include "nsINameSpaceManager.h" -#include "nsWeakReference.h" -#include "nsIDOMWindow.h" #include "nsDisplayList.h" -#include "nsUnicharUtils.h" #include "nsIScrollableFrame.h" #include "nsIObjectLoadingContent.h" #include "nsLayoutUtils.h" #include "FrameLayerBuilder.h" #include "nsObjectFrame.h" -#include "nsIServiceManager.h" #include "nsContentUtils.h" -#include "LayerTreeInvalidation.h" #include "nsIPermissionManager.h" using namespace mozilla; @@ -70,8 +49,6 @@ GetDocumentFromView(nsView* aView) return ps ? ps->GetDocument() : nullptr; } -class AsyncFrameInit; - nsSubDocumentFrame::nsSubDocumentFrame(nsStyleContext* aContext) : nsLeafFrame(aContext) , mIsInline(false) diff --git a/layout/generic/nsTextFrame.cpp b/layout/generic/nsTextFrame.cpp index 3a783ec3fed8..2d2a17004364 100644 --- a/layout/generic/nsTextFrame.cpp +++ b/layout/generic/nsTextFrame.cpp @@ -14,7 +14,6 @@ #include "nsCOMPtr.h" #include "nsBlockFrame.h" -#include "nsHTMLParts.h" #include "nsCRT.h" #include "nsSplittableFrame.h" #include "nsLineLayout.h" @@ -30,9 +29,7 @@ #include "nsCoord.h" #include "nsRenderingContext.h" #include "nsIPresShell.h" -#include "nsITimer.h" #include "nsTArray.h" -#include "nsIDocument.h" #include "nsCSSPseudoElements.h" #include "nsCSSFrameConstructor.h" #include "nsCompatibility.h" @@ -43,17 +40,13 @@ #include "nsPlaceholderFrame.h" #include "nsTextFrameUtils.h" #include "nsTextRunTransformations.h" -#include "nsFrameManager.h" #include "nsTextFrameTextRunCache.h" #include "nsExpirationTracker.h" #include "nsUnicodeProperties.h" -#include "nsUnicharUtilCIID.h" #include "nsTextFragment.h" #include "nsGkAtoms.h" #include "nsFrameSelection.h" -#include "nsISelection.h" -#include "nsIDOMRange.h" #include "nsRange.h" #include "nsCSSRendering.h" #include "nsContentUtils.h" @@ -61,21 +54,16 @@ #include "nsIWordBreaker.h" #include "nsGenericDOMDataNode.h" -#include "nsILineIterator.h" - -#include "nsIServiceManager.h" #include #ifdef ACCESSIBILITY #include "nsAccessibilityService.h" #endif #include "nsAutoPtr.h" -#include "nsBidiUtils.h" #include "nsPrintfCString.h" #include "gfxFont.h" #include "gfxContext.h" -#include "gfxImageSurface.h" #include "mozilla/dom/Element.h" #include "mozilla/LookAndFeel.h" diff --git a/layout/generic/nsTextFrame.h b/layout/generic/nsTextFrame.h index 9837abf87e13..195402d0ed8b 100644 --- a/layout/generic/nsTextFrame.h +++ b/layout/generic/nsTextFrame.h @@ -12,7 +12,6 @@ #include "nsLineBox.h" #include "gfxFont.h" #include "gfxSkipChars.h" -#include "gfxContext.h" #include "nsDisplayList.h" class nsTextPaintStyle; diff --git a/layout/generic/nsTextFrameUtils.cpp b/layout/generic/nsTextFrameUtils.cpp index a6fff3cc4bd7..44fb1e70a86e 100644 --- a/layout/generic/nsTextFrameUtils.cpp +++ b/layout/generic/nsTextFrameUtils.cpp @@ -5,12 +5,11 @@ #include "nsTextFrameUtils.h" -#include "nsIWordBreaker.h" -#include "gfxFont.h" #include "nsUnicharUtils.h" #include "nsBidiUtils.h" #include "nsIContent.h" #include "nsStyleStruct.h" +#include "nsTextFragment.h" #include // XXX TODO implement transform of backslash to yen that nsTextTransform does diff --git a/layout/generic/nsTextFrameUtils.h b/layout/generic/nsTextFrameUtils.h index 451540af9a5a..b2be1f705d3a 100644 --- a/layout/generic/nsTextFrameUtils.h +++ b/layout/generic/nsTextFrameUtils.h @@ -6,9 +6,7 @@ #ifndef NSTEXTFRAMEUTILS_H_ #define NSTEXTFRAMEUTILS_H_ -#include "gfxFont.h" #include "gfxSkipChars.h" -#include "nsTextFragment.h" class nsIContent; struct nsStyleText; diff --git a/layout/generic/nsTextRunTransformations.cpp b/layout/generic/nsTextRunTransformations.cpp index 1932ed51e55f..60f478ea6b01 100644 --- a/layout/generic/nsTextRunTransformations.cpp +++ b/layout/generic/nsTextRunTransformations.cpp @@ -7,13 +7,9 @@ #include "mozilla/MemoryReporting.h" -#include "nsTextFrameUtils.h" -#include "gfxSkipChars.h" #include "nsGkAtoms.h" - #include "nsStyleConsts.h" #include "nsStyleContext.h" -#include "gfxContext.h" #include "nsUnicodeProperties.h" #include "nsSpecialCasingData.h" diff --git a/layout/generic/nsVideoFrame.cpp b/layout/generic/nsVideoFrame.cpp index c100642f26c2..defa6beca554 100644 --- a/layout/generic/nsVideoFrame.cpp +++ b/layout/generic/nsVideoFrame.cpp @@ -6,31 +6,23 @@ /* rendering object for the HTML