Ticket #89: download-folder.patch

File download-folder.patch, 1.3 kB (added by imslushie@…, 11 months ago)

Browse->Download Dir patch

  • MucousPopup.py

    old new  
    527527                                number = self.mucous.BrowseShares.scrolling[mode]-self.mucous.BrowseShares.dimensions["directories"]["start"] 
    528528                                if self.position == 0: 
    529529                                        # Download 
    530                                         self.mucous.Transfers.FolderDownload(user, path) 
     530 
     531          # CHANGED 12/17/2007 Josh Leder 
     532          # Transfers.FolderDownload strips the end of the path for some reason 
     533          # so I am adding a trailing path delimiter (which will be discarded) 
     534          # to prevent going an extra level up in the folder hierarchy 
     535          # I'm also changing CurrentFile() to CurrentDir() which seems to make 
     536          # a lot more sense. :) 
     537                                        user, path = self.mucous.BrowseShares.CurrentDir() 
     538                                        self.mucous.Transfers.FolderDownload(user, path + "\\") 
    531539                                        return 0 
    532540                                elif self.position == 1: 
    533541                                        user, path = self.mucous.BrowseShares.CurrentDir() 
     
    545553                                        return 0 
    546554                                elif self.position == 1: 
    547555                                        # Download Dir 
    548                                         self.mucous.Transfers.FolderDownload(user, path) 
     556                                        #self.mucous.Transfers.FolderDownload(user, path) 
     557                                        user, path = self.mucous.BrowseShares.CurrentDir() 
     558                                        self.mucous.Transfers.FolderDownload(user, path + "\\") 
    549559                                        return 0 
    550560                         
    551561                                elif self.position == 2: