mikeym
January 22nd, 2009, 06:08 PM
Hi,
I'm working on a Glade app at the moment (to add custom search buttons to firefox) and I'm struggling a bit with the file chooser dialogue. I can't seem to find anything which explains how to go about using it?
I've added a file chooser dialogue in Glade and put a couple of buttons on it (cancel and save) and it now looks like this:
http://ubuntuforums.org/attachment.php?attachmentid=100711&stc=1&d=1232643953
Now I can run it like this from perl:
$filechooser->set_do_overwrite_confirmation (TRUE);
$filechooser->set_current_folder ($dir);
$filechooser->set_current_name ("$name.xml");
my $xmlfile;
if($filechooser->run=='accept-filename') {
$xmlfile=$filechooser->get_filename;
}
$filechooser->destroy;
But it just displays dumbly and doesn't do anything. What do I have to do with my buttons to make it work?
Thanks again for all the help.
I'm working on a Glade app at the moment (to add custom search buttons to firefox) and I'm struggling a bit with the file chooser dialogue. I can't seem to find anything which explains how to go about using it?
I've added a file chooser dialogue in Glade and put a couple of buttons on it (cancel and save) and it now looks like this:
http://ubuntuforums.org/attachment.php?attachmentid=100711&stc=1&d=1232643953
Now I can run it like this from perl:
$filechooser->set_do_overwrite_confirmation (TRUE);
$filechooser->set_current_folder ($dir);
$filechooser->set_current_name ("$name.xml");
my $xmlfile;
if($filechooser->run=='accept-filename') {
$xmlfile=$filechooser->get_filename;
}
$filechooser->destroy;
But it just displays dumbly and doesn't do anything. What do I have to do with my buttons to make it work?
Thanks again for all the help.