def list(self, items):
     params = self.params()
     for item in items:
         if item['type'] == 'dir':
             self.render_dir(item)
         elif item['type'] == 'next':
             params.update({'list': item['url']})
             xbmcutil.add_dir(xbmcutil.__lang__(30007), params,
                              xbmcutil.icon('next.png'))
         elif item['type'] == 'prev':
             params.update({'list': item['url']})
             xbmcutil.add_dir(xbmcutil.__lang__(30008), params,
                              xbmcutil.icon('prev.png'))
         elif item['type'] == 'new':
             params.update({'list': item['url']})
             xbmcutil.add_dir(xbmcutil.__lang__(30012), params,
                              xbmcutil.icon('new.png'))
         elif item['type'] == 'top':
             params.update({'list': item['url']})
             xbmcutil.add_dir(xbmcutil.__lang__(30013), params,
                              xbmcutil.icon('top.png'))
         elif item['type'] == 'video':
             self.render_video(item)
         else:
             self.render_default(item)
Example #2
0
 def root(self):
     if 'search' in self.provider.capabilities():
         params = self.params()
         params.update({'search-list':'#'})
         xbmcutil.add_dir(xbmcutil.__lang__(30003),params,xbmcutil.icon('search.png'))
     xbmcutil.add_local_dir(xbmcutil.__lang__(30006),self.settings['downloads'],xbmcutil.icon('download.png'))	
     self.list(self.provider.categories())
     return xbmcplugin.endOfDirectory(int(sys.argv[1]))
Example #3
0
 def root(self):
     if 'search' in self.provider.capabilities():
         params = self.params()
         params.update({'search-list': ''})
         xbmcutil.add_search_folder(xbmcutil.__lang__(30003), params,
                                    xbmcutil.icon('search.png'))
     self.list(self.provider.categories())
Example #4
0
def root():
    search.item()
    xbmcutil.add_local_dir(xbmcutil.__lang__(30006), settings['downloads'],
                           xbmcutil.icon('download.png'))
    for provider in providers.keys():
        xbmcutil.add_dir(provider, {'cp': provider}, icon(provider))
    return xbmcplugin.endOfDirectory(int(sys.argv[1]))
    def root(self):
        searches = xbmcutil.get_searches(self.addon, self.provider.name)
        if len(searches) > 0:
            self.provider.info('Upgrading to new saved search storage...')
            for s in searches:
                self.provider.info('Moving item %s' % s)
                xbmcutil.search_add(self.cache, s, 9999999)
            xbmcutil.delete_search_history(self.addon, self.provider.name)

        if 'search' in self.provider.capabilities():
            params = self.params()
            params.update({'search-list': '#'})
            xbmcutil.add_dir(xbmcutil.__lang__(30003), params, xbmcutil.icon('search.png'))
        if not '!download' in self.provider.capabilities():
            xbmcutil.add_local_dir(xbmcutil.__lang__(30006), self.settings[
                                   'downloads'], xbmcutil.icon('download.png'))
        self.list(self.provider.categories())
        return xbmcplugin.endOfDirectory(int(sys.argv[1]))
Example #6
0
 def search_list(self):
     params = self.params()
     params.update({'search':'#'})
     menuItems = self.params()
     xbmcutil.add_dir(xbmcutil.__lang__(30004),params,xbmcutil.icon('search.png'))
     for what in xbmcutil.search_list(self.cache):
         params['search'] = what
         menuItems['search-remove'] = what
         xbmcutil.add_dir(what,params,menuItems={xbmc.getLocalizedString(117):menuItems})
     xbmcplugin.endOfDirectory(int(sys.argv[1]))
	def search_list(self):
		params = self.params()
		params.update({'search':''})
		menuItems = self.params()
		xbmcutil.add_search_item(xbmcutil.__lang__(30004), params, xbmcutil.icon('search.png'))
		for what in xbmcutil.get_searches(self.addon, self.provider.name):
			params = self.params()
			menuItems = self.params()
			params['search'] = what
			menuItems['search-remove'] = what
			xbmcutil.add_dir(what, params, menuItems={u'Remove':menuItems})
 def list(self, items):
     params = self.params()
     for item in items:
         if item['type'] == 'dir':
             self.render_dir(item)
         elif item['type'] == 'next':
             params.update({'list': item['url']})
             xbmcutil.add_dir(xbmcutil.__lang__(30007), params, xbmcutil.icon('next.png'))
         elif item['type'] == 'prev':
             params.update({'list': item['url']})
             xbmcutil.add_dir(xbmcutil.__lang__(30008), params, xbmcutil.icon('prev.png'))
         elif item['type'] == 'new':
             params.update({'list': item['url']})
             xbmcutil.add_dir(xbmcutil.__lang__(30012), params, xbmcutil.icon('new.png'))
         elif item['type'] == 'top':
             params.update({'list': item['url']})
             xbmcutil.add_dir(xbmcutil.__lang__(30013), params, xbmcutil.icon('top.png'))
         elif item['type'] == 'video':
             self.render_video(item)
         else:
             self.render_default(item)
