Backed out changeset 01b86df73b4a (bug 1272332) for Linux x64 opt reftest bustage, e.g. 914521.html. r=backout

This commit is contained in:
Sebastian Hengst 2016-05-18 13:42:25 +02:00
parent 6d3d2e75ef
commit a68f0cb92b

View File

@ -24,7 +24,6 @@
#include "nsStyleConsts.h"
#include "gfxFontConstants.h"
#include "WidgetUtils.h"
#include "nsIXULRuntime.h"
#include <dlfcn.h>
@ -1098,18 +1097,16 @@ nsLookAndFeel::Init()
// with wrong color theme, see Bug 972382
GtkSettings *settings = gtk_settings_get_for_screen(gdk_screen_get_default());
if (!mozilla::BrowserTabsRemoteAutostart() || XRE_IsContentProcess()) {
// Disable dark theme in processes that have web content because it
// interacts poorly with widget styling (see bug 1216658).
// To avoid triggering reload of theme settings unnecessarily, only set the
// setting when necessary.
const gchar* dark_setting = "gtk-application-prefer-dark-theme";
gboolean dark;
g_object_get(settings, dark_setting, &dark, nullptr);
// Disable dark theme because it interacts poorly with widget styling in
// web content (see bug 1216658).
// To avoid triggering reload of theme settings unnecessarily, only set the
// setting when necessary.
const gchar* dark_setting = "gtk-application-prefer-dark-theme";
gboolean dark;
g_object_get(settings, dark_setting, &dark, nullptr);
if (dark) {
g_object_set(settings, dark_setting, FALSE, nullptr);
}
if (dark) {
g_object_set(settings, dark_setting, FALSE, nullptr);
}
GtkWidgetPath *path = gtk_widget_path_new();