summaryrefslogtreecommitdiff
path: root/src/lib/elm_entry.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/elm_entry.c')
-rw-r--r--src/lib/elm_entry.c15
1 files changed, 3 insertions, 12 deletions
diff --git a/src/lib/elm_entry.c b/src/lib/elm_entry.c
index 9ccb07596..1e6a97f1a 100644
--- a/src/lib/elm_entry.c
+++ b/src/lib/elm_entry.c
@@ -683,7 +683,6 @@ _drag_drop_cb(void *data EINA_UNUSED,
683 Elm_Selection_Data *drop) 683 Elm_Selection_Data *drop)
684{ 684{
685 Eina_Bool rv; 685 Eina_Bool rv;
686 char *buf;
687 686
688 ELM_ENTRY_DATA_GET(obj, sd); 687 ELM_ENTRY_DATA_GET(obj, sd);
689 688
@@ -694,20 +693,12 @@ _drag_drop_cb(void *data EINA_UNUSED,
694 693
695 if (!rv) WRN("Warning: Failed to position cursor: paste anyway"); 694 if (!rv) WRN("Warning: Failed to position cursor: paste anyway");
696 695
697 buf = malloc(drop->len + 1); 696 rv = _selection_data_cb(NULL, obj, drop);
698 if (!buf) 697
699 {
700 ERR("Failed to allocate memory for dropped text %p", obj);
701 return EINA_FALSE;
702 }
703 memcpy(buf, drop->data, drop->len);
704 buf[drop->len] = '\0';
705 elm_entry_entry_insert(obj, buf);
706 free(buf);
707 edje_object_part_text_cursor_copy 698 edje_object_part_text_cursor_copy
708 (sd->entry_edje, "elm.text", EDJE_CURSOR_USER, /*->*/ EDJE_CURSOR_MAIN); 699 (sd->entry_edje, "elm.text", EDJE_CURSOR_USER, /*->*/ EDJE_CURSOR_MAIN);
709 700
710 return EINA_TRUE; 701 return rv;
711} 702}
712 703
713static Elm_Sel_Format 704static Elm_Sel_Format