xbmc: add upstream patch

Signed-off-by: Stephan Raue <stephan@openelec.tv>
This commit is contained in:
Stephan Raue 2014-03-29 03:16:47 +01:00
parent 095d2336ed
commit d685ca7bed

View File

@ -0,0 +1,58 @@
From ab0ae8ac9c7194f3c8dccc27db635df7ad75eab8 Mon Sep 17 00:00:00 2001
From: Jonathan Marshall <jmarshall@xbmc.org>
Date: Sat, 29 Mar 2014 14:29:24 +1300
Subject: [PATCH] [music] content type wasn't set in a bunch of cases. fixes
#14915, fixes #15057
---
xbmc/music/windows/GUIWindowMusicNav.cpp | 26 ++++++++++++++++++++++++--
1 file changed, 24 insertions(+), 2 deletions(-)
diff --git a/xbmc/music/windows/GUIWindowMusicNav.cpp b/xbmc/music/windows/GUIWindowMusicNav.cpp
index 74c7e34..33a753f 100644
--- a/xbmc/music/windows/GUIWindowMusicNav.cpp
+++ b/xbmc/music/windows/GUIWindowMusicNav.cpp
@@ -309,8 +309,25 @@ bool CGUIWindowMusicNav::GetDirectory(const CStdString &strDirectory, CFileItemL
{
CVideoDatabaseDirectory dir;
VIDEODATABASEDIRECTORY::NODE_TYPE node = dir.GetDirectoryChildType(strDirectory);
- if (node == VIDEODATABASEDIRECTORY::NODE_TYPE_TITLE_MUSICVIDEOS)
+ if (node == VIDEODATABASEDIRECTORY::NODE_TYPE_TITLE_MUSICVIDEOS ||
+ node == VIDEODATABASEDIRECTORY::NODE_TYPE_RECENTLY_ADDED_MUSICVIDEOS)
items.SetContent("musicvideos");
+ else if (node == VIDEODATABASEDIRECTORY::NODE_TYPE_GENRE)
+ items.SetContent("genres");
+ else if (node == VIDEODATABASEDIRECTORY::NODE_TYPE_COUNTRY)
+ items.SetContent("countries");
+ else if (node == VIDEODATABASEDIRECTORY::NODE_TYPE_ACTOR)
+ items.SetContent("artists");
+ else if (node == VIDEODATABASEDIRECTORY::NODE_TYPE_DIRECTOR)
+ items.SetContent("directors");
+ else if (node == VIDEODATABASEDIRECTORY::NODE_TYPE_STUDIO)
+ items.SetContent("studios");
+ else if (node == VIDEODATABASEDIRECTORY::NODE_TYPE_YEAR)
+ items.SetContent("years");
+ else if (node == VIDEODATABASEDIRECTORY::NODE_TYPE_MUSICVIDEOS_ALBUM)
+ items.SetContent("albums");
+ else if (node == VIDEODATABASEDIRECTORY::NODE_TYPE_TAGS)
+ items.SetContent("tags");
}
else if (StringUtils::StartsWithNoCase(strDirectory, "musicdb://"))
{
@@ -327,7 +344,12 @@ bool CGUIWindowMusicNav::GetDirectory(const CStdString &strDirectory, CFileItemL
items.SetContent("artists");
else if (node == NODE_TYPE_SONG ||
node == NODE_TYPE_SONG_TOP100 ||
- node == NODE_TYPE_SINGLES)
+ node == NODE_TYPE_SINGLES ||
+ node == NODE_TYPE_ALBUM_RECENTLY_ADDED_SONGS ||
+ node == NODE_TYPE_ALBUM_RECENTLY_PLAYED_SONGS ||
+ node == NODE_TYPE_ALBUM_COMPILATIONS_SONGS ||
+ node == NODE_TYPE_ALBUM_TOP100_SONGS ||
+ node == NODE_TYPE_YEAR_SONG)
items.SetContent("songs");
else if (node == NODE_TYPE_GENRE)
items.SetContent("genres");
--
1.8.5.5