Enlightenment CVS committal
Author : moom16
Project : e17
Module : apps/eclair
Dir : e17/apps/eclair/data/themes/default/scripts
Modified Files:
body_script.edc
Log Message:
* Edje: Use a clip to change the alpha of the swallowed cover instead of using
send_message
* Fix cover transition bugs
* Some default theme improvement
* Synchronize the cover and the meta tag threads with the main thread to avoid
aving files that have not been scanned for meta tags or cover
* Many cleanups and framework
===================================================================
RCS file:
/cvsroot/enlightenment/e17/apps/eclair/data/themes/default/scripts/body_script.edc,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -3 -r1.2 -r1.3
--- body_script.edc 3 May 2005 08:57:36 -0000 1.2
+++ body_script.edc 3 May 2005 20:36:33 -0000 1.3
@@ -1,5 +1,5 @@
#define COVER_ALPHA_SPEED 10
-#define COVER_ALPHA_MESSAGE 0
+#define COVER_UPDATE_INTERVAL 0.05
public cover_alpha = 0;
public previous_cover_alpha = 0;
@@ -7,19 +7,21 @@
public cover_is_set = 0;
public cover_set() {
- new ca;
-
- ca = get_int(cover_alpha);
- set_int(previous_cover_alpha, ca);
+ custom_state(PART:"cover_clip", "default");
+ set_state(PART:"cover_clip", "custom", 0.0);
+ custom_state(PART:"previous_cover_clip", "default");
+ set_state(PART:"previous_cover_clip", "custom", 0.0);
+ set_int(previous_cover_alpha, get_int(cover_alpha));
cover_change_cb(1);
}
public cover_unset() {
- new ca;
-
- ca = get_int(cover_alpha);
- set_int(previous_cover_alpha, ca);
+ custom_state(PART:"cover_clip", "default");
+ set_state(PART:"cover_clip", "custom", 0.0);
+ custom_state(PART:"previous_cover_clip", "default");
+ set_state(PART:"previous_cover_clip", "custom", 0.0);
+ set_int(previous_cover_alpha, get_int(cover_alpha));
cover_change_cb(0);
}
@@ -59,20 +61,25 @@
if (set == 0)
{
if (pca != 0)
- set_int(cover_timer, timer(0.05, "cover_change_cb", set));
+ set_int(cover_timer, timer(COVER_UPDATE_INTERVAL, "cover_change_cb",
set));
else
set_int(cover_timer, 0);
}
else
{
if (ca != 255 || pca != 0)
- set_int(cover_timer, timer(0.05, "cover_change_cb", set));
+ set_int(cover_timer, timer(COVER_UPDATE_INTERVAL, "cover_change_cb",
set));
else
set_int(cover_timer, 0);
}
+
+ set_state_val(PART:"cover_clip", STATE_COLOR, 255, 255, 255, ca);
+ set_state_val(PART:"previous_cover_clip", STATE_COLOR, 255, 255, 255, pca);
+
set_int(cover_alpha, ca);
set_int(previous_cover_alpha, pca);
- send_message(MSG_INT_SET, COVER_ALPHA_MESSAGE, ca, pca);
+ //TODO: edje bug: the edje object is not updated after the set_state_val
call
+ run_program(PROGRAM:"update");
}
-------------------------------------------------------
This SF.Net email is sponsored by: NEC IT Guy Games.
Get your fingers limbered up and give it your best shot. 4 great events, 4
opportunities to win big! Highest score wins.NEC IT Guy Games. Play to
win an NEC 61 plasma display. Visit http://www.necitguy.com/?r=20
_______________________________________________
enlightenment-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs