def submit_torrent(self):
self._torrent_info.download_dir = self._download_dir
self._control.last_download_dir = os.path.abspath(self._download_dir)
file_paths = []
for node, item in self._file_items:
if item.checkState(0) == Qt.Checked:
file_paths.append(node.path)
if not self._torrent_info.download_info.single_file_mode:
self._torrent_info.download_info.select_files(file_paths, 'whitelist')
self._control_thread.loop.call_soon_threadsafe(self._control.add, self._torrent_info)
self.close()
评论列表
文章目录