Currently an initial _NET_WM_STATE_MAXIMIZED_HORZ hint is ignored because _NET_WM_STATE_MAXIMIZED_HORIZ is checked first, and once the state is set it cannot be changed again. This patch changes the behavior of ewmh_WMStateMaxHoriz so that having either MAXIMIZED_HORZ or MAXIMIZED_HORIZ makes the window maximized.
Index: ChangeLog =================================================================== RCS file: /home/cvs/fvwm/fvwm/ChangeLog,v retrieving revision 1.3060 diff -u -p -r1.3060 ChangeLog --- ChangeLog 28 Nov 2008 23:29:27 -0000 1.3060 +++ ChangeLog 29 Dec 2008 13:28:14 -0000 @@ -1,3 +1,9 @@ +2008-12-29 Alexandre Julliard <[email protected]> + + * fvwm/ewmh_events.c (ewmh_WMStateMaxHoriz): Having either + _NET_WM_STATE_MAXIMIZED_HORIZ or _NET_WM_STATE_MAXIMIZED_HORZ + should be enough to make the window horizontally maximized. + 2008-11-29 Dominik Vogt <dominik(dot)vogt(at)gmx(dot)de> * fvwm/fvwm.h: Index: fvwm/ewmh_events.c =================================================================== RCS file: /home/cvs/fvwm/fvwm/fvwm/ewmh_events.c,v retrieving revision 1.63 diff -u -p -r1.63 ewmh_events.c --- fvwm/ewmh_events.c 8 Aug 2008 12:12:23 -0000 1.63 +++ fvwm/ewmh_events.c 29 Dec 2008 13:28:15 -0000 @@ -743,8 +743,13 @@ int ewmh_WMStateMaxHoriz(EWMH_CMD_ARGS) fw, EWMH_STATE_UNDEFINED_HINT); return 0; } - if (HAS_EWMH_INIT_MAXHORIZ_STATE(fw) != - EWMH_STATE_UNDEFINED_HINT) + + /* If the initial state is STATE_NO_HINT we still want to + * override it, since having just one of MAXIMIZED_HORIZ or + * MAXIMIZED_HORZ is enough to make the window maximized. + */ + if (HAS_EWMH_INIT_MAXHORIZ_STATE(fw) == + EWMH_STATE_HAS_HINT) { return 0; } -- Alexandre Julliard [email protected]
