diff cagou/core/widgets_handler.py @ 160:916af9c1cb9b

widget handler: don't set split delete mode if there is not top/left widget
author Goffi <goffi@goffi.org>
date Sat, 28 Apr 2018 10:57:17 +0200
parents a0e486074d91
children ef09dce878c7
line wrap: on
line diff
--- a/cagou/core/widgets_handler.py	Sat Apr 28 10:43:54 2018 +0200
+++ b/cagou/core/widgets_handler.py	Sat Apr 28 10:57:17 2018 +0200
@@ -182,7 +182,7 @@
 
                 if top.height <= REMOVE_WID_LIMIT:
                     # we are in remove zone, we add visual hint for that
-                    if not self._split_del:
+                    if not self._split_del and self._top_wids:
                         self._split_del = True
                         self._draw_ellipse()
                 else:
@@ -227,7 +227,7 @@
 
                 if left.width <= REMOVE_WID_LIMIT:
                     # we are in remove zone, we add visual hint for that
-                    if not self._split_del:
+                    if not self._split_del and self._left_wids:
                         self._split_del = True
                         self._draw_ellipse()
                 else: