From 34c69d3922fec8be57b2cd5aaededfc2a0828f23 Mon Sep 17 00:00:00 2001 From: Manolo Gouy Date: Fri, 13 Dec 2013 16:28:38 +0000 Subject: Fix for STR#3016: Fl_Input and Fl_Text_Editor have now the standard behavior when doing drag-n-drop of text: if the dragged text is dropped in the widget it comes from, it's cut and pasted. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10031 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- src/Fl_Text_Editor.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/Fl_Text_Editor.cxx') diff --git a/src/Fl_Text_Editor.cxx b/src/Fl_Text_Editor.cxx index 03e4b22bd..2854bfa88 100644 --- a/src/Fl_Text_Editor.cxx +++ b/src/Fl_Text_Editor.cxx @@ -646,7 +646,7 @@ int Fl_Text_Editor::handle(int event) { insert_position(dndCursorPos); return 1; case FL_DND_RELEASE: // keep insertion cursor and wait for the FL_PASTE event - buffer()->unselect(); // FL_PASTE must not destroy current selection! + if (!dragging) buffer()->unselect(); // FL_PASTE must not destroy current selection if drag comes from outside return 1; } -- cgit v1.2.3