diff options
author | Kristian Rietveld <kris@gtk.org> | 2003-12-19 22:47:20 +0000 |
---|---|---|
committer | Kristian Rietveld <kristian@src.gnome.org> | 2003-12-19 22:47:20 +0000 |
commit | 2f4326e40633536ffea31e266f1985ca0fb805f3 (patch) | |
tree | 5ae741b553cfad54a1969207659eb381693794cb /gtk/gtkcelllayout.c | |
parent | 30d9f88996c6cf5148837063ea45cef3f17c96da (diff) | |
download | gtk+-2f4326e40633536ffea31e266f1985ca0fb805f3.tar.gz |
Fixes #108458.
Fri Dec 19 23:36:00 2003 Kristian Rietveld <kris@gtk.org>
Fixes #108458.
* gtk/gtkcelllayout.[ch]: added a reorder method.
* gtk/gtktreeviewcolumn.c (gtk_tree_view_column_cell_layout_init),
(gtk_tree_view_column_cell_layout_reorder): implement reorder.
* gtk/gtkcellview.c (gtk_cell_view_cell_layout_init),
(gtk_cell_view_cell_layout_reorder): ditto.
* gtk/gtkcombobox.c (gtk_combo_box_cell_layout_init),
(gtk_combo_box_cell_layout_reorder): ditto.
* gtk/gtkentrycompletion.c (gtk_entry_completion_cell_layout_init),
(gtk_entry_completion_reorder): ditto.
Diffstat (limited to 'gtk/gtkcelllayout.c')
-rw-r--r-- | gtk/gtkcelllayout.c | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/gtk/gtkcelllayout.c b/gtk/gtkcelllayout.c index 29ccc89362..6dff244122 100644 --- a/gtk/gtkcelllayout.c +++ b/gtk/gtkcelllayout.c @@ -250,3 +250,27 @@ gtk_cell_layout_clear_attributes (GtkCellLayout *cell_layout, (* GTK_CELL_LAYOUT_GET_IFACE (cell_layout)->clear_attributes) (cell_layout, cell); } + +/** + * gtk_cell_layout_reorder: + * @cell_layout: A #GtkCellLayout. + * @cell: A #GtkCellRenderer to reorder. + * @position: New position to insert @cell at. + * + * Re-inserts @cell at @position. Note that @cell has already to be packed + * into @cell_layout for this to function properly. + * + * Since: 2.4 + */ +void +gtk_cell_layout_reorder (GtkCellLayout *cell_layout, + GtkCellRenderer *cell, + gint position) +{ + g_return_if_fail (GTK_IS_CELL_LAYOUT (cell_layout)); + g_return_if_fail (GTK_IS_CELL_RENDERER (cell)); + + (* GTK_CELL_LAYOUT_GET_IFACE (cell_layout)->reorder) (cell_layout, + cell, + position); +} |