Ephoto: Add ability to scale images.
This commit is contained in:
parent
69a25b6453
commit
9394902746
|
@ -32,10 +32,11 @@ ephoto_SOURCES = \
|
|||
ephoto_ipc.c \
|
||||
ephoto_main.c \
|
||||
ephoto_red_eye.c \
|
||||
ephoto_thumb.c \
|
||||
ephoto_thumb_browser.c \
|
||||
ephoto_scale.c \
|
||||
ephoto_single_browser.c \
|
||||
ephoto_slideshow.c
|
||||
ephoto_slideshow.c \
|
||||
ephoto_thumb.c \
|
||||
ephoto_thumb_browser.c
|
||||
|
||||
internal_bindir = $(datadir)/$(PACKAGE)
|
||||
internal_bin_PROGRAMS = ephoto_thumbnail
|
||||
|
|
|
@ -142,6 +142,8 @@ void ephoto_color_add(Ephoto *ephoto, Evas_Object *main, Evas_Object *parent,
|
|||
Evas_Object *image);
|
||||
void ephoto_red_eye_add(Ephoto *ephoto, Evas_Object *main, Evas_Object *parent,
|
||||
Evas_Object *image);
|
||||
void ephoto_scale_add(Ephoto *ephoto, Evas_Object *main, Evas_Object *parent,
|
||||
Evas_Object *image);
|
||||
void ephoto_filter_blur(Evas_Object *main, Evas_Object *image);
|
||||
void ephoto_filter_sharpen(Evas_Object *main, Evas_Object *image);
|
||||
void ephoto_filter_dither(Evas_Object *main, Evas_Object *image);
|
||||
|
|
|
@ -1026,6 +1026,21 @@ _crop_image(void *data, Evas_Object *obj EINA_UNUSED,
|
|||
}
|
||||
}
|
||||
|
||||
static void
|
||||
_scale_image(void *data, Evas_Object *obj EINA_UNUSED,
|
||||
void *event_info EINA_UNUSED)
|
||||
{
|
||||
Ephoto_Single_Browser *sb = data;
|
||||
|
||||
if (sb->viewer)
|
||||
{
|
||||
sb->editing = EINA_TRUE;
|
||||
Ephoto_Viewer *v = evas_object_data_get(sb->viewer, "viewer");
|
||||
|
||||
ephoto_scale_add(sb->ephoto, sb->main, sb->mhbox, v->image);
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
_go_bcg(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
|
||||
{
|
||||
|
@ -1475,6 +1490,7 @@ _add_edit_menu_items(Ephoto_Single_Browser *sb, Evas_Object *menu)
|
|||
elm_menu_item_add(menu, menu_it, "document-properties", _("Transform"),
|
||||
NULL, NULL);
|
||||
elm_menu_item_add(menu, menu_itt, "edit-cut", _("Crop"), _crop_image, sb);
|
||||
elm_menu_item_add(menu, menu_itt, "zoom-in", _("Scale"), _scale_image, sb);
|
||||
elm_menu_item_separator_add(menu, menu_itt);
|
||||
elm_menu_item_add(menu, menu_itt, "object-rotate-left", _("Rotate Left"),
|
||||
_go_rotate_counterclock, sb);
|
||||
|
|
|
@ -258,6 +258,7 @@ e_thumb_client_data(Ecore_Ipc_Event_Client_Data *e)
|
|||
eth->busy = 0;
|
||||
_pending--;
|
||||
eth->done = 1;
|
||||
e_thumb_icon_end(obj);
|
||||
if (_pending == 0) _e_thumb_thumbnailers_kill();
|
||||
if (ecore_file_exists(icon))
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue