[gnome-flashback] monitor-config-manager: round layout size after scaling



commit 66f4ca375fe80618397666955b982b56ae9f13bd
Author: Alberts Muktupāvels <alberts muktupavels gmail com>
Date:   Tue Jul 16 22:14:09 2019 +0300

    monitor-config-manager: round layout size after scaling
    
    Based on mutter commit:
    https://gitlab.gnome.org/GNOME/mutter/commit/4786cc85bd3932da57f8

 backends/gf-monitor-config-manager.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/backends/gf-monitor-config-manager.c b/backends/gf-monitor-config-manager.c
index 931480b..3aa6fe3 100644
--- a/backends/gf-monitor-config-manager.c
+++ b/backends/gf-monitor-config-manager.c
@@ -179,8 +179,8 @@ create_preferred_logical_monitor_config (GfMonitorManager           *monitor_man
   switch (layout_mode)
     {
       case GF_LOGICAL_MONITOR_LAYOUT_MODE_LOGICAL:
-        width /= scale;
-        height /= scale;
+        width = (int) roundf (width / scale);
+        height = (int) roundf (height / scale);
         break;
 
       case GF_LOGICAL_MONITOR_LAYOUT_MODE_PHYSICAL:


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