[mutter] tiling: do not tile if moving in snap mode



commit 6aa4bfd06042f6584bc07c65d5251c5779d9f850
Author: Rui Matos <tiagomatos gmail com>
Date:   Thu Oct 20 15:41:52 2011 +0100

    tiling: do not tile if moving in snap mode
    
    If we are moving in snap mode (shift pressed) we don't want to tile. We must
    also cancel any pending tiling if snap mode is activated during the move drag.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=662270

 src/core/window.c |   13 ++++++++++---
 1 files changed, 10 insertions(+), 3 deletions(-)
---
diff --git a/src/core/window.c b/src/core/window.c
index 3b29660..3162b66 100644
--- a/src/core/window.c
+++ b/src/core/window.c
@@ -8432,9 +8432,16 @@ update_move (MetaWindow  *window,
   shake_threshold = meta_ui_get_drag_threshold (window->screen->ui) *
     DRAG_THRESHOLD_TO_SHAKE_THRESHOLD_FACTOR;
 
-  if (meta_prefs_get_edge_tiling () &&
-      !META_WINDOW_MAXIMIZED (window) &&
-      !META_WINDOW_TILED_SIDE_BY_SIDE (window))
+  if (snap)
+    {
+      /* We don't want to tile while snapping. Also, clear any previous tile
+         request. */
+      window->tile_mode = META_TILE_NONE;
+      window->tile_monitor_number = -1;
+    }
+  else if (meta_prefs_get_edge_tiling () &&
+           !META_WINDOW_MAXIMIZED (window) &&
+           !META_WINDOW_TILED_SIDE_BY_SIDE (window))
     {
       const MetaMonitorInfo *monitor;
       MetaRectangle work_area;



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