forked from enlightenment/rage
remove emotion obj init as its pretty pointless these days
This commit is contained in:
parent
8d8a210798
commit
65a614e5e2
|
@ -19,7 +19,7 @@ config_init(void)
|
||||||
(&eddc, sizeof(eddc), "Config", sizeof(Config));
|
(&eddc, sizeof(eddc), "Config", sizeof(Config));
|
||||||
edd_base = eet_data_descriptor_stream_new(&eddc);
|
edd_base = eet_data_descriptor_stream_new(&eddc);
|
||||||
EET_DATA_DESCRIPTOR_ADD_BASIC
|
EET_DATA_DESCRIPTOR_ADD_BASIC
|
||||||
(edd_base, Config, "emotion_engine", emotion_engine, EET_T_STRING);
|
(edd_base, Config, "version", version, EET_T_INT);
|
||||||
snprintf(buf, sizeof(buf), "%s/rage/config/standard/base.cfg", efreet_config_home_get());
|
snprintf(buf, sizeof(buf), "%s/rage/config/standard/base.cfg", efreet_config_home_get());
|
||||||
ef = eet_open(buf, EET_FILE_MODE_READ);
|
ef = eet_open(buf, EET_FILE_MODE_READ);
|
||||||
if (ef)
|
if (ef)
|
||||||
|
@ -31,8 +31,7 @@ config_init(void)
|
||||||
{
|
{
|
||||||
config = calloc(1, sizeof(Config));
|
config = calloc(1, sizeof(Config));
|
||||||
if (!config) abort();
|
if (!config) abort();
|
||||||
// xine vlc gstreamer1
|
config->version = 1;
|
||||||
config->emotion_engine = eina_stringshare_add("gstreamer1");
|
|
||||||
config_save();
|
config_save();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -40,7 +39,6 @@ config_init(void)
|
||||||
void
|
void
|
||||||
config_shutdown(void)
|
config_shutdown(void)
|
||||||
{
|
{
|
||||||
if (config->emotion_engine) eina_stringshare_del(config->emotion_engine);
|
|
||||||
free(config);
|
free(config);
|
||||||
if (edd_base)
|
if (edd_base)
|
||||||
{
|
{
|
||||||
|
|
|
@ -5,7 +5,7 @@ typedef struct _Config Config;
|
||||||
|
|
||||||
struct _Config
|
struct _Config
|
||||||
{
|
{
|
||||||
const char *emotion_engine;
|
int version; // dummy - unused atm
|
||||||
};
|
};
|
||||||
|
|
||||||
void config_init(void);
|
void config_init(void);
|
||||||
|
|
|
@ -192,9 +192,6 @@ elm_main(int argc, char **argv)
|
||||||
"\n"
|
"\n"
|
||||||
" -f\n"
|
" -f\n"
|
||||||
" Enable fullscreen mode at start\n"
|
" Enable fullscreen mode at start\n"
|
||||||
" -e ENGINE\n"
|
|
||||||
" ENGINE is one of gstreamer1, xine or vlc\n"
|
|
||||||
" The default is gstreamer1\n"
|
|
||||||
"\n"
|
"\n"
|
||||||
" -sub SUBTITLE_FILE\n"
|
" -sub SUBTITLE_FILE\n"
|
||||||
" This sets the subtitle file to use for the\n"
|
" This sets the subtitle file to use for the\n"
|
||||||
|
@ -209,15 +206,6 @@ elm_main(int argc, char **argv)
|
||||||
, DEPTH_DEFAULT);
|
, DEPTH_DEFAULT);
|
||||||
exit(0);
|
exit(0);
|
||||||
}
|
}
|
||||||
else if (!strcmp(argv[i], "-e"))
|
|
||||||
{
|
|
||||||
if (i < (argc - 1))
|
|
||||||
{
|
|
||||||
i++;
|
|
||||||
eina_stringshare_del(config->emotion_engine);
|
|
||||||
config->emotion_engine = eina_stringshare_add(argv[i]);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (!strcmp(argv[i], "-f"))
|
else if (!strcmp(argv[i], "-f"))
|
||||||
{
|
{
|
||||||
fullscreen = EINA_TRUE;
|
fullscreen = EINA_TRUE;
|
||||||
|
|
|
@ -196,7 +196,6 @@ _local_artwork_poster(Evas_Object *win, const char *path_to_file)
|
||||||
{
|
{
|
||||||
Evas_Object *em = emotion_object_add(evas_object_evas_get(win));
|
Evas_Object *em = emotion_object_add(evas_object_evas_get(win));
|
||||||
|
|
||||||
emotion_object_init(em, NULL);
|
|
||||||
emotion_object_file_set(em, path_to_file);
|
emotion_object_file_set(em, path_to_file);
|
||||||
|
|
||||||
char *path = albumart_file_get(path_to_file);
|
char *path = albumart_file_get(path_to_file);
|
||||||
|
@ -277,13 +276,11 @@ elm_main(int argc, char **argv)
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (emotion_object_init(vid, NULL))
|
|
||||||
{
|
|
||||||
evas_object_smart_callback_add(vid, "open_done", _cb_loaded, file);
|
evas_object_smart_callback_add(vid, "open_done", _cb_loaded, file);
|
||||||
emotion_object_file_set(vid, file);
|
emotion_object_file_set(vid, file);
|
||||||
vid_timeout = ecore_timer_add(360.0, _cb_timeout, NULL);
|
vid_timeout = ecore_timer_add(360.0, _cb_timeout, NULL);
|
||||||
elm_run();
|
elm_run();
|
||||||
}
|
|
||||||
out:
|
out:
|
||||||
elm_shutdown();
|
elm_shutdown();
|
||||||
|
|
||||||
|
|
|
@ -581,12 +581,6 @@ video_add(Evas_Object *parent)
|
||||||
o = sd->o_vid = emotion_object_add(evas_object_evas_get(obj));
|
o = sd->o_vid = emotion_object_add(evas_object_evas_get(obj));
|
||||||
emotion_object_keep_aspect_set(o, EMOTION_ASPECT_KEEP_NONE);
|
emotion_object_keep_aspect_set(o, EMOTION_ASPECT_KEEP_NONE);
|
||||||
config = config_get();
|
config = config_get();
|
||||||
if (!emotion_object_init(o, config->emotion_engine))
|
|
||||||
{
|
|
||||||
evas_object_del(sd->o_vid);
|
|
||||||
sd->o_vid = NULL;
|
|
||||||
return obj;
|
|
||||||
}
|
|
||||||
evas_object_smart_callback_add(o, "frame_decode", _cb_vid_frame, obj);
|
evas_object_smart_callback_add(o, "frame_decode", _cb_vid_frame, obj);
|
||||||
evas_object_smart_callback_add(o, "frame_resize", _cb_vid_resize, obj);
|
evas_object_smart_callback_add(o, "frame_resize", _cb_vid_resize, obj);
|
||||||
evas_object_smart_callback_add(o, "decode_stop", _cb_vid_stop, obj);
|
evas_object_smart_callback_add(o, "decode_stop", _cb_vid_stop, obj);
|
||||||
|
|
Loading…
Reference in New Issue