fixed empty vps string

This commit is contained in:
louis 2014-10-15 18:10:34 +02:00
parent 8b8389d975
commit 6b16f46272

View File

@ -126,7 +126,10 @@ void cDisplayMenuDetailView::SetTokens(void) {
intTokens.insert(pair<string,int>("duration", event->Duration() / 60));
intTokens.insert(pair<string,int>("durationhours", event->Duration() / 3600));
stringTokens.insert(pair<string,string>("durationminutes", *cString::sprintf("%.2d", (event->Duration() / 60)%60)));
stringTokens.insert(pair<string,string>("vps", *event->GetVpsString()));
if (event->Vps())
stringTokens.insert(pair<string,string>("vps", *event->GetVpsString()));
else
stringTokens.insert(pair<string,string>("vps", ""));
vector< map< string, string > > reruns;
bool hasReruns = LoadReruns(&reruns);
@ -852,7 +855,10 @@ void cDisplayMenuDetailView::DrawHeader(void) {
headerIntTokens.insert(pair<string,int>("duration", event->Duration() / 60));
headerIntTokens.insert(pair<string,int>("durationhours", event->Duration() / 3600));
headerStringTokens.insert(pair<string,string>("durationminutes", *cString::sprintf("%.2d", (event->Duration() / 60)%60)));
headerStringTokens.insert(pair<string,string>("vps", *event->GetVpsString()));
if (event->Vps())
headerStringTokens.insert(pair<string,string>("vps", *event->GetVpsString()));
else
headerStringTokens.insert(pair<string,string>("vps", ""));
stringstream epgImageName;
epgImageName << event->EventID();