Example #9
0
def root():
    search.item({"s": "movie"}, label=xbmcutil.__lang__(30003) + " " + __language__(30017))
    search.item({"s": "person"}, label=xbmcutil.__lang__(30003) + " " + __language__(30018))
    xbmcutil.add_dir(__language__(30041), {"fav": ""}, icon())
    xbmcutil.add_dir(__language__(30044), {"filmoteka": ""}, icon())
    xbmcutil.add_dir("Kino", {"kino": ""}, icon())
    xbmcutil.add_dir("Žebříčky", {"top": ""}, xbmcutil.icon("top.png"))
    xbmcutil.add_dir("Blu-ray", {"dvd": "bluray"}, icon())
    xbmcutil.add_dir("Premiérová DVD", {"dvd": "dvd_retail"}, icon())
    xbmcutil.add_dir("Levná DVD v trafikách a časopisech", {"dvd": "dvd_lite"}, icon())
    xbmcutil.add_dir("Tvůrci", {"artists": ""}, icon())
    xbmcplugin.endOfDirectory(int(sys.argv[1]))
 def search_list(self):
     params = self.params()
     params.update({'search': '#'})
     menu1 = self.params()
     menu2 = self.params()
     xbmcutil.add_dir(xbmcutil.__lang__(30004), params, xbmcutil.icon('search.png'))
     for what in xbmcutil.search_list(self.cache):
         params['search'] = what
         menu1['search-remove'] = what
         menu2['search-edit'] = what
         xbmcutil.add_dir(what, params, menuItems={xbmcutil.__lang__(
             30016): menu2, xbmc.getLocalizedString(117): menu1})
     xbmcplugin.endOfDirectory(int(sys.argv[1]))
def _list(addon,history,key,value):
	params = {}
	menuItems = {}
	if key:
		params[key] = value
		menuItems[key] = value
	params['search'] = '#'
	xbmcutil.add_dir(xbmcutil.__lang__(30004),params,xbmcutil.icon('search.png'))
	for what in xbmcutil.get_searches(addon,history):
		params['search'] = what
		menuItems['search-remove'] = what
		xbmcutil.add_dir(what,params,menuItems={xbmc.getLocalizedString(117):menuItems})
	xbmcplugin.endOfDirectory(int(sys.argv[1]))
def _list(addon, history, key, value):
    params = {}
    menuItems = {}
    if key:
        params[key] = value
        menuItems[key] = value
    params['search'] = '#'
    xbmcutil.add_dir(xbmcutil.__lang__(30004), params,
                     xbmcutil.icon('search.png'))
    for what in xbmcutil.get_searches(addon, history):
        params['search'] = what
        menuItems['search-remove'] = what
        xbmcutil.add_dir(what,
                         params,
                         menuItems={xbmc.getLocalizedString(117): menuItems})
    xbmcplugin.endOfDirectory(int(sys.argv[1]))
Example #13
0
 def search_list(self):
     params = self.params()
     params.update({'search':''})
     xbmcutil.add_search_item(xbmcutil.__lang__(30004), params, xbmcutil.icon('search.png'))
     maximum = 10
     try:
         maximum = int(self.settings['keep-searches'])
     except:
         pass
     for what in xbmcutil.get_searches(self.addon, self.provider.name, maximum):
         params = self.params()
         menuItems = self.params()
         menuItems2 = self.params()
         params['search'] = what
         menuItems['search-remove'] = what
         menuItems2['search-edit'] = what
         xbmcutil.add_dir(what, params, menuItems={u'Remove':menuItems,u'Edit':menuItems2})
