Re: custom model rows-reordered marshal



Torsten Schoenfeld <kaffeetisch gmx de> writes:

There might be some more in GtkCellRenderer.xs,

gtk_cell_renderer_get_size definitely, I think.

GtkWidget.xs,

and gtk_widget_get_size_request similarly.  style_get_property might be
ok if that's not implementable in perl, though making it like the plain
get_property could be a good thing.  gtk_container_child_get perhaps
likewise.

GtkTreeDnd.xs.

gtk_tree_drag_source_drag_data_get I guess (worsened a little by my
recent addition), and gtk_tree_get_row_drag_data.  Maybe the former
along lines like (untested):

Index: GtkTreeDnd.xs
===================================================================
RCS file: /cvsroot/gtk2-perl/gtk2-perl-xs/Gtk2/xs/GtkTreeDnd.xs,v
retrieving revision 1.11
diff -u -u -r1.11 GtkTreeDnd.xs
--- GtkTreeDnd.xs       6 Sep 2008 18:22:05 -0000       1.11
+++ GtkTreeDnd.xs       19 Sep 2008 01:58:54 -0000
@@ -148,7 +148,7 @@
 gtk_tree_drag_source_drag_data_get (GtkTreeDragSource *drag_source, GtkTreePath *path, GtkSelectionData 
*selection_data = NULL)
     PREINIT:
        SV *ret = &PL_sv_undef;
-    PPCODE:
+    CODE:
        if (selection_data) {
                if (gtk_tree_drag_source_drag_data_get (drag_source, path,
                                                        selection_data))
@@ -162,7 +162,8 @@
                                                        &new_selection_data))
                        ret = sv_2mortal (newSVGtkSelectionData_copy (&new_selection_data));
        }
-       PUSHs (ret);
+       ST(0) = ret;
+       XSRETURN(1);
 
 MODULE = Gtk2::TreeDnd PACKAGE = Gtk2::TreeDragDest    PREFIX = gtk_tree_drag_dest_
 
@@ -206,6 +207,8 @@
 
 ## gboolean gtk_tree_get_row_drag_data (GtkSelectionData *selection_data, GtkTreeModel **tree_model, 
GtkTreePath **path)
 =for apidoc
+If $selection_data is not type GTK_TREE_MODEL_ROW then the return is
+an empty list.
 =for signature (tree_model, path) = $selection_data->get_row_drag_data
 =cut
 void


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]