gtk_selection_get_selected()
- From: Jens Hornung <dncn gmx net>
- To: gtk-app-devel-list gnome org <gtk-app-devel-list gnome org>
- Subject: gtk_selection_get_selected()
- Date: Tue, 8 Apr 2003 16:30:36 +0200
Hi,
i've got some problems with the function 'gtk_selection_get_selected'. Here's a part of the code:
...
GtkListStore *list;
GtkTreeView *view;
GtkTreeSelection *selection;
GtkTreeIter iter;
GValue *value;
...
selection = gtk_tree_view_get_selection(view);
gtk_tree_selection_set_mode(selection, GTK_SELECTION_SINGLE);
if((gtk_tree_selection_get_selected(GTK_TREE_SELECTION(selection),
GTK_TREE_MODEL(&list),
&iter))
== TRUE)
{
gtk_tree_model_get_value(GTK_TREE_MODEL(list),
&iter,
1,
value);
g_printf("%s\n", (gchar *)value);
g_value_unset(value);
}
...
gcc always stops with the message:
ad.c: In function `main':
ad.c:360: warning: passing arg 2 of `gtk_tree_selection_get_selected' from incompatible pointer type
Can someone give me a hint, how to do that right.
regards,
Jens.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]