Enlightenment CVS committal

Author  : kwo
Project : e16
Module  : e

Dir     : e16/e/src


Modified Files:
        moveresize.c 


Log Message:
Reduce size of H/V resize only regions.
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/moveresize.c,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -3 -r1.24 -r1.25
--- moveresize.c        20 Nov 2004 17:55:12 -0000      1.24
+++ moveresize.c        21 Nov 2004 20:37:38 -0000      1.25
@@ -254,7 +254,7 @@
 int
 ActionResizeStart(EWin * ewin, const void *params, int hv)
 {
-   int                 x, y, w, h;
+   int                 x, y, w, h, ww, hh;
 
    EDBUG(6, "DoResize");
 
@@ -281,6 +281,8 @@
        y = Mode.y - ewin->y;
        w = ewin->w >> 1;
        h = ewin->h >> 1;
+       ww = ewin->w / 6;
+       hh = ewin->h / 6;
        if ((x < w) && (y < h))
           Mode.resize_detail = 0;
        if ((x >= w) && (y < h))
@@ -293,22 +295,22 @@
        /* The following four if statements added on 07/22/04 by Josh Holtrop.
         * They allow strictly horizontal or vertical resizing when the
         * cursor is towards the middle of an edge of a window. */
-       if ((abs(x - w) < (w >> 1)) && (y < (h >> 1)))
+       if ((abs(x - w) < (w >> 1)) && (y < hh))
          {
             Mode.mode = MODE_RESIZE_V;
             Mode.resize_detail = 0;
          }
-       else if ((abs(x - w) < (w >> 1)) && (y > (h + (h >> 1))))
+       else if ((abs(x - w) < (w >> 1)) && (y > (ewin->h - hh)))
          {
             Mode.mode = MODE_RESIZE_V;
             Mode.resize_detail = 1;
          }
-       else if ((abs(y - h) < (h >> 1)) && (x < (w >> 1)))
+       else if ((abs(y - h) < (h >> 1)) && (x < ww))
          {
             Mode.mode = MODE_RESIZE_H;
             Mode.resize_detail = 0;
          }
-       else if ((abs(y - h) < (h >> 1)) && (x > (w + (w >> 1))))
+       else if ((abs(y - h) < (h >> 1)) && (x > (ewin->w - ww)))
          {
             Mode.mode = MODE_RESIZE_H;
             Mode.resize_detail = 1;




-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to