Re: Little inconsistency



Piotr Waśkiewicz <piter storm pl> writes:

> Take a look at file gtkliststore.c:
> /**
>   * gtk_list_store_insert:
>   * @list_store: A #GtkListStore
>   * @iter: An unset #GtkTreeIter to set to the new row
>   * @position: position to insert the new row
>   *
>   * Creates a new row at @position.  @iter will be changed to point to
> this new
>   * row.  If @position is larger than the number of rows on the list,
> then the
>   * new row will be appended to the list.  The row will be empty before
>     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> But later in this function:
> 
> list = g_slist_nth (G_SLIST (list_store->root), position - 1);
> 
>    if (list == NULL)
>      {
>        g_warning ("%s: position %d is off the end of the list\n",
> G_STRLOC, position);
>        return;
>      }
> 
> This is bug, or feature? ;)

It's in bugzilla as http://bugzilla.gnome.org/show_bug.cgi?id=85813; 
the tree view folks will have to decide whether the docs or the 
implementation is in error.

Regards,
                                        Owen




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