From: jstebbins Date: Sun, 14 Sep 2008 15:52:55 +0000 (+0000) Subject: LinGui: refine the drop zone for queue drag n drop. now it only highlights X-Git-Url: http://git.osdn.jp/view?a=commitdiff_plain;h=1e1e3591bf5e3642541ea7c985f82f24eeefdae7;hp=0e961f54fbaed86821d3adbf5327a06f997a6e36;p=handbrake-jp%2Fhandbrake-jp-git.git LinGui: refine the drop zone for queue drag n drop. now it only highlights the zone between rows. git-svn-id: svn://localhost/HandBrake/trunk@1695 b64f7644-9d1e-0410-96f1-a4d463321fa5 --- diff --git a/gtk/src/callbacks.c b/gtk/src/callbacks.c index 05a7cba7..6faa6bf5 100644 --- a/gtk/src/callbacks.c +++ b/gtk/src/callbacks.c @@ -2913,6 +2913,17 @@ queue_drag_motion_cb( gdk_drag_status(ctx, GDK_ACTION_MOVE, time); return TRUE; } + // Don't allow *drop into* + if (pos == GTK_TREE_VIEW_DROP_INTO_OR_BEFORE) + pos = GTK_TREE_VIEW_DROP_BEFORE; + if (pos == GTK_TREE_VIEW_DROP_INTO_OR_AFTER) + pos = GTK_TREE_VIEW_DROP_AFTER; + // Don't allow droping int child items + if (gtk_tree_path_get_depth(path) > 1) + { + gtk_tree_path_up(path); + pos = GTK_TREE_VIEW_DROP_AFTER; + } indices = gtk_tree_path_get_indices(path); row = indices[0]; js = ghb_array_get_nth(ud->queue, row);