ускорил получение списка файлов
parent
1031f71364
commit
fc0e69ab63
|
@ -157,14 +157,15 @@ class AnteoLoader:
|
||||||
files = []
|
files = []
|
||||||
filelist = []
|
filelist = []
|
||||||
with closing(self.engine):
|
with closing(self.engine):
|
||||||
self.engine.start()
|
#self.engine.start()
|
||||||
#media_types=[MediaType.VIDEO, MediaType.AUDIO, MediaType.SUBTITLES, MediaType.UNKNOWN]
|
#media_types=[MediaType.VIDEO, MediaType.AUDIO, MediaType.SUBTITLES, MediaType.UNKNOWN]
|
||||||
|
|
||||||
iterator = 0
|
iterator = 0
|
||||||
text = Localization.localize('Magnet-link is converting') if self.magnetLink\
|
text = Localization.localize('Magnet-link is converting') if self.magnetLink\
|
||||||
else Localization.localize('Opening torrent file')
|
else Localization.localize('Opening torrent file')
|
||||||
while not files and not xbmc.abortRequested and iterator < 100:
|
while not files and not xbmc.abortRequested and iterator < 100:
|
||||||
files = self.engine.list()
|
#files = self.engine.list()
|
||||||
|
files = self.engine.list_from_info()
|
||||||
#self.engine.check_torrent_error()
|
#self.engine.check_torrent_error()
|
||||||
if len(files) == 0: break
|
if len(files) == 0: break
|
||||||
if iterator==4:
|
if iterator==4:
|
||||||
|
|
Loading…
Reference in New Issue