Re: filechooserdialog



On 27.07.2012 00:49, Dave M wrote:
my $dialog = Gtk3::FileChooserDialog->new(
     'Select a file', undef,
     'open',
     'gtk-cancel' => 'cancel',
     'gtk-ok'     => 'ok',
     );

This doesn't work because we are missing an override. The C function gtk_file_chooser_dialog_new takes a variable number of arguments, which gobject-introspection does not support at the moment. Hence your call to Gtk3::FileChooserDialog->new actually resolves to Gtk3::Dialog->new, which creates an empty dialog only. We'd need a custom Gtk3::FileChooserDialog::new implementation equivalent to the C version: <http://git.gnome.org/browse/gtk+/tree/gtk/gtkfilechooserdialog.c#n560> and our old XS override: <http://git.gnome.org/browse/perl-Gtk2/tree/xs/GtkFileChooserDialog.xs#n17>.



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