Logo Search packages:      
Sourcecode: rapid-photo-downloader version File versions  Download package

def rapid::rapid::SelectionTreeView::update_download_selected_button (   self  ) 

Updates the text on the Download Selection button, and set its sensitivity

Definition at line 3807 of file rapid.py.

03807                                              :
        """
        Updates the text on the Download Selection button, and set its sensitivity
        """
        no_available_for_download = 0
        selection = self.get_selection()
        model, paths = selection.get_selected_rows()
        if paths:            
            path = paths[0]
            iter = self.liststore.get_iter(path)
            
            #update button text
            no_available_for_download, threads = self.no_selected_rows_available_for_download()
            
        if no_available_for_download and workers.scanComplete(threads):
            self.rapidApp.download_selected_button.set_label(self.rapidApp.DOWNLOAD_SELECTED_LABEL + " (%s)" % no_available_for_download)
            self.rapidApp.download_selected_button.set_sensitive(True)
        else:
            #nothing was selected, or nothing is available from what the user selected, or should not download right now
            self.rapidApp.download_selected_button.set_label(self.rapidApp.DOWNLOAD_SELECTED_LABEL)
            self.rapidApp.download_selected_button.set_sensitive(False)
    
    def on_selection_changed(self, selection):


Generated by  Doxygen 1.6.0   Back to index