diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2011-11-02 14:43:07 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-11-02 14:43:07 -0700 |
commit | 81f013f3f131e5f96d36d3524f7e8d13d0147209 (patch) | |
tree | 2cf8ad4375d3444ab917ffe742778eccbf2597c3 | |
parent | 3c69c9b935ea43402bafd2918e2e71e561b4484d (diff) | |
parent | f89aec94e268dad1305789bbc9d17864f19c833b (diff) | |
download | subsurface-81f013f3f131e5f96d36d3524f7e8d13d0147209.tar.gz |
Merge branch 'drag-n-drop-fix' of git://github.com/dirkhh/subsurface
* 'drag-n-drop-fix' of git://github.com/dirkhh/subsurface:
Fix drag and drop error
-rw-r--r-- | gtk-gui.c | 12 |
1 files changed, 6 insertions, 6 deletions
@@ -694,23 +694,21 @@ static GtkNotebook *create_new_notebook_window(GtkNotebook *source, return GTK_NOTEBOOK(notebook); } -static void drag_cb(GtkWidget *widget, GdkDragContext *context, +static gboolean drag_cb(GtkWidget *widget, GdkDragContext *context, gint x, gint y, guint time, gpointer user_data) { GtkWidget *source; notebook_data_t *nbdp; + gtk_drag_finish(context, TRUE, TRUE, time); source = gtk_drag_get_source_widget(context); if (nbd[0].name && ! strcmp(nbd[0].name,gtk_widget_get_name(source))) nbdp = nbd; else if (nbd[1].name && ! strcmp(nbd[1].name,gtk_widget_get_name(source))) nbdp = nbd + 1; - else - /* HU? */ - return; - - gtk_drag_finish(context, TRUE, TRUE, time); + else /* just on ourselves */ + return TRUE; /* we no longer need the widget - but getting rid of this is hard; * remove the signal handler, remove the notebook from the box @@ -722,6 +720,8 @@ static void drag_cb(GtkWidget *widget, GdkDragContext *context, nbdp->widget = NULL; free(nbdp->name); nbdp->name = NULL; + + return TRUE; } #ifdef WIN32 |