discomfitor pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=8b4162d681dc3488169e73edd205aa8177160c9f

commit 8b4162d681dc3488169e73edd205aa8177160c9f
Author: Mike Blumenkrantz <[email protected]>
Date:   Wed Mar 5 09:30:09 2014 -0500

    fix maximization geometry on desks with shelves
    
    in some cases during startup a client can get post-maximize geometry before 
the sizing algorithm is applied
    
    fix T1052
---
 src/bin/e_maximize.c | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/src/bin/e_maximize.c b/src/bin/e_maximize.c
index df3bc45..3b5e971 100644
--- a/src/bin/e_maximize.c
+++ b/src/bin/e_maximize.c
@@ -211,18 +211,18 @@ _e_maximize_client_rects_fill_both(E_Client *ec, 
Eina_List *rects, int *x1, int
    if (y2) hy2 = vy2 = *y2;
 
    /* Init working values, try maximizing horizontally first */
-   bx = ec->x;
-   by = ec->y;
-   bw = ec->w;
-   bh = ec->h;
+   bx = ec->saved.x ?: ec->x;
+   by = ec->saved.y ?: ec->y;
+   bw = ec->saved.w ?: ec->w;
+   bh = ec->saved.h ?: ec->h;
    _e_maximize_client_rects_fill_horiz(ec, rects, &hx1, &hx2, &bx, &by, &bw, 
&bh);
    _e_maximize_client_rects_fill_vert(ec, rects, &hy1, &hy2, &bx, &by, &bw, 
&bh);
 
    /* Reset working values, try maximizing vertically first */
-   bx = ec->x;
-   by = ec->y;
-   bw = ec->w;
-   bh = ec->h;
+   bx = ec->saved.x ?: ec->x;
+   by = ec->saved.y ?: ec->y;
+   bw = ec->saved.w ?: ec->w;
+   bh = ec->saved.h ?: ec->h;
    _e_maximize_client_rects_fill_vert(ec, rects, &vy1, &vy2, &bx, &by, &bw, 
&bh);
    _e_maximize_client_rects_fill_horiz(ec, rects, &vx1, &vx2, &bx, &by, &bw, 
&bh);
 

-- 


Reply via email to