Bug 1326189 part 1 - Apply :visited style for caret-color. r=dholbert
authorXidorn Quan <me@upsuper.org>
Thu, 19 Jan 2017 23:07:25 +0800
changeset 375592 2472110ff7862ce333a0d89615364e097ed0e970
parent 375591 b67585d1f51838b66cbc0854f74210c8120affbd
child 375593 d3a7a0669c3feaf4eb99f02bee625a654accb7df
push id6996
push userjlorenzo@mozilla.com
push dateMon, 06 Mar 2017 20:48:21 +0000
treeherdermozilla-beta@d89512dab048 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersdholbert
bugs1326189
milestone53.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 1326189 part 1 - Apply :visited style for caret-color. r=dholbert MozReview-Commit-ID: DQqSdCz2TEC
layout/generic/nsFrame.cpp
layout/style/nsCSSVisitedDependentPropList.h
--- a/layout/generic/nsFrame.cpp
+++ b/layout/generic/nsFrame.cpp
@@ -1879,17 +1879,17 @@ nsIFrame::DisplayCaret(nsDisplayListBuil
     return;
 
   aList->AppendNewToTop(new (aBuilder) nsDisplayCaret(aBuilder, this));
 }
 
 nscolor
 nsIFrame::GetCaretColorAt(int32_t aOffset)
 {
-  return StyleColor()->CalcComplexColor(StyleUserInterface()->mCaretColor);
+  return nsLayoutUtils::GetColor(this, &nsStyleUserInterface::mCaretColor);
 }
 
 bool
 nsFrame::DisplayBackgroundUnconditional(nsDisplayListBuilder* aBuilder,
                                         const nsDisplayListSet& aLists,
                                         bool aForceBackground)
 {
   // Here we don't try to detect background propagation. Frames that might
--- a/layout/style/nsCSSVisitedDependentPropList.h
+++ b/layout/style/nsCSSVisitedDependentPropList.h
@@ -28,8 +28,9 @@ STYLE_STRUCT(Border, (mBorderTopColor,
                       mBorderLeftColor))
 STYLE_STRUCT(Outline, (mOutlineColor))
 STYLE_STRUCT(Column, (mColumnRuleColor))
 STYLE_STRUCT(Text, (mTextEmphasisColor,
                     mWebkitTextFillColor,
                     mWebkitTextStrokeColor))
 STYLE_STRUCT(TextReset, (mTextDecorationColor))
 STYLE_STRUCT(SVG, (mFill, mStroke))
+STYLE_STRUCT(UserInterface, (mCaretColor))