Logo Search packages:      
Sourcecode: viridian version File versions  Download package

def AmpacheTools::AmpacheGUI::AmpacheGUI::button_open_downloads_file_chooser_clicked (   self,
  widget,
  data = None 
)
Open file chooser for the downloads directory.

Definition at line 2332 of file AmpacheGUI.py.

                                                                             :
            """Open file chooser for the downloads directory."""
            dialog = gtk.FileChooserDialog(_("Choose Folder..."),
                                    None,
                                    gtk.FILE_CHOOSER_ACTION_SELECT_FOLDER,
                                    (gtk.STOCK_CANCEL, gtk.RESPONSE_CANCEL,
                                    gtk.STOCK_OPEN, gtk.RESPONSE_OK))
            dialog.set_current_folder(os.path.expanduser("~"))
            dialog.set_default_response(gtk.RESPONSE_OK)
            response = dialog.run()
            if response == gtk.RESPONSE_OK:
                  self.downloads_directory = dialog.get_current_folder()
                  self.downloads_text_entry.set_text(self.downloads_directory)
                  self.db_session.variable_set('downloads_directory', self.downloads_directory)
            dialog.destroy()


Generated by  Doxygen 1.6.0   Back to index