Enlightenment CVS committal Author : handyande Project : misc Module : engage
Dir : misc/engage/src/module Modified Files: e_mod_main.c e_mod_main.h Log Message: Try to fix the sometimes-events-dont-show-on-bar issue.... =================================================================== RCS file: /cvsroot/enlightenment/misc/engage/src/module/e_mod_main.c,v retrieving revision 1.79 retrieving revision 1.80 diff -u -3 -r1.79 -r1.80 --- e_mod_main.c 6 Dec 2005 13:21:07 -0000 1.79 +++ e_mod_main.c 6 Dec 2005 14:09:42 -0000 1.80 @@ -594,6 +594,7 @@ eb->x = eb->y = eb->w = eb->h = -1; eb->zoom = 1.0; + eb->zoom_start_time = 0.0; eb->zooming = 0; eb->mouse_out = -1; @@ -2198,25 +2199,25 @@ _engage_zoom_in_slave(void *data) { Evas_Coord x, y; - static double start_time = 0; Engage_Bar *eb; eb = data; - if (start_time == 0) + if (eb->zoom_start_time == 0) { eb->zooming = 1; - start_time = ecore_time_get(); + eb->zoom_start_time = ecore_time_get(); } - eb->zoom = (eb->conf->zoom_factor - 1.0) * ((ecore_time_get() - start_time) - / eb->conf->zoom_duration) + 1.0; + eb->zoom = (eb->conf->zoom_factor - 1.0) * + ((ecore_time_get() - eb->zoom_start_time) + / eb->conf->zoom_duration) + 1.0; evas_pointer_canvas_xy_get(eb->evas, &x, &y); if (eb->zoom >= eb->conf->zoom_factor) { eb->zoom = eb->conf->zoom_factor; _engage_zoom_timer = NULL; - start_time = 0; + eb->zoom_start_time = 0; _engage_bar_motion_handle(eb, x, y); return 0; } @@ -2228,15 +2229,14 @@ _engage_zoom_out_slave(void *data) { Evas_Coord x, y, bx, by, bw, bh; - static double start_time = 0; Engage_Bar *eb; eb = data; - if (start_time == 0) - start_time = ecore_time_get(); + if (eb->zoom_start_time == 0) + eb->zoom_start_time = ecore_time_get(); eb->zoom = (eb->conf->zoom_factor - 1.0) * (1.0 - (ecore_time_get() - - start_time) / eb->conf->zoom_duration) + 1.0; + - eb->zoom_start_time) / eb->conf->zoom_duration) + 1.0; evas_pointer_canvas_xy_get(eb->evas, &x, &y); @@ -2244,7 +2244,7 @@ { eb->zoom = 1.0; _engage_zoom_timer = NULL; - start_time = 0; + eb->zoom_start_time = 0; evas_object_geometry_get(eb->box_object, &bx, &by, &bw, &bh); evas_object_move(eb->event_object, bx, by); evas_object_resize(eb->event_object, bw, bh); =================================================================== RCS file: /cvsroot/enlightenment/misc/engage/src/module/e_mod_main.h,v retrieving revision 1.21 retrieving revision 1.22 diff -u -3 -r1.21 -r1.22 --- e_mod_main.h 5 Dec 2005 21:00:35 -0000 1.21 +++ e_mod_main.h 6 Dec 2005 14:09:42 -0000 1.22 @@ -77,6 +77,7 @@ Evas_Coord x, y, w, h; double zoom; int zooming; + double zoom_start_time; E_Gadman_Client *gmc; ------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click _______________________________________________ enlightenment-cvs mailing list enlightenment-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs