]> git.0d.be Git - empathy.git/commitdiff
Handle MOVE and COPY drags better, change contact-id drags to COPY
authorShaun McCance <Shaun McCance>
Tue, 15 Sep 2009 20:57:51 +0000 (15:57 -0500)
committerShaun McCance <shaunm@gnome.org>
Tue, 24 Nov 2009 18:05:31 +0000 (12:05 -0600)
src/empathy-chat-window.c

index 90d4f8f6d771b30c6c200bd45d654a59eb427b3c..36f31b0b12e305c195415e646e5271d4c9effb06 100644 (file)
@@ -116,8 +116,7 @@ static const GtkTargetEntry drag_types_dest[] = {
        { "text/uri-list", 0, DND_DRAG_TYPE_URI_LIST },
 };
 
-static const GtkTargetEntry drag_types_dest_noft[] = {
-       { "text/contact-id", 0, DND_DRAG_TYPE_CONTACT_ID },
+static const GtkTargetEntry drag_types_dest_move[] = {
        { "GTK_NOTEBOOK_TAB", GTK_TARGET_SAME_APP, DND_DRAG_TYPE_TAB },
 };
 
@@ -1340,14 +1339,17 @@ chat_window_drag_motion (GtkWidget        *widget,
        GdkAtom target;
 
        if (list == NULL) {
-               list = gtk_target_list_new (drag_types_dest_noft,
-                                           G_N_ELEMENTS (drag_types_dest_noft));
+               list = gtk_target_list_new (drag_types_dest_move,
+                                           G_N_ELEMENTS (drag_types_dest_move));
        }
 
        target = gtk_drag_dest_find_target (widget, context, list);
        if (target == GDK_NONE) {
                gdk_drag_status (context, GDK_ACTION_COPY, time);
        }
+       else {
+               gdk_drag_status (context, GDK_ACTION_MOVE, time);
+       }
 }
 
 static void