Enlightenment CVS committal
Author : dj2
Project : e17
Module : libs/ewl
Dir : e17/libs/ewl/src/bin/tests
Modified Files:
ewl_media.c
Log Message:
- fixup the media test a bit
===================================================================
RCS file: /cvs/e/e17/libs/ewl/src/bin/tests/ewl_media.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -3 -r1.4 -r1.5
--- ewl_media.c 28 May 2006 01:32:17 -0000 1.4
+++ ewl_media.c 28 May 2006 02:36:25 -0000 1.5
@@ -26,7 +26,6 @@
static void stop_cb(Ewl_Widget *w, void *event, void *data);
static void ff_cb(Ewl_Widget *w, void *event, void *data);
static void rew_cb(Ewl_Widget *w, void *event, void *data);
-static void video_realize_cb(Ewl_Widget *w, void *event, void *data);
static void video_change_cb(Ewl_Widget *w, void *event, void *data);
static void seeker_move_cb(Ewl_Widget *w, void *event, void *data);
static void open_file_cb(Ewl_Widget *w, void *event, void *data);
@@ -150,16 +149,6 @@
}
static void
-video_realize_cb(Ewl_Widget *w __UNUSED__, void *event __UNUSED__,
- void *data __UNUSED__)
-{
- double len;
-
- len = ewl_media_length_get(EWL_MEDIA(video));
- ewl_seeker_range_set(EWL_SEEKER(seeker), len);
-}
-
-static void
video_change_cb(Ewl_Widget *w __UNUSED__, void *event __UNUSED__, void *data)
{
char buf[512];
@@ -198,6 +187,7 @@
e = event;
if (e->response == EWL_STOCK_OK)
{
+ int len;
char *file = NULL;
char buf[PATH_MAX];
@@ -207,7 +197,10 @@
file);
ewl_media_media_set(EWL_MEDIA(video), buf);
- IF_FREE(file);
+ if (file) free(file);
+
+ len = ewl_media_length_get(EWL_MEDIA(video));
+ ewl_seeker_range_set(EWL_SEEKER(seeker), len);
}
}
@@ -270,7 +263,6 @@
ewl_container_child_append(EWL_CONTAINER(b), video);
ewl_media_module_set(EWL_MEDIA(video), type);
ewl_object_fill_policy_set(EWL_OBJECT(video), EWL_FLAG_FILL_ALL);
- ewl_callback_append(video, EWL_CALLBACK_REALIZE, video_realize_cb,
NULL);
ewl_callback_append(video, EWL_CALLBACK_VALUE_CHANGED, video_change_cb,
time);
ewl_widget_show(video);
@@ -281,7 +273,7 @@
ewl_container_child_append(EWL_CONTAINER(b), controls);
ewl_widget_show(controls);
- /* hold he controls */
+ /* hold the controls */
b = ewl_hbox_new();
ewl_container_child_append(EWL_CONTAINER(controls), b);
ewl_widget_show(b);
-------------------------------------------------------
All the advantages of Linux Managed Hosting--Without the Cost and Risk!
Fully trained technicians. The highest number of Red Hat certifications in
the hosting industry. Fanatical Support. Click to learn more
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=107521&bid=248729&dat=121642
_______________________________________________
enlightenment-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs