[gnome-shell] hidpi: Make sure gdk and clutter scaling stays disabled when the scale factor changes



commit c4924153867c5f587d19e6c93d0f3a905571d2a8
Author: Adel Gadllah <adel gadllah gmail com>
Date:   Thu Mar 13 14:06:04 2014 +0100

    hidpi: Make sure gdk and clutter scaling stays disabled when the scale factor changes
    
    Not doing that could led to messy situations when the user changes the scale factor
    at runtime.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=726238

 src/shell-global.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/src/shell-global.c b/src/shell-global.c
index e055548..336639d 100644
--- a/src/shell-global.c
+++ b/src/shell-global.c
@@ -760,6 +760,10 @@ update_scale_factor (GtkSettings *settings,
   g_value_init (&value, G_TYPE_INT);
   if (gdk_screen_get_setting (global->gdk_screen, "gdk-window-scaling-factor", &value))
     g_object_set (context, "scale-factor", g_value_get_int (&value), NULL);
+
+  /* Make sure clutter and gdk scaling stays disabled */
+  g_object_set (clutter_settings_get_default (), "window-scaling-factor", 1, NULL);
+  gdk_x11_display_set_window_scale (gdk_display_get_default (), 1);
 }
 
 /* This is an IBus workaround. The flow of events with IBus is that every time


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]