// This file was generated by the Gtk# code generator.
// Any changes made will be lost if regenerated.

namespace Gtk {

	using System;
	using System.Runtime.InteropServices;

#region Autogenerated code
	public partial class Tree {

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate bool d_gtk_tree_get_row_drag_data(IntPtr selection_data, out IntPtr tree_model, out IntPtr path);
		static d_gtk_tree_get_row_drag_data gtk_tree_get_row_drag_data = FuncLoader.LoadFunction<d_gtk_tree_get_row_drag_data>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_tree_get_row_drag_data"));

		public static bool GetRowDragData(Gtk.SelectionData selection_data, out Gtk.ITreeModel tree_model, out Gtk.TreePath path) {
			IntPtr native_tree_model;
			IntPtr native_path;
			bool raw_ret = gtk_tree_get_row_drag_data(selection_data == null ? IntPtr.Zero : selection_data.Handle, out native_tree_model, out native_path);
			bool ret = raw_ret;
			tree_model = Gtk.TreeModelAdapter.GetObject (native_tree_model, false);
			path = native_path == IntPtr.Zero ? null : (Gtk.TreePath) GLib.Opaque.GetOpaque (native_path, typeof (Gtk.TreePath), true);
			return ret;
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate bool d_gtk_tree_set_row_drag_data(IntPtr selection_data, IntPtr tree_model, IntPtr path);
		static d_gtk_tree_set_row_drag_data gtk_tree_set_row_drag_data = FuncLoader.LoadFunction<d_gtk_tree_set_row_drag_data>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gtk), "gtk_tree_set_row_drag_data"));

		public static bool SetRowDragData(Gtk.SelectionData selection_data, Gtk.ITreeModel tree_model, Gtk.TreePath path) {
			bool raw_ret = gtk_tree_set_row_drag_data(selection_data == null ? IntPtr.Zero : selection_data.Handle, tree_model == null ? IntPtr.Zero : ((tree_model is GLib.Object) ? (tree_model as GLib.Object).Handle : (tree_model as Gtk.TreeModelAdapter).Handle), path == null ? IntPtr.Zero : path.Handle);
			bool ret = raw_ret;
			return ret;
		}

#endregion
	}
}
