pull/17/head
DiMartinoXBMC 2018-08-08 12:53:21 +03:00
parent 30ddf28618
commit 131d437504
3 changed files with 28 additions and 152 deletions

View File

@ -1032,7 +1032,6 @@
</component> </component>
<component name="ProjectFrameBounds"> <component name="ProjectFrameBounds">
<option name="x" value="-8" /> <option name="x" value="-8" />
<option name="y" value="-8" />
<option name="width" value="1936" /> <option name="width" value="1936" />
<option name="height" value="1056" /> <option name="height" value="1056" />
</component> </component>
@ -1089,55 +1088,7 @@
<recent name="C:\Users\Admin\AppData\Roaming\Kodi\addons\plugin.video.torrenter\resources\searchers\unused" /> <recent name="C:\Users\Admin\AppData\Roaming\Kodi\addons\plugin.video.torrenter\resources\searchers\unused" />
</key> </key>
</component> </component>
<component name="RunManager" selected="Python.cal"> <component name="RunManager">
<configuration default="false" name="cal" type="PythonConfigurationType" factoryName="Python" temporary="true">
<option name="INTERPRETER_OPTIONS" value="" />
<option name="PARENT_ENVS" value="true" />
<envs>
<env name="PYTHONUNBUFFERED" value="1" />
</envs>
<option name="SDK_HOME" value="" />
<option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
<option name="IS_MODULE_SDK" value="true" />
<option name="ADD_CONTENT_ROOTS" value="true" />
<option name="ADD_SOURCE_ROOTS" value="true" />
<module name="plugin.video.torrenter" />
<option name="SCRIPT_NAME" value="$PROJECT_DIR$/cal.py" />
<option name="PARAMETERS" value="" />
<option name="SHOW_COMMAND_LINE" value="false" />
<RunnerSettings RunnerId="PythonRunner" />
<ConfigurationWrapper RunnerId="PythonRunner" />
<method />
</configuration>
<configuration default="true" type="PythonConfigurationType" factoryName="Python">
<option name="INTERPRETER_OPTIONS" value="" />
<option name="PARENT_ENVS" value="true" />
<envs>
<env name="PYTHONUNBUFFERED" value="1" />
</envs>
<option name="SDK_HOME" value="" />
<option name="WORKING_DIRECTORY" value="" />
<option name="IS_MODULE_SDK" value="false" />
<option name="ADD_CONTENT_ROOTS" value="true" />
<option name="ADD_SOURCE_ROOTS" value="true" />
<module name="plugin.video.torrenter" />
<option name="SCRIPT_NAME" value="" />
<option name="PARAMETERS" value="" />
<option name="SHOW_COMMAND_LINE" value="false" />
<method />
</configuration>
<configuration default="true" type="Tox" factoryName="Tox">
<option name="INTERPRETER_OPTIONS" value="" />
<option name="PARENT_ENVS" value="true" />
<envs />
<option name="SDK_HOME" value="" />
<option name="WORKING_DIRECTORY" value="" />
<option name="IS_MODULE_SDK" value="false" />
<option name="ADD_CONTENT_ROOTS" value="true" />
<option name="ADD_SOURCE_ROOTS" value="true" />
<module name="plugin.video.torrenter" />
<method />
</configuration>
<configuration default="true" type="tests" factoryName="Attests"> <configuration default="true" type="tests" factoryName="Attests">
<option name="INTERPRETER_OPTIONS" value="" /> <option name="INTERPRETER_OPTIONS" value="" />
<option name="PARENT_ENVS" value="true" /> <option name="PARENT_ENVS" value="true" />
@ -1157,104 +1108,35 @@
<option name="USE_PATTERN" value="false" /> <option name="USE_PATTERN" value="false" />
<method /> <method />
</configuration> </configuration>
<configuration default="true" type="tests" factoryName="Doctests"> <configuration name="cal" type="PythonConfigurationType" factoryName="Python" temporary="true">
<module name="plugin.video.torrenter" />
<option name="INTERPRETER_OPTIONS" value="" /> <option name="INTERPRETER_OPTIONS" value="" />
<option name="PARENT_ENVS" value="true" /> <option name="PARENT_ENVS" value="true" />
<envs /> <envs>
<env name="PYTHONUNBUFFERED" value="1" />
</envs>
<option name="SDK_HOME" value="" /> <option name="SDK_HOME" value="" />
<option name="WORKING_DIRECTORY" value="" /> <option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
<option name="IS_MODULE_SDK" value="false" /> <option name="IS_MODULE_SDK" value="true" />
<option name="ADD_CONTENT_ROOTS" value="true" /> <option name="ADD_CONTENT_ROOTS" value="true" />
<option name="ADD_SOURCE_ROOTS" value="true" /> <option name="ADD_SOURCE_ROOTS" value="true" />
<module name="plugin.video.torrenter" /> <option name="SCRIPT_NAME" value="$PROJECT_DIR$/cal.py" />
<option name="SCRIPT_NAME" value="" /> <option name="PARAMETERS" value="" />
<option name="CLASS_NAME" value="" /> <option name="SHOW_COMMAND_LINE" value="false" />
<option name="METHOD_NAME" value="" /> <option name="EMULATE_TERMINAL" value="false" />
<option name="FOLDER_NAME" value="" /> <option name="MODULE_MODE" value="false" />
<option name="TEST_TYPE" value="TEST_SCRIPT" /> <option name="REDIRECT_INPUT" value="false" />
<option name="PATTERN" value="" /> <option name="INPUT_FILE" value="" />
<option name="USE_PATTERN" value="false" /> <RunnerSettings RunnerId="PythonRunner" />
<method /> <ConfigurationWrapper RunnerId="PythonRunner" />
<method v="2" />
</configuration> </configuration>
<configuration default="true" type="tests" factoryName="Nosetests">
<option name="INTERPRETER_OPTIONS" value="" />
<option name="PARENT_ENVS" value="true" />
<envs />
<option name="SDK_HOME" value="" />
<option name="WORKING_DIRECTORY" value="" />
<option name="IS_MODULE_SDK" value="false" />
<option name="ADD_CONTENT_ROOTS" value="true" />
<option name="ADD_SOURCE_ROOTS" value="true" />
<module name="plugin.video.torrenter" />
<option name="SCRIPT_NAME" value="" />
<option name="CLASS_NAME" value="" />
<option name="METHOD_NAME" value="" />
<option name="FOLDER_NAME" value="" />
<option name="TEST_TYPE" value="TEST_SCRIPT" />
<option name="PATTERN" value="" />
<option name="USE_PATTERN" value="false" />
<option name="PARAMS" value="" />
<option name="USE_PARAM" value="false" />
<method />
</configuration>
<configuration default="true" type="tests" factoryName="Unittests">
<option name="INTERPRETER_OPTIONS" value="" />
<option name="PARENT_ENVS" value="true" />
<envs />
<option name="SDK_HOME" value="" />
<option name="WORKING_DIRECTORY" value="" />
<option name="IS_MODULE_SDK" value="false" />
<option name="ADD_CONTENT_ROOTS" value="true" />
<option name="ADD_SOURCE_ROOTS" value="true" />
<module name="plugin.video.torrenter" />
<option name="SCRIPT_NAME" value="" />
<option name="CLASS_NAME" value="" />
<option name="METHOD_NAME" value="" />
<option name="FOLDER_NAME" value="" />
<option name="TEST_TYPE" value="TEST_SCRIPT" />
<option name="PATTERN" value="" />
<option name="USE_PATTERN" value="false" />
<option name="PUREUNITTEST" value="true" />
<option name="PARAMS" value="" />
<option name="USE_PARAM" value="false" />
<method />
</configuration>
<configuration default="true" type="tests" factoryName="py.test">
<option name="INTERPRETER_OPTIONS" value="" />
<option name="PARENT_ENVS" value="true" />
<envs />
<option name="SDK_HOME" value="" />
<option name="WORKING_DIRECTORY" value="" />
<option name="IS_MODULE_SDK" value="false" />
<option name="ADD_CONTENT_ROOTS" value="true" />
<option name="ADD_SOURCE_ROOTS" value="true" />
<module name="plugin.video.torrenter" />
<option name="SCRIPT_NAME" value="" />
<option name="CLASS_NAME" value="" />
<option name="METHOD_NAME" value="" />
<option name="FOLDER_NAME" value="" />
<option name="TEST_TYPE" value="TEST_SCRIPT" />
<option name="PATTERN" value="" />
<option name="USE_PATTERN" value="false" />
<option name="testToRun" value="" />
<option name="keywords" value="" />
<option name="params" value="" />
<option name="USE_PARAM" value="false" />
<option name="USE_KEYWORD" value="false" />
<method />
</configuration>
<list size="1">
<item index="0" class="java.lang.String" itemvalue="Python.cal" />
</list>
<recent_temporary> <recent_temporary>
<list size="1"> <list>
<item index="0" class="java.lang.String" itemvalue="Python.cal" /> <item itemvalue="Python.cal" />
</list> </list>
</recent_temporary> </recent_temporary>
</component> </component>
<component name="ShelveChangesManager" show_recycled="false">
<option name="remove_strategy" value="false" />
</component>
<component name="SvnConfiguration"> <component name="SvnConfiguration">
<configuration /> <configuration />
</component> </component>

