[metacity] window: fix build warnings



commit 20932206907d55afaf121bb68dba1956cbcacc47
Author: Alberts Muktupāvels <alberts muktupavels gmail com>
Date:   Fri Sep 29 21:46:33 2017 +0300

    window: fix build warnings
    
    this statement may fall through [-Wimplicit-fallthrough=]

 src/core/window.c |   16 ++++++++++++----
 1 files changed, 12 insertions(+), 4 deletions(-)
---
diff --git a/src/core/window.c b/src/core/window.c
index 7a54b7f..3c5b2c2 100644
--- a/src/core/window.c
+++ b/src/core/window.c
@@ -6393,7 +6393,10 @@ meta_window_update_struts (MetaWindow *window)
                 {
                 case META_SIDE_RIGHT:
                   temp->rect.x = BOX_RIGHT(temp->rect) - thickness;
-                  /* Intentionally fall through without breaking */
+                  temp->rect.width = thickness;
+                  temp->rect.y = strut_begin;
+                  temp->rect.height = strut_end - strut_begin + 1;
+                  break;
                 case META_SIDE_LEFT:
                   temp->rect.width  = thickness;
                   temp->rect.y      = strut_begin;
@@ -6401,7 +6404,10 @@ meta_window_update_struts (MetaWindow *window)
                   break;
                 case META_SIDE_BOTTOM:
                   temp->rect.y = BOX_BOTTOM(temp->rect) - thickness;
-                  /* Intentionally fall through without breaking */
+                  temp->rect.height = thickness;
+                  temp->rect.x = strut_begin;
+                  temp->rect.width = strut_end - strut_begin + 1;
+                  break;
                 case META_SIDE_TOP:
                   temp->rect.height = thickness;
                   temp->rect.x      = strut_begin;
@@ -6456,13 +6462,15 @@ meta_window_update_struts (MetaWindow *window)
                 {
                 case META_SIDE_RIGHT:
                   temp->rect.x = BOX_RIGHT(temp->rect) - thickness;
-                  /* Intentionally fall through without breaking */
+                  temp->rect.width = thickness;
+                  break;
                 case META_SIDE_LEFT:
                   temp->rect.width  = thickness;
                   break;
                 case META_SIDE_BOTTOM:
                   temp->rect.y = BOX_BOTTOM(temp->rect) - thickness;
-                  /* Intentionally fall through without breaking */
+                  temp->rect.height = thickness;
+                  break;
                 case META_SIDE_TOP:
                   temp->rect.height = thickness;
                   break;


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