diff options
author | Tristan Van Berkom <tristan.van.berkom@gmail.com> | 2010-12-17 15:25:15 +0900 |
---|---|---|
committer | Tristan Van Berkom <tristan.van.berkom@gmail.com> | 2010-12-17 15:25:15 +0900 |
commit | 71e7cd0ec407f489549ed045b7e9bfdff8c70c58 (patch) | |
tree | aab2e74e2a73dcd875eaf2c55509186ac362461c /gtk/gtkfilechooserdefault.c | |
parent | 735fa8b1976e3bbe045e5365d42f0d67007e5293 (diff) | |
parent | e9a77a153501dd5f1ecf1726f23afac0229eed61 (diff) | |
download | gtk+-71e7cd0ec407f489549ed045b7e9bfdff8c70c58.tar.gz |
Merge branch 'master' into treeview-refactor
Conflicts:
tests/testtreeedit.c
Diffstat (limited to 'gtk/gtkfilechooserdefault.c')
-rw-r--r-- | gtk/gtkfilechooserdefault.c | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/gtk/gtkfilechooserdefault.c b/gtk/gtkfilechooserdefault.c index a3de75b65d..ef98afef50 100644 --- a/gtk/gtkfilechooserdefault.c +++ b/gtk/gtkfilechooserdefault.c @@ -1124,7 +1124,7 @@ set_preview_widget (GtkFileChooserDefault *impl, static GdkPixbuf * render_search_icon (GtkFileChooserDefault *impl) { - return gtk_widget_render_icon (GTK_WIDGET (impl), GTK_STOCK_FIND, GTK_ICON_SIZE_MENU, NULL); + return gtk_widget_render_icon_pixbuf (GTK_WIDGET (impl), GTK_STOCK_FIND, GTK_ICON_SIZE_MENU); } static GdkPixbuf * @@ -1144,7 +1144,7 @@ render_recent_icon (GtkFileChooserDefault *impl) /* fallback */ if (!retval) - retval = gtk_widget_render_icon (GTK_WIDGET (impl), GTK_STOCK_FILE, GTK_ICON_SIZE_MENU, NULL); + retval = gtk_widget_render_icon_pixbuf (GTK_WIDGET (impl), GTK_STOCK_FILE, GTK_ICON_SIZE_MENU); return retval; } @@ -3075,11 +3075,11 @@ shortcuts_drag_motion_cb (GtkWidget *widget, } #endif - if (context->suggested_action == GDK_ACTION_COPY || - (context->actions & GDK_ACTION_COPY) != 0) + if (gdk_drag_context_get_suggested_action (context) == GDK_ACTION_COPY || + (gdk_drag_context_get_actions (context) & GDK_ACTION_COPY) != 0) action = GDK_ACTION_COPY; - else if (context->suggested_action == GDK_ACTION_MOVE || - (context->actions & GDK_ACTION_MOVE) != 0) + else if (gdk_drag_context_get_suggested_action (context) == GDK_ACTION_MOVE || + (gdk_drag_context_get_actions (context) & GDK_ACTION_MOVE) != 0) action = GDK_ACTION_MOVE; else { @@ -3228,6 +3228,7 @@ shortcuts_drag_data_received_cb (GtkWidget *widget, GtkFileChooserDefault *impl; GtkTreePath *tree_path; GtkTreeViewDropPosition tree_pos; + GdkAtom target; int position; int bookmarks_index; @@ -3247,9 +3248,11 @@ shortcuts_drag_data_received_cb (GtkWidget *widget, g_assert (position >= bookmarks_index); position -= bookmarks_index; - if (gtk_targets_include_uri (&selection_data->target, 1)) + target = gtk_selection_data_get_target (selection_data); + + if (gtk_targets_include_uri (&target, 1)) shortcuts_drop_uris (impl, selection_data, position); - else if (selection_data->target == gdk_atom_intern_static_string ("GTK_TREE_MODEL_ROW")) + else if (target == gdk_atom_intern_static_string ("GTK_TREE_MODEL_ROW")) shortcuts_reorder (impl, position); g_signal_stop_emission_by_name (widget, "drag-data-received"); |