Bug 1530193 - followup: Fix default type and value of browser.display.focus_ring_style.
authorEmilio Cobos Álvarez <emilio@crisal.io>
Thu, 07 Mar 2019 14:41:30 +0100
changeset 462911 a96130bc4159d683e559b763d18d36bc5d4b2b44
parent 462910 43963f700a1e06a01d46158177dccd3c3987c9c0
child 462912 8e48fdd65475c48fdc2f6af9e359c3d07bee66e5
push id35662
push useraiakab@mozilla.com
push dateThu, 07 Mar 2019 21:58:58 +0000
treeherdermozilla-central@af29567ecdba [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1530193
milestone67.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 1530193 - followup: Fix default type and value of browser.display.focus_ring_style. It warns on debug builds.
layout/base/nsPresContext.cpp
layout/base/nsPresContext.h
layout/style/PreferenceSheet.h
modules/libpref/init/StaticPrefList.h
--- a/layout/base/nsPresContext.cpp
+++ b/layout/base/nsPresContext.cpp
@@ -166,17 +166,16 @@ nsPresContext::nsPresContext(dom::Docume
       mElementsRestyled(0),
       mFramesConstructed(0),
       mFramesReflowed(0),
       mInteractionTimeEnabled(true),
       mHasPendingInterrupt(false),
       mPendingInterruptFromTest(false),
       mInterruptsEnabled(false),
       mSendAfterPaintToContent(false),
-      mUseFocusColors(false),
       mDrawImageBackground(true),  // always draw the background
       mDrawColorBackground(true),
       // mNeverAnimate is initialised below, in constructor body
       mPaginated(aType != eContext_Galley),
       mCanPaginatedScroll(false),
       mDoScaledTwips(true),
       mIsRootPaginatedDocument(false),
       mPrefBidiDirection(false),
--- a/layout/base/nsPresContext.h
+++ b/layout/base/nsPresContext.h
@@ -1215,19 +1215,16 @@ class nsPresContext : public nsISupports
 
   // last time we did a full style flush
   mozilla::TimeStamp mLastStyleUpdateForAllAnimations;
 
   unsigned mHasPendingInterrupt : 1;
   unsigned mPendingInterruptFromTest : 1;
   unsigned mInterruptsEnabled : 1;
   unsigned mSendAfterPaintToContent : 1;
-  unsigned mUseFocusColors : 1;
-  unsigned mFocusRingOnAnything : 1;
-  unsigned mFocusRingStyle : 1;
   unsigned mDrawImageBackground : 1;
   unsigned mDrawColorBackground : 1;
   unsigned mNeverAnimate : 1;
   unsigned mPaginated : 1;
   unsigned mCanPaginatedScroll : 1;
   unsigned mDoScaledTwips : 1;
   unsigned mIsRootPaginatedDocument : 1;
   unsigned mPrefBidiDirection : 1;
--- a/layout/style/PreferenceSheet.h
+++ b/layout/style/PreferenceSheet.h
@@ -32,17 +32,17 @@ struct PreferenceSheet {
     nscolor mFocusBackgroundColor = mDefaultBackgroundColor;
 
     bool mIsChrome = false;
     bool mUseAccessibilityTheme = false;
 
     bool mUnderlineLinks = true;
     bool mUseFocusColors = false;
     uint8_t mFocusRingWidth = 1;
-    bool mFocusRingStyle = false;
+    uint8_t mFocusRingStyle = 1;
     bool mFocusRingOnAnything = false;
 
     void Load(bool aIsChrome);
   };
 
   static void EnsureInitialized() {
     if (sInitialized) {
       return;
--- a/modules/libpref/init/StaticPrefList.h
+++ b/modules/libpref/init/StaticPrefList.h
@@ -570,20 +570,21 @@ VARCACHE_PREF(
 )
 
 VARCACHE_PREF(
   "browser.display.focus_ring_width",
    browser_display_focus_ring_width,
   uint32_t, 1
 )
 
+// 0=solid, 1=dotted
 VARCACHE_PREF(
   "browser.display.focus_ring_style",
    browser_display_focus_ring_style,
-  bool, false
+  uint32_t, 1
 )
 
 VARCACHE_PREF(
   "browser.display.use_system_colors",
    browser_display_use_system_colors,
   bool, true
 )