Blame SOURCES/0001-constraints-Fix-titlebars-going-off-the-bottom.patch

8ae457
From 2fd734c349ab00f2f460af97f7c383678407f620 Mon Sep 17 00:00:00 2001
8ae457
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
8ae457
Date: Wed, 16 Jan 2019 01:09:26 +0100
8ae457
Subject: [PATCH] constraints: Fix titlebars going off the bottom
8ae457
8ae457
The "current" rect includes the frame, so in order to keep the
8ae457
titlebar on screen, window movement must be restricted to at
8ae457
most (height - titlebar_height) past the work area bottom.
8ae457
8ae457
https://gitlab.gnome.org/GNOME/mutter/merge_requests/391
8ae457
---
8ae457
 src/core/constraints.c | 4 ++--
8ae457
 1 file changed, 2 insertions(+), 2 deletions(-)
8ae457
8ae457
diff --git a/src/core/constraints.c b/src/core/constraints.c
8ae457
index 3b6203d6b..92b146ce3 100644
8ae457
--- a/src/core/constraints.c
8ae457
+++ b/src/core/constraints.c
8ae457
@@ -1570,7 +1570,7 @@ constrain_titlebar_visible (MetaWindow         *window,
8ae457
       MetaFrameBorders borders;
8ae457
       meta_frame_calc_borders (window->frame, &borders);
8ae457
 
8ae457
-      bottom_amount = info->current.height + borders.visible.bottom;
8ae457
+      bottom_amount = info->current.height - borders.visible.top;
8ae457
       vert_amount_onscreen = borders.visible.top;
8ae457
     }
8ae457
   else
8ae457
@@ -1649,7 +1649,7 @@ constrain_partially_onscreen (MetaWindow         *window,
8ae457
       MetaFrameBorders borders;
8ae457
       meta_frame_calc_borders (window->frame, &borders);
8ae457
 
8ae457
-      bottom_amount = info->current.height + borders.visible.bottom;
8ae457
+      bottom_amount = info->current.height - borders.visible.top;
8ae457
       vert_amount_onscreen = borders.visible.top;
8ae457
     }
8ae457
   else
8ae457
-- 
8ae457
2.20.1
8ae457