Skip to content

Commit

Permalink
enhanced library refresh for all types of content
Browse files Browse the repository at this point in the history
  • Loading branch information
DonDavici committed Mar 8, 2015
1 parent f8bf379 commit 7eacc91
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 4 deletions.
12 changes: 9 additions & 3 deletions src/DP_PlexLibrary.py
Original file line number Diff line number Diff line change
Expand Up @@ -2831,11 +2831,17 @@ def transcode(self, myID, url):
def getFullListEntry(self, entryData, url, viewState = None, isDirectory = False):
printl("", self, "S")

if not isDirectory and "ratingKey" in entryData:
# build specific context menu entries
# TODO check after some time if we can delete this
# if not isDirectory and "ratingKey" in entryData:
# # build specific context menu entries
# contextMenu = self.buildContextMenu(url, entryData['ratingKey'], entryData['server'])
# else:
# # directories have no contextMenu
# contextMenu = None

if "ratingKey" in entryData:
contextMenu = self.buildContextMenu(url, entryData['ratingKey'], entryData['server'])
else:
# directories have no contextMenu
contextMenu = None

# build url for content
Expand Down
3 changes: 2 additions & 1 deletion src/DP_ViewMixed.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,8 @@ def _refresh(self):
# we use this for filtermode at startup
self.filterableContent = True

self.setMediaFunctions()

if self.details.get("type") == "movie" or self.details.get("type") == "episode":
# handle pictures
self.changeBackdrop = True
Expand Down Expand Up @@ -111,7 +113,6 @@ def _refresh(self):

# final sets
self.setDuration()
self.setMediaFunctions()

elif self.details.get("type") == "season":
# handle pictures
Expand Down
2 changes: 2 additions & 0 deletions src/DP_ViewMusic.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,8 @@ def _refresh(self):
# we use this for filtermode at startup
self.filterableContent = True

self.setMediaFunctions()

if "type" in self.details:
if self.details["type"] == "folder":
self.fromDirectory = True
Expand Down

0 comments on commit 7eacc91

Please sign in to comment.