コード例 #1
0
ファイル: persistence.py プロジェクト: fraca7/dsremap
 def pathFor(self, filename):
     dst = Meta.newThumbnail(filename)
     self._zipobj.extract(filename, os.path.dirname(dst))
     os.rename(os.path.join(os.path.dirname(dst), filename), dst)
     return dst
コード例 #2
0
ファイル: configuration.py プロジェクト: fraca7/dsremap
 def dropEvent(self, event):
     src = event.mimeData().urls()[0].toLocalFile()
     dst = Meta.newThumbnail(src)
     shutil.copyfile(src, dst)
     cmd = commands.ChangeConfigurationThumbnailCommand(configuration=self.configuration(), filename=dst)
     self.history().run(cmd)