From: <d4i...@us...> - 2013-01-31 19:30:48
|
Revision: 2948 http://oblivionworks.svn.sourceforge.net/oblivionworks/?rev=2948&view=rev Author: d4id4los Date: 2013-01-31 19:30:41 +0000 (Thu, 31 Jan 2013) Log Message: ----------- Fix for bug #240, delete cosaves to the recycling bin like save and mod files. Modified Paths: -------------- Programs/Wrye Bash/Mopy/bash/bosh.py Modified: Programs/Wrye Bash/Mopy/bash/bosh.py =================================================================== --- Programs/Wrye Bash/Mopy/bash/bosh.py 2013-01-31 10:56:52 UTC (rev 2947) +++ Programs/Wrye Bash/Mopy/bash/bosh.py 2013-01-31 19:30:41 UTC (rev 2948) @@ -2874,9 +2874,11 @@ self.savePath = savePath self.paths = CoSaves.getPaths(savePath) - def delete(self): + def delete(self,askOk=False,dontRecycle=False): """Deletes cofiles.""" - for path in self.paths: path.remove() + for path in self.paths: + if path.exists(): + balt.shellDelete(path,askOk=askOk,recycle=not dontRecycle) def recopy(self,savePath,saveName,pathFunc): """Renames/copies cofiles depending on supplied pathFunc.""" This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |