Esempio n. 1
0
def markMovieDuringPlayback(watched , imdb=None, tmdb=None,  refresh=False):
    try:
        if not control.setting('trakt.scrobbleMovies') == 'true': raise Exception() 
        if trakt.getTraktIndicatorsInfo() == False: raise Exception()
        
        if int(watched) == 7: 
            # AVOID DUPLICATE WATCHING
            indicators = getMovieIndicators(refresh=True)
            overlay = int(getMovieOverlay(indicators, imdb=imdb, tmdb=tmdb, traktOnly=True))
            if overlay == 7: raise Exception()
            
            trakt.markMovieAsWatched(imdb=imdb, tmdb=tmdb)
        else: 

            trakt.markMovieAsNotWatched(imdb=imdb, tmdb=tmdb)
        trakt.cachesyncMovies()
    except:
        pass
    try:
        type = 'movie'
        action = str(watched)
        meta = {'imdb': imdb, 'tmdb': tmdb} 
        playcountMeta(type, meta, action)
    except:
        pass
    if refresh== True: control.refresh()
Esempio n. 2
0
def movies(imdb, watched):
    # control.busy()
    try:
        if not control.setting('trakt.scrobbleMovies') == 'true': raise Exception()	
        if trakt.getTraktIndicatorsInfo() == False: raise Exception()
        if int(watched) == 7: trakt.markMovieAsWatched(imdb)
        else: trakt.markMovieAsNotWatched(imdb)
        trakt.cachesyncMovies()
    except:
        pass

    try:
        type = 'movie'
        action = str(watched)
        meta = {'imdb': imdb, 'tmdb':imdb} 
        playcountMeta(type, meta, action)
    except:
        pass