View File

@ -556,11 +556,9 @@ class Core:
if action2 == 'open': if action2 == 'open':
filename, foldername, path, url, seek, length, ind = db.get('filename, foldername, path, url, seek, length, ind', 'addtime', str(addtime)) filename, foldername, path, url, seek, length, ind = db.get('filename, foldername, path, url, seek, length, ind', 'addtime', str(addtime))
if os.path.exists(path) and os.path.getsize(path) > 0: if os.path.exists(path):
self.__settings__.setSetting("lastTorrent", path) self.__settings__.setSetting("lastTorrent", path)
else: else:
if os.path.exists(path):
os.unlink(path)
torrent = Downloader.Torrent(self.userStorageDirectory, torrentFilesDirectory=self.torrentFilesDirectory) torrent = Downloader.Torrent(self.userStorageDirectory, torrentFilesDirectory=self.torrentFilesDirectory)
path = torrent.saveTorrent(url) path = torrent.saveTorrent(url)
self.__settings__.setSetting("lastTorrent", path) self.__settings__.setSetting("lastTorrent", path)
@ -576,11 +574,9 @@ class Core:
seek = int(seek) seek = int(seek)
else: else:
seek = 0 seek = 0
if os.path.exists(path) and os.path.getsize(path) > 0: if os.path.exists(path):
self.__settings__.setSetting("lastTorrent", path) self.__settings__.setSetting("lastTorrent", path)
else: else:
if os.path.exists(path):
os.unlink(path)
torrent = Downloader.Torrent(self.userStorageDirectory, torrentFilesDirectory=self.torrentFilesDirectory) torrent = Downloader.Torrent(self.userStorageDirectory, torrentFilesDirectory=self.torrentFilesDirectory)
self.__settings__.setSetting("lastTorrent", torrent.saveTorrent(url)) self.__settings__.setSetting("lastTorrent", torrent.saveTorrent(url))
xbmc.executebuiltin('xbmc.RunPlugin("plugin://plugin.video.torrenter/?action=playTorrent&url='+str(ind)+'&seek='+str(seek)+'")') xbmc.executebuiltin('xbmc.RunPlugin("plugin://plugin.video.torrenter/?action=playTorrent&url='+str(ind)+'&seek='+str(seek)+'")')

