mirror of
https://github.com/jellyfin/jellyfin-kodi.git
synced 2025-05-21 00:35:08 +00:00
Change most string occurrences of Emby to Jellyfin (case sensitive)
This commit is contained in:
parent
168bab2b01
commit
59c1dd42e3
79 changed files with 833 additions and 832 deletions
|
@ -23,7 +23,7 @@ from utils import get_play_action
|
|||
|
||||
#################################################################################################
|
||||
|
||||
LOG = logging.getLogger("EMBY."+__name__)
|
||||
LOG = logging.getLogger("JELLYFIN."+__name__)
|
||||
|
||||
#################################################################################################
|
||||
|
||||
|
@ -89,8 +89,8 @@ class Actions(object):
|
|||
Detect the seektime for video type content.
|
||||
Verify the default video action set in Kodi for accurate resume behavior.
|
||||
'''
|
||||
seektime = window('emby.resume.bool')
|
||||
window('emby.resume', clear=True)
|
||||
seektime = window('jellyfin.resume.bool')
|
||||
window('jellyfin.resume', clear=True)
|
||||
|
||||
if item['MediaType'] in ('Video', 'Audio'):
|
||||
resume = item['UserData'].get('PlaybackPositionTicks')
|
||||
|
@ -128,7 +128,7 @@ class Actions(object):
|
|||
|
||||
if settings('askCinema') == "true":
|
||||
|
||||
resp = dialog("yesno", heading="{emby}", line1=_(33016))
|
||||
resp = dialog("yesno", heading="{jellyfin}", line1=_(33016))
|
||||
if not resp:
|
||||
|
||||
enabled = False
|
||||
|
@ -148,7 +148,7 @@ class Actions(object):
|
|||
|
||||
self.stack.append([intro['PlaybackInfo']['Path'], listitem])
|
||||
|
||||
window('emby.skip.%s' % intro['Id'], value="true")
|
||||
window('jellyfin.skip.%s' % intro['Id'], value="true")
|
||||
|
||||
def _set_additional_parts(self, item_id):
|
||||
|
||||
|
@ -659,7 +659,7 @@ class Actions(object):
|
|||
LOG.info("Resume dialog called.")
|
||||
XML_PATH = (xbmcaddon.Addon('plugin.video.jellyfin').getAddonInfo('path'), "default", "1080i")
|
||||
|
||||
dialog = resume.ResumeDialog("script-emby-resume.xml", *XML_PATH)
|
||||
dialog = resume.ResumeDialog("script-jellyfin-resume.xml", *XML_PATH)
|
||||
dialog.set_resume_point("Resume from %s" % str(timedelta(seconds=seektime)).split(".")[0])
|
||||
dialog.doModal()
|
||||
|
||||
|
@ -721,14 +721,14 @@ def on_update(data, server):
|
|||
|
||||
if item:
|
||||
|
||||
if not window('emby.skip.%s.bool' % item[0]):
|
||||
if not window('jellyfin.skip.%s.bool' % item[0]):
|
||||
server['api'].item_played(item[0], playcount)
|
||||
|
||||
window('emby.skip.%s' % item[0], clear=True)
|
||||
window('jellyfin.skip.%s' % item[0], clear=True)
|
||||
|
||||
def on_play(data, server):
|
||||
|
||||
''' Setup progress for emby playback.
|
||||
''' Setup progress for jellyfin playback.
|
||||
'''
|
||||
player = xbmc.Player()
|
||||
|
||||
|
@ -781,7 +781,7 @@ def special_listener():
|
|||
'''
|
||||
player = xbmc.Player()
|
||||
isPlaying = player.isPlaying()
|
||||
count = int(window('emby.external_count') or 0)
|
||||
count = int(window('jellyfin.external_count') or 0)
|
||||
|
||||
if (not isPlaying and xbmc.getCondVisibility('Window.IsVisible(DialogContextMenu.xml)') and
|
||||
xbmc.getInfoLabel('Control.GetLabel(1002)') == xbmc.getLocalizedString(12021)):
|
||||
|
@ -791,24 +791,24 @@ def special_listener():
|
|||
if control == 1002: # Start from beginning
|
||||
|
||||
LOG.info("Resume dialog: Start from beginning selected.")
|
||||
window('emby.resume.bool', False)
|
||||
window('jellyfin.resume.bool', False)
|
||||
else:
|
||||
LOG.info("Resume dialog: Resume selected.")
|
||||
window('emby.resume.bool', True)
|
||||
window('jellyfin.resume.bool', True)
|
||||
|
||||
elif isPlaying and not window('emby.external_check'):
|
||||
elif isPlaying and not window('jellyfin.external_check'):
|
||||
time = player.getTime()
|
||||
|
||||
if time > 1: # Not external player.
|
||||
|
||||
window('emby.external_check', value="true")
|
||||
window('emby.external_count', value="0")
|
||||
window('jellyfin.external_check', value="true")
|
||||
window('jellyfin.external_count', value="0")
|
||||
elif count == 120:
|
||||
|
||||
LOG.info("External player detected.")
|
||||
window('emby.external.bool', True)
|
||||
window('emby.external_check.bool', True)
|
||||
window('emby.external_count', value="0")
|
||||
window('jellyfin.external.bool', True)
|
||||
window('jellyfin.external_check.bool', True)
|
||||
window('jellyfin.external_count', value="0")
|
||||
|
||||
elif time == 0:
|
||||
window('emby.external_count', value=str(count + 1))
|
||||
window('jellyfin.external_count', value=str(count + 1))
|
||||
|
|
|
@ -17,7 +17,7 @@ import requests
|
|||
|
||||
##################################################################################################
|
||||
|
||||
LOG = logging.getLogger("EMBY."+__name__)
|
||||
LOG = logging.getLogger("JELLYFIN."+__name__)
|
||||
|
||||
##################################################################################################
|
||||
|
||||
|
@ -247,7 +247,7 @@ from __objs__ import QU
|
|||
|
||||
##################################################################################################
|
||||
|
||||
log = logging.getLogger("EMBY."+__name__)
|
||||
log = logging.getLogger("JELLYFIN."+__name__)
|
||||
|
||||
##################################################################################################
|
||||
|
||||
|
@ -278,7 +278,7 @@ class Artwork(object):
|
|||
# This method will sync all Kodi artwork to textures13.db
|
||||
# and cache them locally. This takes diskspace!
|
||||
if not dialog(type_="yesno",
|
||||
heading="{emby}",
|
||||
heading="{jellyfin}",
|
||||
line1=_(33042)):
|
||||
return
|
||||
|
||||
|
@ -288,7 +288,7 @@ class Artwork(object):
|
|||
pdialog.create(_(29999), _(33043))
|
||||
|
||||
# ask to rest all existing or not
|
||||
if dialog(type_="yesno", heading="{emby}", line1=_(33044)):
|
||||
if dialog(type_="yesno", heading="{jellyfin}", line1=_(33044)):
|
||||
log.info("Resetting all cache data first")
|
||||
self.delete_cache()
|
||||
|
||||
|
|
|
@ -12,7 +12,7 @@ from helper import values
|
|||
|
||||
##################################################################################################
|
||||
|
||||
LOG = logging.getLogger("EMBY."+__name__)
|
||||
LOG = logging.getLogger("JELLYFIN."+__name__)
|
||||
|
||||
##################################################################################################
|
||||
|
||||
|
|
|
@ -9,7 +9,7 @@ import queries as QU
|
|||
|
||||
##################################################################################################
|
||||
|
||||
LOG = logging.getLogger("EMBY."+__name__)
|
||||
LOG = logging.getLogger("JELLYFIN."+__name__)
|
||||
|
||||
##################################################################################################
|
||||
|
||||
|
|
|
@ -9,7 +9,7 @@ from kodi import Kodi
|
|||
|
||||
##################################################################################################
|
||||
|
||||
LOG = logging.getLogger("EMBY."+__name__)
|
||||
LOG = logging.getLogger("JELLYFIN."+__name__)
|
||||
|
||||
##################################################################################################
|
||||
|
||||
|
|
|
@ -9,7 +9,7 @@ from kodi import Kodi
|
|||
|
||||
##################################################################################################
|
||||
|
||||
log = logging.getLogger("EMBY."+__name__)
|
||||
log = logging.getLogger("JELLYFIN."+__name__)
|
||||
|
||||
##################################################################################################
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
|
||||
''' Queries for the Kodi database. obj reflect key/value to retrieve from emby items.
|
||||
''' Queries for the Kodi database. obj reflect key/value to retrieve from jellyfin items.
|
||||
Some functions require additional information, therefore obj do not always reflect
|
||||
the Kodi database query values.
|
||||
'''
|
||||
|
|
|
@ -9,7 +9,7 @@ from kodi import Kodi
|
|||
|
||||
##################################################################################################
|
||||
|
||||
LOG = logging.getLogger("EMBY."+__name__)
|
||||
LOG = logging.getLogger("JELLYFIN."+__name__)
|
||||
|
||||
##################################################################################################
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@ from helper import api, catch, stop, validate, emby_item, library_check, values,
|
|||
|
||||
##################################################################################################
|
||||
|
||||
LOG = logging.getLogger("EMBY."+__name__)
|
||||
LOG = logging.getLogger("JELLYFIN."+__name__)
|
||||
|
||||
##################################################################################################
|
||||
|
||||
|
@ -320,7 +320,7 @@ class Movies(KodiDb):
|
|||
@emby_item()
|
||||
def remove(self, item_id, e_item):
|
||||
|
||||
''' Remove movieid, fileid, emby reference.
|
||||
''' Remove movieid, fileid, jellyfin reference.
|
||||
Remove artwork, boxset
|
||||
'''
|
||||
obj = {'Id': item_id}
|
||||
|
|
|
@ -14,7 +14,7 @@ from helper import api, catch, stop, validate, emby_item, values, library_check,
|
|||
|
||||
##################################################################################################
|
||||
|
||||
LOG = logging.getLogger("EMBY."+__name__)
|
||||
LOG = logging.getLogger("JELLYFIN."+__name__)
|
||||
|
||||
##################################################################################################
|
||||
|
||||
|
@ -103,7 +103,7 @@ class Music(KodiDb):
|
|||
|
||||
''' Add object to kodi.
|
||||
|
||||
safety checks: It looks like Emby supports the same artist multiple times.
|
||||
safety checks: It looks like Jellyfin supports the same artist multiple times.
|
||||
Kodi doesn't allow that. In case that happens we just merge the artist entries.
|
||||
'''
|
||||
obj['ArtistId'] = self.get(*values(obj, QU.get_artist_obj))
|
||||
|
@ -203,7 +203,7 @@ class Music(KodiDb):
|
|||
def artist_link(self, obj):
|
||||
|
||||
''' Assign main artists to album.
|
||||
Artist does not exist in emby database, create the reference.
|
||||
Artist does not exist in jellyfin database, create the reference.
|
||||
'''
|
||||
for artist in (obj['AlbumArtists'] or []):
|
||||
|
||||
|
@ -392,7 +392,7 @@ class Music(KodiDb):
|
|||
def song_artist_link(self, obj):
|
||||
|
||||
''' Assign main artists to song.
|
||||
Artist does not exist in emby database, create the reference.
|
||||
Artist does not exist in jellyfin database, create the reference.
|
||||
'''
|
||||
for index, artist in enumerate(obj['ArtistItems'] or []):
|
||||
|
||||
|
@ -533,7 +533,7 @@ class Music(KodiDb):
|
|||
@emby_item()
|
||||
def get_child(self, item_id, e_item):
|
||||
|
||||
''' Get all child elements from tv show emby id.
|
||||
''' Get all child elements from tv show jellyfin id.
|
||||
'''
|
||||
obj = {'Id': item_id}
|
||||
child = []
|
||||
|
|
|
@ -14,7 +14,7 @@ from helper import api, catch, stop, validate, library_check, emby_item, values,
|
|||
|
||||
##################################################################################################
|
||||
|
||||
LOG = logging.getLogger("EMBY."+__name__)
|
||||
LOG = logging.getLogger("JELLYFIN."+__name__)
|
||||
|
||||
##################################################################################################
|
||||
|
||||
|
@ -51,7 +51,7 @@ class MusicVideos(KodiDb):
|
|||
''' If item does not exist, entry will be added.
|
||||
If item exists, entry will be updated.
|
||||
|
||||
If we don't get the track number from Emby, see if we can infer it
|
||||
If we don't get the track number from Jellyfin, see if we can infer it
|
||||
from the sortname attribute.
|
||||
'''
|
||||
API = api.API(item, self.server['auth/server-address'])
|
||||
|
@ -220,7 +220,7 @@ class MusicVideos(KodiDb):
|
|||
@emby_item()
|
||||
def remove(self, item_id, e_item):
|
||||
|
||||
''' Remove mvideoid, fileid, pathid, emby reference.
|
||||
''' Remove mvideoid, fileid, pathid, jellyfin reference.
|
||||
'''
|
||||
obj = {'Id': item_id}
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@ import os
|
|||
|
||||
##################################################################################################
|
||||
|
||||
LOG = logging.getLogger("EMBY."+__name__)
|
||||
LOG = logging.getLogger("JELLYFIN."+__name__)
|
||||
|
||||
##################################################################################################
|
||||
|
||||
|
@ -37,7 +37,7 @@ class Objects(object):
|
|||
''' Syntax to traverse the item dictionary.
|
||||
This of the query almost as a url.
|
||||
|
||||
Item is the Emby item json object structure
|
||||
Item is the Jellyfin item json object structure
|
||||
|
||||
",": each element will be used as a fallback until a value is found.
|
||||
"?": split filters and key name from the query part, i.e. MediaSources/0?$Name
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
"video": "special://database/MyVideos107.db",
|
||||
"music": "special://database/MyMusic60.db",
|
||||
"texture": "special://database/Textures13.db",
|
||||
"emby": "special://database/emby.db",
|
||||
"jellyfin": "special://database/jellyfin.db",
|
||||
"MovieProviderName": "imdb",
|
||||
"Movie": {
|
||||
"Id": "Id",
|
||||
|
@ -40,7 +40,7 @@
|
|||
"Audio": "MediaSources/0/MediaStreams:?Type=Audio",
|
||||
"Video": "MediaSources/0/MediaStreams:?Type=Video",
|
||||
"Container": "MediaSources/0/Container",
|
||||
"EmbyParentId": "ParentId",
|
||||
"JellyfinParentId": "ParentId",
|
||||
"CriticRating": "CriticRating"
|
||||
},
|
||||
"MovieUserData": {
|
||||
|
@ -77,7 +77,7 @@
|
|||
"Tags": "Tags",
|
||||
"Favorite": "UserData/IsFavorite",
|
||||
"RecursiveCount": "RecursiveItemCount",
|
||||
"EmbyParentId": "ParentId",
|
||||
"JellyfinParentId": "ParentId",
|
||||
"Status": "Status"
|
||||
},
|
||||
"Season": {
|
||||
|
@ -119,7 +119,7 @@
|
|||
"Video": "MediaSources/0/MediaStreams:?Type=Video",
|
||||
"Container": "MediaSources/0/Container",
|
||||
"Location": "LocationType",
|
||||
"EmbyParentId": "SeriesId,ParentId"
|
||||
"JellyfinParentId": "SeriesId,ParentId"
|
||||
},
|
||||
"EpisodeUserData": {
|
||||
"Id": "Id",
|
||||
|
@ -160,7 +160,7 @@
|
|||
"Played": "UserData/Played",
|
||||
"Favorite": "UserData/IsFavorite",
|
||||
"Directors": "People:?Type=Director$Name",
|
||||
"EmbyParentId": "ParentId"
|
||||
"JellyfinParentId": "ParentId"
|
||||
},
|
||||
"MusicVideoUserData": {
|
||||
"Id": "Id",
|
||||
|
@ -178,7 +178,7 @@
|
|||
"UniqueId": "ProviderIds/MusicBrainzArtist",
|
||||
"Genres": "Genres",
|
||||
"Bio": "Overview",
|
||||
"EmbyParentId": "ParentId"
|
||||
"JellyfinParentId": "ParentId"
|
||||
},
|
||||
"Album": {
|
||||
"Id": "Id",
|
||||
|
@ -190,7 +190,7 @@
|
|||
"AlbumArtists": "AlbumArtists",
|
||||
"Artists": "AlbumArtists:?$Name",
|
||||
"ArtistItems": "ArtistItems",
|
||||
"EmbyParentId": "ParentId"
|
||||
"JellyfinParentId": "ParentId"
|
||||
},
|
||||
"Song": {
|
||||
"Id": "Id",
|
||||
|
@ -213,7 +213,7 @@
|
|||
"Album": "Album",
|
||||
"SongAlbumId": "AlbumId",
|
||||
"Container": "MediaSources/0/Container",
|
||||
"EmbyParentId": "ParentId"
|
||||
"JellyfinParentId": "ParentId"
|
||||
},
|
||||
"SongUserData": {
|
||||
"Id": "Id",
|
||||
|
|
|
@ -16,7 +16,7 @@ from helper import api, catch, stop, validate, emby_item, library_check, setting
|
|||
|
||||
##################################################################################################
|
||||
|
||||
LOG = logging.getLogger("EMBY."+__name__)
|
||||
LOG = logging.getLogger("JELLYFIN."+__name__)
|
||||
|
||||
##################################################################################################
|
||||
|
||||
|
@ -512,7 +512,7 @@ class TVShows(KodiDb):
|
|||
@emby_item()
|
||||
def remove(self, item_id, e_item):
|
||||
|
||||
''' Remove showid, fileid, pathid, emby reference.
|
||||
''' Remove showid, fileid, pathid, jellyfin reference.
|
||||
There's no episodes left, delete show and any possible remaining seasons
|
||||
'''
|
||||
obj = {'Id': item_id}
|
||||
|
@ -614,7 +614,7 @@ class TVShows(KodiDb):
|
|||
@emby_item()
|
||||
def get_child(self, item_id, e_item):
|
||||
|
||||
''' Get all child elements from tv show emby id.
|
||||
''' Get all child elements from tv show jellyfin id.
|
||||
'''
|
||||
obj = {'Id': item_id}
|
||||
child = []
|
||||
|
|
|
@ -8,7 +8,7 @@ from helper import JSONRPC
|
|||
|
||||
#################################################################################################
|
||||
|
||||
LOG = logging.getLogger("EMBY."+__name__)
|
||||
LOG = logging.getLogger("JELLYFIN."+__name__)
|
||||
|
||||
#################################################################################################
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue