Exemplo n.º 1
0
    print params

    if params['action'] == 'playVod':
        if 'infolabels' in params:
            vod.playAsset(params['vod_id'],
                          infolabels=params['infolabels'],
                          parental_rating=int(params['parental_rating']))
        else:
            vod.playAsset(params['vod_id'],
                          parental_rating=int(params['parental_rating']))
    elif params['action'] == 'playClip':
        clips.playClip(params['id'])
    elif params['action'] == 'playLive':
        if 'infolabels' in params:
            liveTv.playLiveTv(params['manifest_url'],
                              package_code=params['package_code'],
                              infolabels=params['infolabels'],
                              parental_rating=int(params['parental_rating']))
        else:
            liveTv.playLiveTv(params['manifest_url'],
                              package_code=params['package_code'],
                              parental_rating=int(params['parental_rating']))

    elif params['action'] == 'listLiveTvChannelDirs':
        nav.listLiveTvChannelDirs()
    elif params['action'] == 'listLiveTvChannels':
        channeldir_name = ''
        if 'channeldir_name' in params:
            channeldir_name = params['channeldir_name']
        nav.listLiveTvChannels(channeldir_name)

    elif params['action'] == 'watchlist':
Exemplo n.º 2
0
addon_handle = int(sys.argv[1])
plugin_base_url = sys.argv[0]
params = dict(urlparse.parse_qsl(sys.argv[2][1:]))

# Router for all plugin actions
if 'action' in params:

    print params

    if params['action'] == 'playVod':
        vod.playAsset(params['vod_id'])
    elif params['action'] == 'playClip':
        clips.playClip(params['id'])
    elif params['action'] == 'playLive':
        liveTv.playLiveTv(params['manifest_url'], params['package_code'])

    elif params['action'] == 'listLiveTvChannelDirs':
        nav.listLiveTvChannelDirs()
    elif params['action'] == 'listLiveTvChannels':
        channeldir_name = ''
        if 'channeldir_name' in params:
            channeldir_name = params['channeldir_name']
        nav.listLiveTvChannels(channeldir_name)

    elif params['action'] == 'watchlist':
        if 'list' in params:
            page = 0
            if 'page' in params:
                page = params['page']
            watchlist.listWatchlist(params['list'], page=page)
Exemplo n.º 3
0
    xbmc.log('[Sky Go] params = %s' % params)

    if params['action'] == 'playVod':
        vod.playAsset(params['vod_id'],
                      infolabels=getDictFromString(
                          params.get('infolabels', None)),
                      art=getDictFromString(params.get('art', None)),
                      parental_rating=int(params.get('parental_rating', 0)))
    elif params['action'] == 'playClip':
        clips.playClip(params['id'])
    elif params['action'] == 'playLive':
        liveTv.playLiveTv(params['manifest_url'],
                          package_code=params.get('package_code'),
                          infolabels=getDictFromString(
                              params.get('infolabels', None)),
                          art=getDictFromString(params.get('art', None)),
                          parental_rating=int(params.get('parental_rating',
                                                         0)))
    elif params['action'] == 'listLiveTvChannelDirs':
        nav.listLiveTvChannelDirs()
    elif params['action'] == 'listLiveTvChannels':
        channeldir_name = ''
        if 'channeldir_name' in params:
            channeldir_name = params['channeldir_name']
        nav.listLiveTvChannels(channeldir_name)

    elif params['action'] == 'watchlist':
        if 'list' in params:
            page = 0
            if 'page' in params:
Exemplo n.º 4
0
addon_handle = int(sys.argv[1])
plugin_base_url = sys.argv[0]
params = dict(urlparse.parse_qsl(sys.argv[2][1:]))

# Router for all plugin actions
if params:

    print params

    if params['action'] == 'playVod':
        vod.playAsset(params['vod_id'])
    elif params['action'] == 'playClip':
        clips.playClip(params['id'])
    elif params['action'] == 'playLive':
        liveTv.playLiveTv(params['channel_id'])

    elif params['action'] == 'listLiveTvChannels':
        nav.listLiveChannels()

    elif params['action'] == 'watchlist':
        if 'list' in params:
            page = 0
            if 'page' in params:
                page = params['page']
            watchlist.listWatchlist(params['list'], page=page)
        else:
            watchlist.rootDir()
    elif params['action'] == 'watchlistAdd':
        watchlist.addToWatchlist(params['id'], params['assetType'])
    elif params['action'] == 'watchlistDel':