summaryrefslogtreecommitdiff
path: root/src/lib/emotion
diff options
context:
space:
mode:
authorTom Hacohen <tom@stosb.com>2014-08-06 11:56:01 +0100
committerTom Hacohen <tom@stosb.com>2014-08-21 11:02:11 +0100
commit0f3ccbfd172ca6746910a00cb4e598a971d89d81 (patch)
tree1ed26bb5d491f758e4615b304a0a650e1545d6e6 /src/lib/emotion
parentee5be295d0fa47f53b88dc6739453c9e322adb9e (diff)
Emotion object: Create .eo file.
Diffstat (limited to 'src/lib/emotion')
-rw-r--r--src/lib/emotion/Emotion.h2
-rw-r--r--src/lib/emotion/emotion_object.eo91
-rw-r--r--src/lib/emotion/emotion_smart.c1
3 files changed, 94 insertions, 0 deletions
diff --git a/src/lib/emotion/Emotion.h b/src/lib/emotion/Emotion.h
index 7240d2f251..f11cbc71ec 100644
--- a/src/lib/emotion/Emotion.h
+++ b/src/lib/emotion/Emotion.h
@@ -360,6 +360,8 @@ extern "C" {
360EAPI Eina_Bool emotion_init(void); 360EAPI Eina_Bool emotion_init(void);
361EAPI Eina_Bool emotion_shutdown(void); 361EAPI Eina_Bool emotion_shutdown(void);
362 362
363#include "emotion_object.eo.h"
364
363/** 365/**
364 * @brief Add an emotion object to the canvas. 366 * @brief Add an emotion object to the canvas.
365 * 367 *
diff --git a/src/lib/emotion/emotion_object.eo b/src/lib/emotion/emotion_object.eo
new file mode 100644
index 0000000000..92e1b25c51
--- /dev/null
+++ b/src/lib/emotion/emotion_object.eo
@@ -0,0 +1,91 @@
1class Emotion.Object (Efl.File, Efl.Player, Efl.Image) {
2 eo_prefix: emotion_obj;
3 properties {
4 option {
5 set {
6 /**
7 * @brief Set the specified option for the current module.
8 *
9 * This function allows one to mute the video or audio of the emotion object.
10 *
11 * @note Please don't use this function, consider using
12 * emotion_object_audio_mute_set() and emotion_object_video_mute_set() instead.
13 *
14 * @see emotion_object_audio_mute_set()
15 * @see emotion_object_video_mute_set()
16 *
17 * @ingroup Emotion_Init
18 */
19 legacy emotion_object_module_option_set;
20 }
21 values {
22 const(char) *opt; /*@ The option that is being set. Currently supported optiosn: "video" and "audio". */
23 const(char) *val; /*@ The value of the option. Currently only supports "off" (?!?!?!) */
24 }
25 }
26 engine {
27 set {
28 /**
29 * @brief Initializes an emotion object with the specified module.
30 *
31 * This function is required after creating the emotion object, in order to
32 * specify which module will be used with this object. Different objects can
33 * use different modules to play a media file. The current supported modules are
34 * @b gstreamer and @b xine.
35 *
36 * To use any of them, you need to make sure that support for them was compiled
37 * correctly.
38 *
39 * @note It's possible to disable the build of a module with
40 * --disable-module_name.
41 *
42 * @see emotion_object_add()
43 * @see emotion_object_file_set()
44 *
45 * @ingroup Emotion_Init
46 */
47 legacy emotion_object_init;
48 return bool; /*@ @c EINA_TRUE if the specified module was successfully initialized for this object, @c EINA_FALSE otherwise. */
49 }
50 values {
51 const(char) *module_filename; /*@ The name of the module to be used (gstreamer or xine). */
52 }
53 }
54 }
55 implements {
56 Efl.File.file.set;
57 Efl.File.file.get;
58 Efl.Player.play.set;
59 Efl.Player.play.get;
60 Efl.Player.position.set;
61 Efl.Player.position.get;
62 Efl.Player.progress.get;
63 Efl.Player.audio_volume.set;
64 Efl.Player.audio_volume.get;
65 Efl.Player.audio_mute.set;
66 Efl.Player.audio_mute.get;
67 Efl.Image.load_size.get;
68 Efl.Image.ratio.get;
69 Efl.Image.smooth_scale.set;
70 Efl.Image.smooth_scale.get;
71 }
72}
73
74/* FIXME: Need to be added:
75EAPI double emotion_object_buffer_size_get (const Evas_Object *obj);
76EAPI Eina_Bool emotion_object_seekable_get (const Evas_Object *obj);
77EAPI double emotion_object_play_length_get (const Evas_Object *obj);
78EAPI const char *emotion_object_progress_info_get (const Evas_Object *obj);
79EAPI Eina_Bool emotion_object_video_handled_get (const Evas_Object *obj);
80EAPI Eina_Bool emotion_object_audio_handled_get (const Evas_Object *obj);
81
82Everything starting from (needs to be added):
83EAPI int emotion_object_audio_channel_count (const Evas_Object *obj);
84
85Should this be part of player or emotion object?
86EAPI void emotion_object_event_simple_send (Evas_Object *obj, Emotion_Event ev);
87
88Deliberations:
89Should this really implement the image interface?
90*/
91
diff --git a/src/lib/emotion/emotion_smart.c b/src/lib/emotion/emotion_smart.c
index ed19ce4a77..dc809d77a9 100644
--- a/src/lib/emotion/emotion_smart.c
+++ b/src/lib/emotion/emotion_smart.c
@@ -1968,3 +1968,4 @@ _smart_clip_unset(Evas_Object * obj)
1968 evas_object_clip_unset(sd->bg); 1968 evas_object_clip_unset(sd->bg);
1969} 1969}
1970 1970
1971#include "emotion_object.eo.h"