From bccb071aa6c325f402c2362f1bb1f772fff4ce0e Mon Sep 17 00:00:00 2001 From: Stephen Houston Date: Mon, 10 Oct 2016 14:18:14 -0500 Subject: [PATCH] Ephoto: Cancel drag on mouse up. --- src/bin/ephoto_single_browser.c | 1 - src/bin/ephoto_thumb_browser.c | 8 +++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/bin/ephoto_single_browser.c b/src/bin/ephoto_single_browser.c index 1f8b62e..6b7fc0b 100644 --- a/src/bin/ephoto_single_browser.c +++ b/src/bin/ephoto_single_browser.c @@ -2127,7 +2127,6 @@ ephoto_single_browser_entries_set(Evas_Object *obj, Eina_List *entries) char *dir; elm_image_file_get(v->image, &image, NULL); - printf("%s\n", image); dir = ecore_file_dir_get(image); if (strcmp(sb->ephoto->config->directory, dir)) ephoto_single_browser_entry_set(sb->main, diff --git a/src/bin/ephoto_thumb_browser.c b/src/bin/ephoto_thumb_browser.c index 978407a..4fc4986 100644 --- a/src/bin/ephoto_thumb_browser.c +++ b/src/bin/ephoto_thumb_browser.c @@ -861,6 +861,8 @@ _grid_mouse_up_cb(void *data, Evas *e EINA_UNUSED, evas_pointer_canvas_xy_get(evas_object_evas_get(tb->grid), &x, &y); item = elm_gengrid_at_xy_item_get(tb->grid, x, y, 0, 0); + elm_drag_cancel(tb->grid); + if (info->button == 1 && item) { if (ctrl) @@ -1173,7 +1175,7 @@ _ephoto_thumb_search_go(void *data, Evas_Object *obj EINA_UNUSED, if (tb->original_grid) { - elm_gengrid_clear(tb->grid); + ephoto_thumb_browser_clear(tb->ephoto); elm_box_unpack(tb->gridbox, tb->grid); evas_object_del(tb->grid); tb->grid = tb->original_grid; @@ -1307,7 +1309,7 @@ _ephoto_thumb_search_cancel(void *data, Evas_Object *obj EINA_UNUSED, tb->searchentries = NULL; if (tb->original_grid) { - elm_gengrid_clear(tb->grid); + ephoto_thumb_browser_clear(tb->ephoto); elm_box_unpack(tb->gridbox, tb->grid); evas_object_del(tb->grid); tb->grid = tb->original_grid; @@ -1533,7 +1535,7 @@ _ephoto_thumb_populate_start(void *data, int type EINA_UNUSED, if (tb->searching) _ephoto_thumb_search_cancel(tb->search, NULL, NULL); _todo_items_free(tb); - elm_gengrid_clear(tb->grid); + ephoto_thumb_browser_clear(ephoto); tb->totimages = 0; tb->totsize = 0;