[gnome-flashback] backends: do not change current orientation when locked



commit b537b0ed679da78ef2fba73374aa26adc18ffff3
Author: Alberts Muktupāvels <alberts muktupavels gmail com>
Date:   Tue Feb 18 19:33:49 2020 +0200

    backends: do not change current orientation when locked
    
    https://gitlab.gnome.org/GNOME/mutter/commit/c37e2523ace072a7fd556

 backends/gf-orientation-manager.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/backends/gf-orientation-manager.c b/backends/gf-orientation-manager.c
index b2f411c..9c1fe81 100644
--- a/backends/gf-orientation-manager.c
+++ b/backends/gf-orientation-manager.c
@@ -106,6 +106,9 @@ read_iio_proxy (GfOrientationManager *manager)
 static void
 sync_state (GfOrientationManager *manager)
 {
+  if (g_settings_get_boolean (manager->settings, ORIENTATION_LOCK_KEY))
+    return;
+
   read_iio_proxy (manager);
 
   if (manager->prev_orientation == manager->curr_orientation)
@@ -115,9 +118,6 @@ sync_state (GfOrientationManager *manager)
   if (manager->curr_orientation == GF_ORIENTATION_UNDEFINED)
     return;
 
-  if (g_settings_get_boolean (manager->settings, ORIENTATION_LOCK_KEY))
-    return;
-
   g_signal_emit (manager, manager_signals[ORIENTATION_CHANGED], 0);
 }
 


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