Bug 1277129 Part 5b - Rename nsHTMLReflowMetrics.h/cpp to ReflowOutput.h/cpp and fix #includes. r=dbaron
authorTing-Yu Lin <tlin@mozilla.com>
Thu, 21 Jul 2016 18:36:37 +0800
changeset 333354 1e22c6ef454e4c66e7f5cb78ec69ab383659b972
parent 333353 8c97676c364884ad3e65271e4b6da64402aa782b
child 333355 b2db47ba326823e5774032569afaa333bfb1f7a3
push id6389
push userraliiev@mozilla.com
push dateMon, 19 Sep 2016 13:38:22 +0000
treeherdermozilla-esr52@01d67bfe6c81 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersdbaron
bugs1277129
milestone50.0a1
Bug 1277129 Part 5b - Rename nsHTMLReflowMetrics.h/cpp to ReflowOutput.h/cpp and fix #includes. r=dbaron The modification to nsAbsoluteContainingBlock.h and nsBlockFrame.cpp are needed to fix the build error due to the file order changed in the unified build. The #includes are fixed by the following script: function rename() { find .\ -type f\ ! -path "./obj*"\ ! -path "./.git"\ ! -path "./.hg"\ \( -name "*.cpp" -or\ -name "*.h" \)\ -exec sed -i -e "s/$1/$2/g" "{}" \; } rename "nsHTMLReflowMetrics\.h" "mozilla\/ReflowOutput\.h" MozReview-Commit-ID: KWvcG3UtKNn
layout/base/nsLayoutUtils.h
layout/generic/ReflowOutput.cpp
layout/generic/ReflowOutput.h
layout/generic/moz.build
layout/generic/nsAbsoluteContainingBlock.h
layout/generic/nsBlockFrame.cpp
layout/generic/nsBlockReflowContext.h
layout/generic/nsHTMLReflowMetrics.cpp
layout/generic/nsHTMLReflowMetrics.h
layout/generic/nsIFrame.h
--- a/layout/base/nsLayoutUtils.h
+++ b/layout/base/nsLayoutUtils.h
@@ -22,17 +22,17 @@
 #include "nsStyleCoord.h"
 #include "nsStyleConsts.h"
 #include "nsGkAtoms.h"
 #include "nsRuleNode.h"
 #include "imgIContainer.h"
 #include "mozilla/gfx/2D.h"
 #include "Units.h"
 #include "mozilla/ToString.h"
-#include "nsHTMLReflowMetrics.h"
+#include "mozilla/ReflowOutput.h"
 #include "ImageContainer.h"
 #include "gfx2DGlue.h"
 
 #include <limits>
 #include <algorithm>
 
 class nsPresContext;
 class nsIContent;
rename from layout/generic/nsHTMLReflowMetrics.cpp
rename to layout/generic/ReflowOutput.cpp
--- a/layout/generic/nsHTMLReflowMetrics.cpp
+++ b/layout/generic/ReflowOutput.cpp
@@ -1,16 +1,16 @@
 /* vim: set shiftwidth=2 tabstop=8 autoindent cindent expandtab: */
 /* 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/. */
 
 /* struct containing the output from nsIFrame::Reflow */
 
