Permalink
Browse files

Merge pull request #2324 from ulion/fix_empty_music_title_in_announce

Fix empty music title announce.
  • Loading branch information...
2 parents 3a4d16f + b6d1ee2 commit 40c1fc91e5f5e00f1f9de7ea549f9233e7d98b76 @ulion ulion committed Mar 1, 2013
Showing with 4 additions and 1 deletion.
  1. +4 −1 xbmc/interfaces/AnnouncementManager.cpp
@@ -190,7 +190,10 @@ void CAnnouncementManager::Announce(AnnouncementFlag flag, const char *sender, c
// TODO: Can be removed once this is properly handled when starting playback of a file
item->SetProperty(LOOKUP_PROPERTY, false);
- object["item"]["title"] = item->GetMusicInfoTag()->GetTitle();
+ CStdString title = item->GetMusicInfoTag()->GetTitle();
+ if (title.IsEmpty())
+ title = item->GetLabel();
+ object["item"]["title"] = title;
if (item->GetMusicInfoTag()->GetTrackNumber() > 0)
object["item"]["track"] = item->GetMusicInfoTag()->GetTrackNumber();

0 comments on commit 40c1fc9

Please sign in to comment.