View File

@ -17,7 +17,7 @@
<string id="30017">Transperency (de slng)</string> <string id="30017">Transperency (de slng)</string>
<string id="30018">Confluence (de DiMartino)</string> <string id="30018">Confluence (de DiMartino)</string>
<string id="30019">Confluence (de RussakHH)</string> <string id="30019">Confluence (de RussakHH)</string>
<string id="30020">Habilitar historial de búsquedas</string> <string id="30020">Habilitar el historial de búsquedas</string>
<string id="30021">python-libtorrent</string> <string id="30021">python-libtorrent</string>
<string id="30022">Ace Stream</string> <string id="30022">Ace Stream</string>
<string id="30023">Reproductor P2P</string> <string id="30023">Reproductor P2P</string>
@ -44,11 +44,9 @@
<string id="30044">Guardar archivos</string> <string id="30044">Guardar archivos</string>
<string id="30045">Preguntar para guardar</string> <string id="30045">Preguntar para guardar</string>
<string id="30046">Torrent2HTTP (libtorrent vía HTTP)</string> <string id="30046">Torrent2HTTP (libtorrent vía HTTP)</string>
<string id="30047">Proxy para búsquedas</string> <string id="30047">Proxy</string>
<string id="31047">Proxy para listas de contenido</string>
<string id="32047">Dirección IP de proxy SOCKS</string>
<string id="30048">Ninguno</string> <string id="30048">Ninguno</string>
<string id="30049">Anti-zapret (antirrestricción)</string> <string id="30049">Anti-zapret (antirestricción)</string>
<string id="31050">Tor</string> <string id="31050">Tor</string>
<string id="30050">Inmunidad</string> <string id="30050">Inmunidad</string>
<string id="30051">Núm. máx. de conexiones (0 = ilimitadas)</string> <string id="30051">Núm. máx. de conexiones (0 = ilimitadas)</string>
@ -60,12 +58,12 @@
<string id="30057">Promedio/Buen PC</string> <string id="30057">Promedio/Buen PC</string>
<string id="30058">Por debajo de la media, PC/router</string> <string id="30058">Por debajo de la media, PC/router</string>
<string id="30059">Tamaño mínimo de almacenaje para autoborrado (GB)</string> <string id="30059">Tamaño mínimo de almacenaje para autoborrado (GB)</string>
<string id="30060">Diferir inicio de reproductor</string> <string id="30060">Diferir inicio del reproductor</string>
<string id="30061">Ordenar resultados de la búsqueda</string> <string id="30061">Ordenar resultados de la búsqueda</string>
<string id="30062">Por fuentes</string> <string id="30062">Por fuentes</string>
<string id="30063">No ordenar</string> <string id="30063">No ordenar</string>
<string id="30064">Por nombre</string> <string id="30064">Por nombre</string>
<string id="30065">Añadir a historial de vistos después del (%)</string> <string id="30065">Añadir al historial de vistos después del (%)</string>
<string id="30066">Confluence (de safonov_ivan)</string> <string id="30066">Confluence (de safonov_ivan)</string>
<string id="30067">Aeon Nox (de joyrider)</string> <string id="30067">Aeon Nox (de joyrider)</string>
<string id="30068">pyrrent2http (python-libtorrent vía HTTP)</string> <string id="30068">pyrrent2http (python-libtorrent vía HTTP)</string>
@ -101,7 +99,7 @@
<string id="50316">Contraseña</string> <string id="50316">Contraseña</string>
<string id="50311">Cliente de BitTorrent</string> <string id="50311">Cliente de BitTorrent</string>
<string id="50317">URL (no SSL)</string> <string id="50317">URL (no SSL)</string>
<string id="30426">Sustitución de ruta (solo remoto)</string> <string id="30426">Sustitución de ruta (Solo remoto)</string>
<string id="30412">Cerrar</string> <string id="30412">Cerrar</string>
<string id="30413">Abrir "Ajustes"</string> <string id="30413">Abrir "Ajustes"</string>
<string id="30414">Navegador de cliente BitTorrent</string> <string id="30414">Navegador de cliente BitTorrent</string>