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

def rapid::rapid::SelectionTreeView::refreshSampleDownloadFolders (   self,
  thread_id = None 
)

Refreshes the download folder of every file that has not yet been downloaded

This is useful when the user updates the preferences, and the scan has already occurred (or is occurring)

If thread_id is specified, will only update rows with that thread

Definition at line 3872 of file rapid.py.

03872                                                             :
        """
        Refreshes the download folder of every file that has not yet been downloaded
        
        This is useful when the user updates the preferences, and the scan has already occurred (or is occurring)
        
        If thread_id is specified, will only update rows with that thread
        """
        for iter in self.get_tree_row_iters():
            status = self.get_status(iter)
            if status in [STATUS_NOT_DOWNLOADED, STATUS_WARNING, STATUS_CANNOT_DOWNLOAD]:
                regenerate = True
                if thread_id is not None:
                    t = self.get_thread(iter)
                    regenerate = t == thread_id
                
                if regenerate:
                    mediaFile = self.get_mediaFile(iter)
                    if mediaFile.isImage:
                        mediaFile.downloadFolder = self.rapidApp.prefs.download_folder
                    else:
                        mediaFile.downloadFolder = self.rapidApp.prefs.video_download_folder
                    mediaFile.samplePath = os.path.join(mediaFile.downloadFolder, mediaFile.sampleSubfolder)
                    if mediaFile.treerowref == self.previewed_file_treerowref:
                        self.show_preview(iter)                

    def _refreshNameFactories(self):


Generated by  Doxygen 1.6.0   Back to index