Bug 1442755 - Disable titlebar theming based on main window focus due to regression at Bug 1497534, r=jhorak a=jcristau
authorMartin Stransky <stransky@redhat.com>
Fri, 16 Nov 2018 00:03:00 +0200
changeset 501260 d810f485f1aa9f2a318c6eb0ee02e730aad573e2
parent 501259 c18fd289892de2269be0d55ba91a5514f8c76d1f
child 501261 13e3f37faf8c7a013d463e8e4240220a78d6899a
push id1864
push userffxbld-merge
push dateMon, 03 Dec 2018 15:51:40 +0000
treeherdermozilla-release@f040763d99ad [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjhorak, jcristau
bugs1442755, 1497534
milestone64.0
Bug 1442755 - Disable titlebar theming based on main window focus due to regression at Bug 1497534, r=jhorak a=jcristau
widget/gtk/nsNativeThemeGTK.cpp
--- a/widget/gtk/nsNativeThemeGTK.cpp
+++ b/widget/gtk/nsNativeThemeGTK.cpp
@@ -446,24 +446,27 @@ nsNativeThemeGTK::GetGtkWidgetAndState(S
       // should draw focus for the drop down button as well.
       if ((aWidgetType == StyleAppearance::MenulistButton ||
            aWidgetType == StyleAppearance::MozMenulistButton) &&
           aWidgetFlags) {
         *aWidgetFlags = CheckBooleanAttr(aFrame, nsGkAtoms::parentfocused);
       }
     }
 
+    //Disabled due to Bug 1497534
+    /*
     if (aWidgetType == StyleAppearance::MozWindowTitlebar ||
         aWidgetType == StyleAppearance::MozWindowTitlebarMaximized ||
         aWidgetType == StyleAppearance::MozWindowButtonClose ||
         aWidgetType == StyleAppearance::MozWindowButtonMinimize ||
         aWidgetType == StyleAppearance::MozWindowButtonMaximize ||
         aWidgetType == StyleAppearance::MozWindowButtonRestore) {
       aState->backdrop = !nsWindow::GetTopLevelWindowActiveState(aFrame);
     }
+    */
 
     if (aWidgetType ==  StyleAppearance::ScrollbarbuttonUp ||
         aWidgetType ==  StyleAppearance::ScrollbarbuttonDown ||
         aWidgetType ==  StyleAppearance::ScrollbarbuttonLeft ||
         aWidgetType ==  StyleAppearance::ScrollbarbuttonRight ||
         aWidgetType == StyleAppearance::ScrollbarVertical ||
         aWidgetType == StyleAppearance::ScrollbarHorizontal ||
         aWidgetType == StyleAppearance::ScrollbartrackHorizontal ||
@@ -1837,17 +1840,18 @@ nsNativeThemeGTK::WidgetStateChanged(nsI
   }
 
   if (aWidgetType == StyleAppearance::MozWindowTitlebar ||
       aWidgetType == StyleAppearance::MozWindowTitlebarMaximized ||
       aWidgetType == StyleAppearance::MozWindowButtonClose ||
       aWidgetType == StyleAppearance::MozWindowButtonMinimize ||
       aWidgetType == StyleAppearance::MozWindowButtonMaximize ||
       aWidgetType == StyleAppearance::MozWindowButtonRestore) {
-    *aShouldRepaint = true;
+    //Disabled due to Bug 1497534
+    *aShouldRepaint = false;
     return NS_OK;
   }
 
   if ((aWidgetType == StyleAppearance::ScrollbarthumbVertical ||
        aWidgetType == StyleAppearance::ScrollbarthumbHorizontal) &&
        aAttribute == nsGkAtoms::active) {
     *aShouldRepaint = true;
     return NS_OK;
@@ -2149,16 +2153,18 @@ nsNativeThemeGTK::WidgetAppearanceDepend
 {
   switch (aWidgetType) {
     case StyleAppearance::MozWindowTitlebar:
     case StyleAppearance::MozWindowTitlebarMaximized:
     case StyleAppearance::MozWindowButtonClose:
     case StyleAppearance::MozWindowButtonMinimize:
     case StyleAppearance::MozWindowButtonMaximize:
     case StyleAppearance::MozWindowButtonRestore:
+      // Disabled due to Bug 1497534
+      return false;
     case StyleAppearance::ScrollbarbuttonUp:
     case StyleAppearance::ScrollbarbuttonDown:
     case StyleAppearance::ScrollbarbuttonLeft:
     case StyleAppearance::ScrollbarbuttonRight:
     case StyleAppearance::ScrollbarVertical:
     case StyleAppearance::ScrollbarHorizontal:
     case StyleAppearance::ScrollbartrackHorizontal:
     case StyleAppearance::ScrollbartrackVertical: