Re: fileselection


"G.Camozzi" <shebby linuxwaves com> writes:

> sorry but i'm a newbie with GTK, and i have problem with fileselection.
> i have a fileselection window and i put in my callbacks.c this line
> void
> on_ok_button1_clicked                  (GtkButton       *button,
> gpointer         user_data)
> {
> g_print("%s",gtk_file_selection_get_filename(
> GTK_FILE_SELECTION(user_data) ));
> }
> On my output i have this error:
> Gtk-WARNING **: invalid cast from (NULL) pointer to `GtkFileSelection'

did you pass the file_selection as user_data when connecting to the 
"clicked" signal, e.g.:

  gtk_signal_connect (GTK_OBJECT (button), "clicked", 
                      GTK_SIGNAL_FUNC (on_ok_button1_clicked),

Salut, Sven


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