From 73fa9588d6c471e8f3e84c1d5278648556e56b8c Mon Sep 17 00:00:00 2001 From: inpos Date: Tue, 31 Jan 2017 09:22:15 +0300 Subject: [PATCH] =?UTF-8?q?=D0=9E=D0=B1=D1=85=D0=BE=D0=B4=20=D0=BE=D1=82?= =?UTF-8?q?=D1=81=D1=83=D1=82=D1=81=D1=82=D0=B2=D0=B8=D1=8F=20=D1=82=D0=B8?= =?UTF-8?q?=D0=BF=D0=B0=20=D1=81=D0=BE=D0=B4=D0=B5=D1=80=D0=B6=D0=B8=D0=BC?= =?UTF-8?q?=D0=BE=D0=B3=D0=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- kodi-vk.inpos.ru/default.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/kodi-vk.inpos.ru/default.py b/kodi-vk.inpos.ru/default.py index ef46089..a78216c 100644 --- a/kodi-vk.inpos.ru/default.py +++ b/kodi-vk.inpos.ru/default.py @@ -336,7 +336,6 @@ class KodiVKGUIVideos(object): y_id = sr[0][1] url = u'plugin://plugin.video.youtube/?action=play_video&videoid=' + y_id else: - xbmc.log(repr(v.info)) continue xbmcplugin.addDirectoryItem(_addon_id, url, list_item, isFolder = False) if page < vids['pages']: @@ -500,6 +499,14 @@ class KodiVk: p.update(dict(urlparse.parse_qsl(sys.argv[2][1:]))) self.params = p self.c_type = p.get('content_type', None) + if not self.c_type: + cw_id = xbmcgui.getCurrentWindowId() + if cw_id in (10006, 10024, 10025, 10028): + self.c_type = _CTYPE_VIDEO + elif id in (10005, 10500, 10501, 10502): + self.c_type = _CTYPE_AUDIO + elif id in (10002,): + self.c_type = _CTYPE_IMAGE def url(self, params=dict(), **kwparams): if self.c_type: kwparams['content_type'] = self.c_type