Prova viste

This commit is contained in:
marco
2021-12-28 19:37:01 +01:00
parent 9cc3ab7f52
commit edecfb8df4

View File

@@ -432,7 +432,9 @@ def viewmodeMonitor():
parent_info = xbmc.getInfoLabel('Container.FolderPath')
parent = Item().fromurl(parent_info)
if 'plugin.video.kod' in parent_info:
item = Item().fromurl(xbmc.getInfoLabel('Container.ListItemPosition(2).FileNameAndPath'))
first_item_url = xbmc.getInfoLabel('Container.ListItemAbsolute(1).FileNameAndPath')
if first_item_url:
item = Item().fromurl(first_item_url)
currentModeName = xbmc.getInfoLabel('Container.Viewmode')
currentMode = int(xbmcgui.Window(10025).getFocusId())
# logger.debug('SAVE VIEW 1', currentMode, parent.action, item.action)
@@ -453,12 +455,11 @@ def viewmodeMonitor():
def getCurrentView(item=None, parent_item=None):
if not item:
item = Item()
if not parent_item:
logger.debug('ESCO')
return None, None
# if not parent_item:
# logger.debug('ESCO')
# return None, None
parent_actions = ['peliculas', 'novedades', 'search', 'get_from_temp', 'newest', 'discover_list', 'new_search', 'channel_search']
@@ -490,7 +491,7 @@ def getCurrentView(item=None, parent_item=None):
return 'season', 'tvshows'
elif parent_item.action in ['getmainlist', '', 'getchanneltypes']:
return None, None
return 'home', addons
elif parent_item.action in ['filterchannels']:
return 'channels', addons