-#include "nsHTMLReflowMetrics.h"
+#include "mozilla/ReflowOutput.h"
 #include "mozilla/ReflowInput.h"
 
 void
 nsOverflowAreas::UnionWith(const nsOverflowAreas& aOther)
 {
   // FIXME: We should probably change scrollable overflow to use
   // UnionRectIncludeEmpty (but leave visual overflow using UnionRect).
   NS_FOR_FRAME_OVERFLOW_TYPES(otype) {
rename from layout/generic/nsHTMLReflowMetrics.h
rename to layout/generic/ReflowOutput.h
--- a/layout/generic/moz.build
+++ b/layout/generic/moz.build
@@ -67,17 +67,16 @@ EXPORTS += [
     'nsDirection.h',
     'nsFrame.h',
     'nsFrameIdList.h',
     'nsFrameList.h',
     'nsFrameSelection.h',
     'nsFrameState.h',
     'nsFrameStateBits.h',
     'nsHTMLParts.h',
-    'nsHTMLReflowMetrics.h',
     'nsIAnonymousContentCreator.h',
     'nsIFrame.h',
     'nsIFrameInlines.h',
     'nsIFrameUtil.h',
     'nsILineIterator.h',
     'nsIObjectFrame.h',
     'nsIPageSequenceFrame.h',
     'nsIScrollableFrame.h',
@@ -97,16 +96,17 @@ EXPORTS += [
     'ScrollbarActivity.h',
     'ScrollSnap.h',
     'Visibility.h',
     'VisibilityIPC.h',
 ]
 
 EXPORTS.mozilla += [
     'ReflowInput.h',
+    'ReflowOutput.h',
     'WritingModes.h',
 ]
 
 EXPORTS.mozilla.dom += [
     'Selection.h',
 ]
 
 EXPORTS.mozilla.layout += [
@@ -135,17 +135,16 @@ UNIFIED_SOURCES += [
     'nsFrame.cpp',
     'nsFrameList.cpp',
     'nsFrameSetFrame.cpp',
     'nsFrameState.cpp',
     'nsFrameUtil.cpp',
     'nsGfxScrollFrame.cpp',
     'nsGridContainerFrame.cpp',
     'nsHTMLCanvasFrame.cpp',
-    'nsHTMLReflowMetrics.cpp',
     'nsImageFrame.cpp',
     'nsImageMap.cpp',
     'nsInlineFrame.cpp',
     'nsIntervalSet.cpp',
     'nsLeafFrame.cpp',
     'nsLineBox.cpp',
     'nsPageContentFrame.cpp',
     'nsPageFrame.cpp',
@@ -161,16 +160,17 @@ UNIFIED_SOURCES += [
     'nsSplittableFrame.cpp',
     'nsSubDocumentFrame.cpp',
     'nsTextFrame.cpp',
     'nsTextFrameUtils.cpp',
     'nsTextRunTransformations.cpp',
     'nsVideoFrame.cpp',
     'nsViewportFrame.cpp',
     'ReflowInput.cpp',
+    'ReflowOutput.cpp',
     'RubyUtils.cpp',
     'ScrollbarActivity.cpp',
     'ScrollSnap.cpp',
     'ScrollVelocityQueue.cpp',
     'StickyScrollContainer.cpp',
     'TextOverflow.cpp',
 ]
 
--- a/layout/generic/nsAbsoluteContainingBlock.h
+++ b/layout/generic/nsAbsoluteContainingBlock.h
@@ -28,16 +28,18 @@ class nsPresContext;
  * There is no principal child list, just a named child list which contains
  * the absolutely positioned frames (kAbsoluteList or kFixedList).
  *
  * All functions include as the first argument the frame that is delegating
  * the request.
  */
 class nsAbsoluteContainingBlock
 {
+  using ReflowInput = mozilla::ReflowInput;
+
 public:
   typedef nsIFrame::ChildListID ChildListID;
 
   explicit nsAbsoluteContainingBlock(ChildListID aChildListID)
 #ifdef DEBUG
     : mChildListID(aChildListID)
 #endif
   {
--- a/layout/generic/nsBlockFrame.cpp
+++ b/layout/generic/nsBlockFrame.cpp
@@ -60,16 +60,17 @@
 #include "nsBidiPresUtils.h"
 
 static const int MIN_LINES_NEEDING_CURSOR = 20;
 
 static const char16_t kDiscCharacter = 0x2022;
 
 using namespace mozilla;
 using namespace mozilla::css;
+using namespace mozilla::dom;
 using namespace mozilla::layout;
 typedef nsAbsoluteContainingBlock::AbsPosReflowFlags AbsPosReflowFlags;
 
 static void MarkAllDescendantLinesDirty(nsBlockFrame* aBlock)
 {
   nsLineList::iterator line = aBlock->begin_lines();
   nsLineList::iterator endLine = aBlock->end_lines();
   while (line != endLine) {
--- a/layout/generic/nsBlockReflowContext.h
+++ b/layout/generic/nsBlockReflowContext.h
@@ -5,17 +5,17 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 /* class that a parent frame uses to reflow a block frame */
 
 #ifndef nsBlockReflowContext_h___
 #define nsBlockReflowContext_h___
 
 #include "nsIFrame.h"
-#include "nsHTMLReflowMetrics.h"
+#include "mozilla/ReflowOutput.h"
 
 class nsLineBox;
 class nsPresContext;
 namespace mozilla {
 class BlockReflowInput;
 } // namespace mozilla
 
 /**
--- a/layout/generic/nsIFrame.h
+++ b/layout/generic/nsIFrame.h
@@ -26,17 +26,17 @@
 #include "CaretAssociationHint.h"
 #include "FramePropertyTable.h"
 #include "mozilla/layout/FrameChildList.h"
 #include "mozilla/Maybe.h"
 #include "mozilla/WritingModes.h"
 #include "nsDirection.h"
 #include "nsFrameList.h"
 #include "nsFrameState.h"
-#include "nsHTMLReflowMetrics.h"
+#include "mozilla/ReflowOutput.h"
 #include "nsITheme.h"
 #include "nsLayoutUtils.h"
 #include "nsQueryFrame.h"
 #include "nsStringGlue.h"
 #include "nsStyleContext.h"
 #include "nsStyleStruct.h"
 #include "Visibility.h"