2022-03-18, 18:19
Hi there!
I am trying to get the infamous texturecache.py (by Millhouse https://forum.kodi.tv/showthread.php?tid=158373) incorporated into my addon, so that I can run it in Kodi for Windows. Previously I was running Kodi in LibreElec, so I had SSH access to run the py script.
This is in Python3 Kodi 19.
I was calling the textures.py in my Tools section:
self.addDirectoryItem("System : Click to Run Textures -c", 'tools_textures_c', 'tools.png', 'DefaultAddonProgram.png')
The command I use is to run textures.py is:
if action == 'tools_textures_c':
if not control.yesnoDialog('Are you sure you want to run Textures c?', '', ''): return
import xbmc
xbmc.executebuiltin('System.Exec(C:\Kodi\portable_data\texturecache.py c)')
control.notification(message='Textures c has completed!')
It works but since the script takes up to an hour to run sometimes, I would really like to have some sort of progress indicator, similar to the one that runs when you clean the movies Database.
Is that possible? If so, what code do I use?
Thanks!!
Ken
I am trying to get the infamous texturecache.py (by Millhouse https://forum.kodi.tv/showthread.php?tid=158373) incorporated into my addon, so that I can run it in Kodi for Windows. Previously I was running Kodi in LibreElec, so I had SSH access to run the py script.
This is in Python3 Kodi 19.
I was calling the textures.py in my Tools section:
self.addDirectoryItem("System : Click to Run Textures -c", 'tools_textures_c', 'tools.png', 'DefaultAddonProgram.png')
The command I use is to run textures.py is:
if action == 'tools_textures_c':
if not control.yesnoDialog('Are you sure you want to run Textures c?', '', ''): return
import xbmc
xbmc.executebuiltin('System.Exec(C:\Kodi\portable_data\texturecache.py c)')
control.notification(message='Textures c has completed!')
It works but since the script takes up to an hour to run sometimes, I would really like to have some sort of progress indicator, similar to the one that runs when you clean the movies Database.
Is that possible? If so, what code do I use?
Thanks!!
Ken