changeset 35691:dfdb25bad545

Enable resize handles for resizable windows only. Fixed size windows must have disabled resize handles.
author ib
date Fri, 18 Jan 2013 20:31:46 +0000
parents f6470f5787b9
children 7bc21ff6b1b2
files gui/wm/ws.c
diffstat 1 files changed, 5 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/gui/wm/ws.c	Fri Jan 18 20:29:02 2013 +0000
+++ b/gui/wm/ws.c	Fri Jan 18 20:31:46 2013 +0000
@@ -1022,7 +1022,11 @@
     wsMotifWmHints.flags = MWM_HINTS_FUNCTIONS | MWM_HINTS_DECORATIONS;
 
     if (decor) {
-        wsMotifWmHints.functions   = MWM_FUNC_MOVE | MWM_FUNC_CLOSE | MWM_FUNC_MINIMIZE | MWM_FUNC_MAXIMIZE | MWM_FUNC_RESIZE;
+        wsMotifWmHints.functions = MWM_FUNC_MOVE | MWM_FUNC_CLOSE | MWM_FUNC_MINIMIZE | MWM_FUNC_MAXIMIZE;
+
+        if (!(win->Property & wsMinSize) || !(win->Property & wsMaxSize))
+            wsMotifWmHints.functions |= MWM_FUNC_RESIZE;
+
         wsMotifWmHints.decorations = MWM_DECOR_ALL;
     }