Example #14
0
def _list(addon,history,key,value):
	params = {}
	menuItems = {}
	if key:
		params[key] = value
		menuItems[key] = value
	params['search'] = ''
	xbmcutil.add_search_item(xbmcutil.__lang__(30004),params,xbmcutil.icon('search.png'))
	for what in xbmcutil.get_searches(addon,history):
		params = {}
		menuItems={}
		if key:
			params[key] = value
			menuItems[key] = value
		params['search'] = what
		menuItems['search-remove'] = what
		xbmcutil.add_dir(what,params,menuItems={u"Remove":menuItems})
Example #15
0
def _list(addon, history, key, value):
    params = {}
    menuItems = {}
    if key:
        params[key] = value
        menuItems[key] = value
    params['search'] = ''
    xbmcutil.add_search_item(xbmcutil.__lang__(30004), params,
                             xbmcutil.icon('search.png'))
    for what in xbmcutil.get_searches(addon, history):
        params = {}
        menuItems = {}
        if key:
            params[key] = value
            menuItems[key] = value
        params['search'] = what
        menuItems['search-remove'] = what
        xbmcutil.add_dir(what, params, menuItems={u"Remove": menuItems})
Example #16
0
 def search_list(self):
     params = self.params()
     params.update({'search': ''})
     xbmcutil.add_search_item(xbmcutil.__lang__(30004), params,
                              xbmcutil.icon('search.png'))
     for what in xbmcutil.get_searches(self.addon, self.provider.name):
         params = self.params()
         menuItems = self.params()
         menuItems2 = self.params()
         params['search'] = what
         menuItems['search-remove'] = what
         menuItems2['search-edit'] = what
         xbmcutil.add_dir(what,
                          params,
                          menuItems={
                              u'Remove': menuItems,
                              u'Edit': menuItems2
                          })
Example #17
0
 def search_list(self):
     params = self.params()
     params.update({'search': ''})
     xbmcutil.add_search_item(xbmcutil.__lang__(30004), params,
                              xbmcutil.icon('search.png'))
     maximum = 10
     try:
         maximum = int(self.settings['keep-searches'])
     except:
         pass
     for what in xbmcutil.get_searches(self.addon, self.provider.name,
                                       maximum):
         params = self.params()
         menuItems = self.params()
         menuItems2 = self.params()
         params['search'] = what
         menuItems['search-remove'] = what
         menuItems2['search-edit'] = what
         xbmcutil.add_dir(what,
                          params,
                          menuItems={
                              u'Remove': menuItems,
                              u'Edit': menuItems2
                          })
Example #18
0
def root():
	search.item()
	xbmcutil.add_local_dir(xbmcutil.__lang__(30006),settings['downloads'],xbmcutil.icon('download.png'))
	for provider in providers.keys():
		xbmcutil.add_dir(provider,{'cp':provider},icon(provider))
	return xbmcplugin.endOfDirectory(int(sys.argv[1]))
Example #19
0
 def render_default(self, item):
     params = self.params()
     if item['type'] == 'top':
         params.update({'list': item['url']})
         xbmcutil.add_dir(item['title'], params, xbmcutil.icon('top.png'))
def item(items={}, label=xbmcutil.__lang__(30003)):
    items['search-list'] = '#'
    xbmcutil.add_dir(label, items, xbmcutil.icon('search.png'))
Example #21
0
def item(items={},label=xbmcutil.__lang__(30003)):
	items['search-list'] = ''
	xbmcutil.add_search_folder(label,items,xbmcutil.icon('search.png'))
	def render_default(self, item):
		params = self.params()
		if item['type'] == 'top':
			params.update({'list':item['url']})
			xbmcutil.add_dir(item['title'], params, xbmcutil.icon('top.png'))
Example #23
0
 def root(self):
     if 'search' in self.provider.capabilities():
         params = self.params()
         params.update({'search-list':''})
         xbmcutil.add_search_folder(xbmcutil.__lang__(30003), params, xbmcutil.icon('search.png'))
     self.list(self.provider.categories())