[Xfce4-commits] [xfce/xfwm4] 04/18: workarea: Ignore change without a primary monitor
noreply at xfce.org
noreply at xfce.org
Sat Apr 11 17:58:40 CEST 2020
This is an automated email from the git hooks/post-receive script.
o l i v i e r p u s h e d a c o m m i t t o b r a n c h x f c e - 4 . 1 4
in repository xfce/xfwm4.
commit e7611ebba4ddc790be8b128d8968a53349429d7a
Author: Olivier Fourdan <fourdan at xfce.org>
Date: Wed Aug 28 10:42:11 2019 -0600
workarea: Ignore change without a primary monitor
If there is no primary monitor, i.e. because no monitor at all, there is
no point in updating the workarea.
Signed-off-by: Olivier Fourdan <fourdan at xfce.org>
(cherry picked from commit d6e5d6e06c02a76882b55b3f80f654f05cdd10c6)
---
src/workspaces.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/src/workspaces.c b/src/workspaces.c
index 6981845..4b6bd2d 100644
--- a/src/workspaces.c
+++ b/src/workspaces.c
@@ -543,13 +543,17 @@ workspaceUpdateArea (ScreenInfo *screen_info)
prev_right = screen_info->margins[STRUTS_RIGHT];
prev_bottom = screen_info->margins[STRUTS_BOTTOM];
+ if (!xfwm_get_primary_monitor_geometry (screen_info->gscr, &workarea, TRUE))
+ {
+ TRACE ("No monitor attached");
+ return;
+ }
+
for (i = 0; i < 4; i++)
{
screen_info->margins[i] = screen_info->gnome_margins[i];
}
- xfwm_get_primary_monitor_geometry (screen_info->gscr, &workarea, TRUE);
-
for (c = screen_info->clients, i = 0; i < screen_info->client_count; c = c->next, i++)
{
if (strutsToRectangles (c, &left, &right, &top, &bottom))
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the Xfce4-commits
mailing list