diff options
-rw-r--r-- | HISTORY | 1 | ||||
-rw-r--r-- | displaychannel.c | 12 | ||||
-rw-r--r-- | displaychannelview.c | 9 | ||||
-rw-r--r-- | displaychannelview.h | 1 |
4 files changed, 22 insertions, 1 deletions
@@ -335,3 +335,4 @@ Version 0.1.4 displaychannel - Added background with dedicated theme color for channel logos in menus - Improved Display of Poster or Banner in displaychannel +- implemented cDisplayChannel::SetMessage() diff --git a/displaychannel.c b/displaychannel.c index ed3d011..0f4b8a8 100644 --- a/displaychannel.c +++ b/displaychannel.c @@ -123,6 +123,15 @@ void cNopacityDisplayChannel::SetProgressBar(const cEvent *present) { void cNopacityDisplayChannel::SetMessage(eMessageType Type, const char *Text) { + channelView->ClearChannelLogo(); + channelView->ClearChannelName(); + channelView->ClearEPGInfo(); + channelView->ClearStatusIcons(); + channelView->ClearSourceInfo(); + channelView->ClearProgressBar(); + channelView->HideSignalMeter(); + channelView->DisplayMessage(Text); + groupSep = true; } void cNopacityDisplayChannel::Flush(void) { @@ -133,7 +142,8 @@ void cNopacityDisplayChannel::Flush(void) { if (present) { SetProgressBar(present); - } + } else + channelView->ClearProgressBar(); if (!groupSep) channelView->DrawScreenResolution(); diff --git a/displaychannelview.c b/displaychannelview.c index 96eddaa..a343d06 100644 --- a/displaychannelview.c +++ b/displaychannelview.c @@ -784,4 +784,13 @@ void cNopacityDisplayChannelView::DrawSourceInfo(const cChannel *Channel) { void cNopacityDisplayChannelView::ClearSourceInfo(void) { pixmapSourceInfo->Fill(clrTransparent); +} + +void cNopacityDisplayChannelView::DisplayMessage(const char *Text) { + if (!Text) + return; + int textWidth = fontManager->channelEPG->Width(Text); + int x = (geoManager->channelContentWidth - textWidth)/2; + int y = (geoManager->channelEpgInfoHeight - fontManager->channelEPG->Height())/2; + pixmapEPGInfo->DrawText(cPoint(x, y), Text, Theme.Color(clrChannelEPG), clrTransparent, fontManager->channelEPG); }
\ No newline at end of file diff --git a/displaychannelview.h b/displaychannelview.h index 69a66d8..c4ce1a6 100644 --- a/displaychannelview.h +++ b/displaychannelview.h @@ -61,6 +61,7 @@ public: void DrawChannelGroups(const cChannel *Channel, cString ChannelName); void DrawSourceInfo(const cChannel *Channel); void ClearSourceInfo(void); + void DisplayMessage(const char *Text); void Flush(void) { osd->Flush(); }; }; #endif //__NOPACITY_DISPLAYCHANNELVIEW_H
\ No newline at end of file |