def show_mainmenu(): """ Show the main menu """ listing = [ TitleItem( title=kodiutils.localize(30001), # A-Z path=kodiutils.url_for('show_catalog'), art_dict=dict( icon='DefaultMovieTitle.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict(plot=kodiutils.localize(30002), )), TitleItem( title=kodiutils.localize(30007), # TV Channels path=kodiutils.url_for('show_channels'), art_dict=dict( icon='DefaultAddonPVRClient.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict(plot=kodiutils.localize(30008), )), TitleItem( title=kodiutils.localize(30009), # Search path=kodiutils.url_for('show_search'), art_dict=dict( icon='DefaultAddonsSearch.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict(plot=kodiutils.localize(30010), )) ] kodiutils.show_listing(listing, sort=['unsorted'])
def show_mainmenu(): """ Show the main menu """ listing = [ TitleItem( title=kodiutils.localize(30001), # A-Z path=kodiutils.url_for('show_catalog'), art_dict=dict( icon='DefaultMovieTitle.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict(plot=kodiutils.localize(30002), )), TitleItem( title=kodiutils.localize(30007), # TV Channels path=kodiutils.url_for('show_channels'), art_dict=dict( icon='DefaultAddonPVRClient.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict(plot=kodiutils.localize(30008), )), TitleItem( title=kodiutils.localize(30003), # Catalog path=kodiutils.url_for('show_categories'), art_dict=dict( icon='DefaultGenre.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict(plot=kodiutils.localize(30004), )), TitleItem( title=kodiutils.localize(30005), # Recommendations path=kodiutils.url_for('show_recommendations'), art_dict=dict( icon='DefaultFavourites.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict(plot=kodiutils.localize(30006), )), TitleItem( title=kodiutils.localize(30011), # My List path=kodiutils.url_for('show_mylist'), art_dict=dict( icon='DefaultPlaylist.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict(plot=kodiutils.localize(30012), )), TitleItem( title=kodiutils.localize(30009), # Search path=kodiutils.url_for('show_search'), art_dict=dict( icon='DefaultAddonsSearch.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict(plot=kodiutils.localize(30010), )) ] kodiutils.show_listing(listing, sort=['unsorted'])
def show_mainmenu(self): """ Show the main menu. """ listing = [] account = self._auth.get_tokens() if account.product == PRODUCT_STREAMZ: listing.append(TitleItem( title=kodiutils.localize(30015), # Recommendations path=kodiutils.url_for('show_recommendations', storefront=STOREFRONT_MAIN), art_dict=dict( icon='DefaultFavourites.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict( plot=kodiutils.localize(30016), ), )) listing.append(TitleItem( title=kodiutils.localize(30003), # Movies path=kodiutils.url_for('show_recommendations', storefront=STOREFRONT_MOVIES), art_dict=dict( icon='DefaultMovies.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict( plot=kodiutils.localize(30004), ), )) listing.append(TitleItem( title=kodiutils.localize(30005), # Series path=kodiutils.url_for('show_recommendations', storefront=STOREFRONT_SERIES), art_dict=dict( icon='DefaultTVShows.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict( plot=kodiutils.localize(30006), ), )) listing.append(TitleItem( title=kodiutils.localize(30021), # Kids path=kodiutils.url_for('show_recommendations', storefront=STOREFRONT_KIDS), art_dict=dict( icon='DefaultFavourites.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict( plot=kodiutils.localize(30022), ), )) elif account.product == PRODUCT_STREAMZ_KIDS: listing.append(TitleItem( title=kodiutils.localize(30015), # Recommendations path=kodiutils.url_for('show_recommendations', storefront=STOREFRONT_MAIN_KIDS), art_dict=dict( icon='DefaultFavourites.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict( plot=kodiutils.localize(30016), ), )) if kodiutils.get_setting_bool('interface_show_mylist'): listing.append(TitleItem( title=kodiutils.localize(30017), # My List path=kodiutils.url_for('show_mylist'), art_dict=dict( icon='DefaultPlaylist.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict( plot=kodiutils.localize(30018), ), )) if kodiutils.get_setting_bool('interface_show_continuewatching'): listing.append(TitleItem( title=kodiutils.localize(30019), # Continue watching path=kodiutils.url_for('show_continuewatching'), art_dict=dict( icon='DefaultInProgressShows.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict( plot=kodiutils.localize(30020), ), )) listing.append(TitleItem( title=kodiutils.localize(30009), # Search path=kodiutils.url_for('show_search'), art_dict=dict( icon='DefaultAddonsSearch.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict( plot=kodiutils.localize(30010), ), )) kodiutils.show_listing(listing, sort=['unsorted'])
def show_mainmenu(self): """ Show the main menu. """ listing = [] account = self._auth.login() if account.product == 'STREAMZ': listing.append( TitleItem( title=kodiutils.localize(30015), # Recommendations path=kodiutils.url_for('show_recommendations', storefront=STOREFRONT_MAIN), art_dict=dict( icon='DefaultFavourites.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict(plot=kodiutils.localize(30016), ), )) listing.append( TitleItem( title=kodiutils.localize(30003), # Movies path=kodiutils.url_for('show_recommendations', storefront=STOREFRONT_MOVIES), art_dict=dict( icon='DefaultMovies.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict(plot=kodiutils.localize(30004), ), )) listing.append( TitleItem( title=kodiutils.localize(30005), # Series path=kodiutils.url_for('show_recommendations', storefront=STOREFRONT_SERIES), art_dict=dict( icon='DefaultTVShows.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict(plot=kodiutils.localize(30006), ), )) listing.append( TitleItem( title=kodiutils.localize(30021), # Kids path=kodiutils.url_for('show_recommendations', storefront=STOREFRONT_KIDS), art_dict=dict( icon='DefaultFavourites.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict(plot=kodiutils.localize(30022), ), )) elif account.product == 'STREAMZ_KIDS': listing.append( TitleItem( title=kodiutils.localize(30015), # Recommendations path=kodiutils.url_for('show_recommendations', storefront=STOREFRONT_MAIN_KIDS), art_dict=dict( icon='DefaultFavourites.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict(plot=kodiutils.localize(30016), ), )) if kodiutils.get_setting_bool('interface_show_az'): listing.append( TitleItem( title=kodiutils.localize(30001), # A-Z path=kodiutils.url_for('show_catalog_all'), art_dict=dict( icon='DefaultMovieTitle.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict(plot=kodiutils.localize(30002), ), )) # listing.append(TitleItem( # title=kodiutils.localize(30003), # Catalogue # path=kodiutils.url_for('show_catalog'), # art_dict=dict( # icon='DefaultGenre.png', # fanart=kodiutils.get_addon_info('fanart'), # ), # info_dict=dict( # plot=kodiutils.localize(30004), # ), # )) if kodiutils.get_setting_bool('interface_show_mylist'): listing.append( TitleItem( title=kodiutils.localize(30017), # My List path=kodiutils.url_for('show_mylist'), art_dict=dict( icon='DefaultPlaylist.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict(plot=kodiutils.localize(30018), ), )) # if kodiutils.get_setting_as_bool('interface_show_continuewatching') and kodiutils.has_credentials(): # listing.append(TitleItem( # title=kodiutils.localize(30019), # Continue watching # path=kodiutils.url_for('show_continuewatching'), # art_dict=dict( # icon='DefaultInProgressShows.png', # fanart=kodiutils.get_addon_info('fanart'), # ), # info_dict=dict( # plot=kodiutils.localize(30020), # ), # )) listing.append( TitleItem( title=kodiutils.localize(30009), # Search path=kodiutils.url_for('show_search'), art_dict=dict( icon='DefaultAddonsSearch.png', fanart=kodiutils.get_addon_info('fanart'), ), info_dict=dict(plot=kodiutils.localize(30010), ), )) kodiutils.show_listing(listing, sort=['unsorted'])