Enlightenment CVS committal

Author  : raster
Project : e17
Module  : apps/e

Dir     : e17/apps/e/src/bin


Modified Files:
        e_border.c e_config.c e_config.h 


Log Message:


make dnd resistance a config value

===================================================================
RCS file: /cvsroot/enlightenment/e17/apps/e/src/bin/e_border.c,v
retrieving revision 1.220
retrieving revision 1.221
diff -u -3 -r1.220 -r1.221
--- e_border.c  20 May 2005 17:27:51 -0000      1.220
+++ e_border.c  21 May 2005 02:49:47 -0000      1.221
@@ -2612,13 +2612,12 @@
               }
             else
               {
-                 int x, y;
-                 double dist;
-
-                 x = bd->drag.x - ev->root.x;
-                 y = bd->drag.y - ev->root.y;
-                 dist = sqrt(pow(x, 2) + pow(y, 2));
-                 if (dist > 4)
+                 int dx, dy;
+                 
+                 dx = bd->drag.x - ev->root.x;
+                 dy = bd->drag.y - ev->root.y;
+                 if (((dx * dx) + (dy * dy)) > 
+                     (e_config->drag_resist * e_config->drag_resist))
                    {
                       /* start drag! */
                       if (bd->icon_object)
===================================================================
RCS file: /cvsroot/enlightenment/e17/apps/e/src/bin/e_config.c,v
retrieving revision 1.53
retrieving revision 1.54
diff -u -3 -r1.53 -r1.54
--- e_config.c  20 May 2005 10:14:51 -0000      1.53
+++ e_config.c  21 May 2005 02:49:47 -0000      1.54
@@ -144,6 +144,7 @@
    E_CONFIG_VAL(D, T, always_click_to_raise, INT);
    E_CONFIG_VAL(D, T, use_auto_raise, INT);
    E_CONFIG_VAL(D, T, auto_raise_delay, DOUBLE); 
+   E_CONFIG_VAL(D, T, drag_resist, INT);
 
    e_config = e_config_domain_load("e", _e_config_edd);
    if (e_config)
@@ -210,6 +211,7 @@
        e_config->always_click_to_raise = 0;
        e_config->use_auto_raise = 0;
        e_config->auto_raise_delay = 0.5;
+       e_config->drag_resist = 8;
          {
             E_Config_Module *em;
 
@@ -684,8 +686,12 @@
    E_CONFIG_LIMIT(e_config->zone_desks_y_count, 1, 64);
    E_CONFIG_LIMIT(e_config->use_edge_flip, 0, 1);
    E_CONFIG_LIMIT(e_config->edge_flip_timeout, 0.0, 2.0);
+   E_CONFIG_LIMIT(e_config->focus_policy, 0, 2);
+   E_CONFIG_LIMIT(e_config->pass_click_on, 0, 1);
+   E_CONFIG_LIMIT(e_config->always_click_to_raise, 0, 1);
    E_CONFIG_LIMIT(e_config->use_auto_raise, 0, 1);
    E_CONFIG_LIMIT(e_config->auto_raise_delay, 0.0, 5.0);
+   E_CONFIG_LIMIT(e_config->drag_resist, 0, 100);
 
    /* apply lang config - exception because config is loaded after intl setup 
*/
    
===================================================================
RCS file: /cvsroot/enlightenment/e17/apps/e/src/bin/e_config.h,v
retrieving revision 1.26
retrieving revision 1.27
diff -u -3 -r1.26 -r1.27
--- e_config.h  20 May 2005 10:14:51 -0000      1.26
+++ e_config.h  21 May 2005 02:49:47 -0000      1.27
@@ -46,7 +46,7 @@
  * defaults for e to work - started at 100 when we introduced this config
  * versioning feature
  */
-#define E_CONFIG_FILE_VERSION 105
+#define E_CONFIG_FILE_VERSION 106
 
 #define E_EVAS_ENGINE_DEFAULT      0
 #define E_EVAS_ENGINE_SOFTWARE_X11 1
@@ -98,6 +98,7 @@
    int         always_click_to_raise;
    int         use_auto_raise;
    double      auto_raise_delay;
+   int         drag_resist;
 };
 
 /* FIXME: all of thsie needs to become eet lumps for enmcode/decode */




-------------------------------------------------------
This SF.Net email is sponsored by Oracle Space Sweepstakes
Want to be the first software developer in space?
Enter now for the Oracle Space Sweepstakes!
http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to