Bug 1184842. Remove frameset mVisibilityOverride since it's always false now. r=mats
authorRobert O'Callahan <robert@ocallahan.org>
Tue, 21 Jul 2015 16:22:02 +1200
changeset 287664 4e87cabdf930af16ba0c1b79b258df220203b2e8
parent 287663 86d881ad9429355be61f271363b19d181fef366c
child 287665 1818b9f17a2648257aaa247f0620c6217e39483e
push id5067
push userraliiev@mozilla.com
push dateMon, 21 Sep 2015 14:04:52 +0000
treeherdermozilla-beta@14221ffe5b2f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmats
bugs1184842
milestone42.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1184842. Remove frameset mVisibilityOverride since it's always false now. r=mats
layout/generic/nsFrameSetFrame.cpp
--- a/layout/generic/nsFrameSetFrame.cpp
+++ b/layout/generic/nsFrameSetFrame.cpp
@@ -103,17 +103,17 @@ public:
                                 const nsRect&           aDirtyRect,
                                 const nsDisplayListSet& aLists) override;
 
   virtual void Reflow(nsPresContext*           aPresContext,
                           nsHTMLReflowMetrics&     aDesiredSize,
                           const nsHTMLReflowState& aReflowState,
                           nsReflowStatus&          aStatus) override;
 
-  bool GetVisibility() { return mVisibility || mVisibilityOverride; }
+  bool GetVisibility() { return mVisibility; }
   void SetVisibility(bool aVisibility);
   void SetColor(nscolor aColor);
 
   void PaintBorder(DrawTarget* aDrawTarget, nsPoint aPt);
 
 protected:
   nsHTMLFramesetBorderFrame(nsStyleContext* aContext, int32_t aWidth, bool aVertical, bool aVisible);
   virtual ~nsHTMLFramesetBorderFrame();
@@ -123,17 +123,16 @@ protected:
   // the prev and next neighbors are indexes into the row (for a horizontal border) or col (for
   // a vertical border) of nsHTMLFramesetFrames or nsHTMLFrames
   int32_t mPrevNeighbor;
   int32_t mNextNeighbor;
   nscolor mColor;
   int32_t mWidth;
   bool mVertical;
   bool mVisibility;
-  bool mVisibilityOverride;
   bool mCanResize;
   friend class nsHTMLFramesetFrame;
 };
 /*******************************************************************************
  * nsHTMLFramesetBlankFrame
  ******************************************************************************/
 class nsHTMLFramesetBlankFrame : public nsLeafFrame
 {
@@ -1171,25 +1170,23 @@ nsHTMLFramesetFrame::RecalculateBorderRe
   PR_STATIC_ASSERT(NS_MAX_FRAMESET_SPEC_COUNT < INT32_MAX / NS_MAX_FRAMESET_SPEC_COUNT);
   PR_STATIC_ASSERT(NS_MAX_FRAMESET_SPEC_COUNT
                    < UINT_MAX / sizeof(int32_t) / NS_MAX_FRAMESET_SPEC_COUNT);
   // set the visibility and mouse sensitivity of borders
   int32_t verX;
   for (verX = 0; verX < mNumCols-1; verX++) {
     if (mVerBorders[verX]) {
       mVerBorders[verX]->mCanResize = true;
-      mVerBorders[verX]->mVisibilityOverride = false;
       SetBorderResize(mVerBorders[verX]);
     }
   }
   int32_t horX;
   for (horX = 0; horX < mNumRows-1; horX++) {
     if (mHorBorders[horX]) {
       mHorBorders[horX]->mCanResize = true;
-      mHorBorders[horX]->mVisibilityOverride = false;
       SetBorderResize(mHorBorders[horX]);
     }
   }
 }
 
 void
 nsHTMLFramesetFrame::SetBorderResize(nsHTMLFramesetBorderFrame* aBorderFrame)
 {
@@ -1341,17 +1338,16 @@ NS_IMPL_FRAMEARENA_HELPERS(nsHTMLFramese
  * nsHTMLFramesetBorderFrame
  ******************************************************************************/
 nsHTMLFramesetBorderFrame::nsHTMLFramesetBorderFrame(nsStyleContext* aContext,
                                                      int32_t aWidth,
                                                      bool    aVertical,
                                                      bool    aVisibility)
   : nsLeafFrame(aContext), mWidth(aWidth), mVertical(aVertical), mVisibility(aVisibility)
 {
-   mVisibilityOverride = false;
    mCanResize    = true;
    mColor        = NO_COLOR;
    mPrevNeighbor = 0;
    mNextNeighbor = 0;
 }
 
 nsHTMLFramesetBorderFrame::~nsHTMLFramesetBorderFrame()
 {
@@ -1462,17 +1458,17 @@ void nsHTMLFramesetBorderFrame::PaintBor
                  LookAndFeel::GetColor(LookAndFeel::eColorID_Widget3DHighlight,
                                        NS_RGB(255, 255, 255))));
 
   ColorPattern sdwColor(ToDeviceColor(
                  LookAndFeel::GetColor(LookAndFeel::eColorID_Widget3DShadow,
                                        NS_RGB(128, 128, 128))));
 
   ColorPattern color(ToDeviceColor(NS_RGB(255, 255, 255))); // default to white
-  if (mVisibility || mVisibilityOverride) {
+  if (mVisibility) {
     color = (NO_COLOR == mColor) ? bgColor :
                                    ColorPattern(ToDeviceColor(mColor));
   }
 
   int32_t appUnitsPerDevPixel = PresContext()->AppUnitsPerDevPixel();
 
   Point toRefFrame = NSPointToPoint(aPt, appUnitsPerDevPixel);
 
@@ -1491,17 +1487,17 @@ void nsHTMLFramesetBorderFrame::PaintBor
       start.x += pixelWidth;
       end.x =  start.x;
     } else {
       start.y += pixelWidth;
       end.y =  start.y;
     }
   }
 
-  if (!mVisibility && !mVisibilityOverride)
+  if (!mVisibility)
     return;
 
   if (widthInPixels >= 5) {
     start.x = (mVertical) ? pixelWidth : 0;
     start.y = (mVertical) ? 0 : pixelWidth;
     end.x   = (mVertical) ? start.x : mRect.width;
     end.y   = (mVertical) ? mRect.height : start.y;
     StrokeLineWithSnapping(start, end, appUnitsPerDevPixel, *aDrawTarget,