parent
ea03dc356c
commit
1372dc64c9
|
@ -118,6 +118,5 @@ _ephoto_display_usage(void)
|
||||||
"ephoto dirname : Specifies a directory to open\n");
|
"ephoto dirname : Specifies a directory to open\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
ELM_MAIN()
|
ELM_MAIN()
|
||||||
|
|
|
@ -13,18 +13,23 @@ ephoto_config_init(Ephoto *ephoto)
|
||||||
{
|
{
|
||||||
Eet_Data_Descriptor_Class eddc;
|
Eet_Data_Descriptor_Class eddc;
|
||||||
|
|
||||||
if (!eet_eina_stream_data_descriptor_class_set(&eddc, sizeof (eddc), "Ephoto_Config", sizeof(Ephoto_Config)))
|
if (!eet_eina_stream_data_descriptor_class_set(&eddc, sizeof (eddc),
|
||||||
|
"Ephoto_Config",
|
||||||
|
sizeof(Ephoto_Config)))
|
||||||
{
|
{
|
||||||
ERR("Unable to create the config data descriptor!");
|
ERR("Unable to create the config data descriptor!");
|
||||||
return EINA_FALSE;
|
return EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!edd) edd = eet_data_descriptor_stream_new(&eddc);
|
if (!edd) edd = eet_data_descriptor_stream_new(&eddc);
|
||||||
|
|
||||||
#undef T
|
#undef T
|
||||||
#undef D
|
#undef D
|
||||||
#define T Ephoto_Config
|
#define T Ephoto_Config
|
||||||
#define D edd
|
#define D edd
|
||||||
#define C_VAL(edd, type, member, dtype) EET_DATA_DESCRIPTOR_ADD_BASIC(edd, type, #member, member, dtype)
|
#define C_VAL(edd, type, member, dtype) \
|
||||||
|
EET_DATA_DESCRIPTOR_ADD_BASIC(edd, type, #member, member, dtype)
|
||||||
|
|
||||||
C_VAL(D, T, config_version, EET_T_INT);
|
C_VAL(D, T, config_version, EET_T_INT);
|
||||||
C_VAL(D, T, thumb_size, EET_T_INT);
|
C_VAL(D, T, thumb_size, EET_T_INT);
|
||||||
C_VAL(D, T, thumb_gen_size, EET_T_INT);
|
C_VAL(D, T, thumb_gen_size, EET_T_INT);
|
||||||
|
@ -50,7 +55,8 @@ ephoto_config_init(Ephoto *ephoto)
|
||||||
if (ephoto->config->config_version < 2)
|
if (ephoto->config->config_version < 2)
|
||||||
{
|
{
|
||||||
ephoto->config->slideshow_timeout = 4.0;
|
ephoto->config->slideshow_timeout = 4.0;
|
||||||
ephoto->config->slideshow_transition = eina_stringshare_add("fade");
|
ephoto->config->slideshow_transition =
|
||||||
|
eina_stringshare_add("fade");
|
||||||
}
|
}
|
||||||
if (ephoto->config->config_version < 3)
|
if (ephoto->config->config_version < 3)
|
||||||
ephoto->config->editor = eina_stringshare_add("gimp %s");
|
ephoto->config->editor = eina_stringshare_add("gimp %s");
|
||||||
|
|
|
@ -241,7 +241,8 @@ ephoto_window_add(const char *path)
|
||||||
free(dir);
|
free(dir);
|
||||||
ephoto_single_browser_path_pending_set(ephoto->single_browser, path);
|
ephoto_single_browser_path_pending_set(ephoto->single_browser, path);
|
||||||
|
|
||||||
elm_naviframe_item_simple_promote(ephoto->pager, ephoto->single_browser);
|
elm_naviframe_item_simple_promote(ephoto->pager,
|
||||||
|
ephoto->single_browser);
|
||||||
ephoto->state = EPHOTO_STATE_SINGLE;
|
ephoto->state = EPHOTO_STATE_SINGLE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -857,7 +857,7 @@ ephoto_single_browser_add(Ephoto *ephoto, Evas_Object *parent)
|
||||||
sep = elm_separator_add(sb->bar);
|
sep = elm_separator_add(sb->bar);
|
||||||
elm_box_pack_end(sb->bar, sep);
|
elm_box_pack_end(sb->bar, sep);
|
||||||
evas_object_show(sep);
|
evas_object_show(sep);
|
||||||
|
|
||||||
but = _button_add(sb->bar, PACKAGE_DATA_DIR "/images/zoom-in.png");
|
but = _button_add(sb->bar, PACKAGE_DATA_DIR "/images/zoom-in.png");
|
||||||
evas_object_smart_callback_add(but, "clicked", _zoom_in_cb, sb);
|
evas_object_smart_callback_add(but, "clicked", _zoom_in_cb, sb);
|
||||||
|
|
||||||
|
@ -879,7 +879,8 @@ ephoto_single_browser_add(Ephoto *ephoto, Evas_Object *parent)
|
||||||
evas_object_size_hint_align_set(sb->sentry, EVAS_HINT_FILL, EVAS_HINT_FILL);
|
evas_object_size_hint_align_set(sb->sentry, EVAS_HINT_FILL, EVAS_HINT_FILL);
|
||||||
elm_entry_single_line_set(sb->sentry, EINA_TRUE);
|
elm_entry_single_line_set(sb->sentry, EINA_TRUE);
|
||||||
elm_entry_scrollable_set(sb->sentry, EINA_TRUE);
|
elm_entry_scrollable_set(sb->sentry, EINA_TRUE);
|
||||||
elm_entry_scrollbar_policy_set(sb->sentry, ELM_SCROLLER_POLICY_OFF, ELM_SCROLLER_POLICY_OFF);
|
elm_entry_scrollbar_policy_set(sb->sentry, ELM_SCROLLER_POLICY_OFF,
|
||||||
|
ELM_SCROLLER_POLICY_OFF);
|
||||||
elm_object_disabled_set(sb->sentry, EINA_TRUE);
|
elm_object_disabled_set(sb->sentry, EINA_TRUE);
|
||||||
evas_object_smart_callback_add
|
evas_object_smart_callback_add
|
||||||
(sb->sentry, "activated", _changed_file_text, sb);
|
(sb->sentry, "activated", _changed_file_text, sb);
|
||||||
|
@ -934,7 +935,7 @@ ephoto_single_browser_entry_set(Evas_Object *obj, Ephoto_Entry *entry)
|
||||||
|
|
||||||
if (sb->entry)
|
if (sb->entry)
|
||||||
ephoto_entry_free_listener_del(sb->entry, _entry_free, sb);
|
ephoto_entry_free_listener_del(sb->entry, _entry_free, sb);
|
||||||
|
|
||||||
sb->entry = entry;
|
sb->entry = entry;
|
||||||
|
|
||||||
if (entry)
|
if (entry)
|
||||||
|
|
|
@ -337,7 +337,7 @@ _key_down(void *data, Evas *e __UNUSED__, Evas_Object *o __UNUSED__, void *event
|
||||||
{
|
{
|
||||||
if (!strcmp(k, "Up"))
|
if (!strcmp(k, "Up"))
|
||||||
{
|
{
|
||||||
if (strcmp(tb->ephoto->config->directory, "/") != 0)
|
if (strcmp(tb->ephoto->config->directory, "/"))
|
||||||
{
|
{
|
||||||
char *parent = ecore_file_dir_get
|
char *parent = ecore_file_dir_get
|
||||||
(tb->ephoto->config->directory);
|
(tb->ephoto->config->directory);
|
||||||
|
@ -522,7 +522,8 @@ ephoto_thumb_browser_add(Ephoto *ephoto, Evas_Object *parent)
|
||||||
evas_object_size_hint_align_set(tb->entry, EVAS_HINT_FILL, EVAS_HINT_FILL);
|
evas_object_size_hint_align_set(tb->entry, EVAS_HINT_FILL, EVAS_HINT_FILL);
|
||||||
elm_entry_single_line_set(tb->entry, EINA_TRUE);
|
elm_entry_single_line_set(tb->entry, EINA_TRUE);
|
||||||
elm_entry_scrollable_set(tb->entry, EINA_TRUE);
|
elm_entry_scrollable_set(tb->entry, EINA_TRUE);
|
||||||
elm_entry_scrollbar_policy_set(tb->entry, ELM_SCROLLER_POLICY_OFF, ELM_SCROLLER_POLICY_OFF);
|
elm_entry_scrollbar_policy_set(tb->entry, ELM_SCROLLER_POLICY_OFF,
|
||||||
|
ELM_SCROLLER_POLICY_OFF);
|
||||||
|
|
||||||
evas_object_smart_callback_add
|
evas_object_smart_callback_add
|
||||||
(tb->entry, "activated", _changed_dir_text, tb);
|
(tb->entry, "activated", _changed_dir_text, tb);
|
||||||
|
|
Loading…
Reference in New Issue