diff options
-rw-r--r-- | HISTORY | 2 | ||||
-rw-r--r-- | config.c | 2 | ||||
-rw-r--r-- | config.h | 1 | ||||
-rw-r--r-- | menuitem.c | 51 | ||||
-rw-r--r-- | po/ca_ES.po | 8 | ||||
-rw-r--r-- | po/de_DE.po | 8 | ||||
-rw-r--r-- | po/it_IT.po | 8 | ||||
-rw-r--r-- | po/sk_SK.po | 8 | ||||
-rw-r--r-- | setup.c | 7 | ||||
-rw-r--r-- | setup.h | 2 |
10 files changed, 85 insertions, 12 deletions
@@ -237,3 +237,5 @@ Version 0.1.4 - Added Deadlock Patch - Changed default Channelseparator Icon (closes Bug 1412) - Display correct recording date even if recording info is empty (closes Bug 1448) +- Added option to display plain channels and EPG information without time in + channels menu (closes Feature 1377) @@ -84,6 +84,7 @@ cNopacityConfig::cNopacityConfig() { displayAdditionalRecEPGPictures = 1; numAdditionalRecEPGPictures = 9; menuChannelDisplayMode = 0; + menuChannelDisplayTime = 1; numEPGEntriesChannelsMenu = 15; menuFadeTime = 0; menuEPGWindowFadeTime = 300; @@ -371,6 +372,7 @@ bool cNopacityConfig::SetupParse(const char *Name, const char *Value) { else if (strcmp(Name, "displayAdditionalRecEPGPictures") == 0) displayAdditionalRecEPGPictures = atoi(Value); else if (strcmp(Name, "numAdditionalRecEPGPictures") == 0) numAdditionalRecEPGPictures = atoi(Value); else if (strcmp(Name, "menuChannelDisplayMode") == 0) menuChannelDisplayMode = atoi(Value); + else if (strcmp(Name, "menuChannelDisplayTime") == 0) menuChannelDisplayTime= atoi(Value); else if (strcmp(Name, "numEPGEntriesChannelsMenu") == 0) numEPGEntriesChannelsMenu = atoi(Value); else if (strcmp(Name, "menuWidthMain") == 0) menuWidthMain = atoi(Value); else if (strcmp(Name, "menuWidthSchedules") == 0) menuWidthSchedules = atoi(Value); @@ -113,6 +113,7 @@ class cNopacityConfig { int displayAdditionalRecEPGPictures; int numAdditionalRecEPGPictures; int menuChannelDisplayMode; + int menuChannelDisplayTime; int numEPGEntriesChannelsMenu; int menuFadeTime; int menuEPGWindowFadeTime; @@ -563,6 +563,13 @@ void cNopacityScheduleMenuItem::DrawRemaining(int x, int y, int width) { cNopacityChannelMenuItem::cNopacityChannelMenuItem(cOsd *osd, const cChannel *Channel, bool sel, cRect *vidWin) : cNopacityMenuItem (osd, "", sel) { this->Channel = Channel; this->vidWin = vidWin; + strEntry = ""; + strEntryFull = ""; + strChannelSource = ""; + strChannelInfo = ""; + strEpgInfo = ""; + strEpgInfoFull = ""; + strTimeInfo = ""; } cNopacityChannelMenuItem::~cNopacityChannelMenuItem(void) { @@ -617,20 +624,52 @@ int cNopacityChannelMenuItem::CheckScrollable(bool hasIcon) { void cNopacityChannelMenuItem::SetTextFull(void) { tColor clrFont = (current)?Theme.Color(clrMenuFontMenuItemHigh):Theme.Color(clrMenuFontMenuItem); pixmapTextScroller->Fill(clrTransparent); - pixmapTextScroller->DrawText(cPoint(5, (height/2 - font->Height())/2), strEntryFull.c_str(), clrFont, clrTransparent, font); + int heightChannelName = 0; + if (config.menuChannelDisplayMode == 2) { + heightChannelName = (height - font->Height())/2; + } else { + heightChannelName = (height/2 - font->Height())/2; + } + pixmapTextScroller->DrawText(cPoint(5, heightChannelName), strEntryFull.c_str(), clrFont, clrTransparent, font); if (config.menuChannelDisplayMode == 1) { - pixmapTextScroller->DrawText(cPoint(5, height/2 + (height/4 - fontSmall->Height())/2), strTimeInfo.c_str(), clrFont, clrTransparent, fontSmall); - pixmapTextScroller->DrawText(cPoint(5, 3*height/4 + (height/4 - fontSmall->Height())/2), strEpgInfoFull.c_str(), clrFont, clrTransparent, fontSmall); + int heightTimeInfo = 0; + int heightEPGInfo = 0; + if (config.menuChannelDisplayTime) { + heightTimeInfo = height/2 + (height/4 - fontSmall->Height())/2; + heightEPGInfo = 3*height/4 + (height/4 - fontSmall->Height())/2; + } else { + heightEPGInfo = height/2 + (height/4 - fontSmall->Height())/2; + } + if (config.menuChannelDisplayTime) { + pixmapTextScroller->DrawText(cPoint(5, heightTimeInfo), strTimeInfo.c_str(), clrFont, clrTransparent, fontSmall); + } + pixmapTextScroller->DrawText(cPoint(5, heightEPGInfo), strEpgInfoFull.c_str(), clrFont, clrTransparent, fontSmall); } } void cNopacityChannelMenuItem::SetTextShort(void) { tColor clrFont = (current)?Theme.Color(clrMenuFontMenuItemHigh):Theme.Color(clrMenuFontMenuItem); pixmapTextScroller->Fill(clrTransparent); - pixmapTextScroller->DrawText(cPoint(5, (height/2 - font->Height())/2), strEntry.c_str(), clrFont, clrTransparent, font); + int heightChannelName = 0; + if (config.menuChannelDisplayMode == 2) { + heightChannelName = (height - font->Height())/2; + } else { + heightChannelName = (height/2 - font->Height())/2; + } + pixmapTextScroller->DrawText(cPoint(5, heightChannelName), strEntry.c_str(), clrFont, clrTransparent, font); if (config.menuChannelDisplayMode == 1) { - pixmapTextScroller->DrawText(cPoint(5, height/2 + (height/4 - fontSmall->Height())/2), strTimeInfo.c_str(), clrFont, clrTransparent, fontSmall); - pixmapTextScroller->DrawText(cPoint(5, 3*height/4 + (height/4 - fontSmall->Height())/2), strEpgInfo.c_str(), clrFont, clrTransparent, fontSmall); + int heightTimeInfo = 0; + int heightEPGInfo = 0; + if (config.menuChannelDisplayTime) { + heightTimeInfo = height/2 + (height/4 - fontSmall->Height())/2; + heightEPGInfo = 3*height/4 + (height/4 - fontSmall->Height())/2; + } else { + heightEPGInfo = height/2 + (height/4 - fontSmall->Height())/2; + } + if (config.menuChannelDisplayTime) { + pixmapTextScroller->DrawText(cPoint(5, heightTimeInfo), strTimeInfo.c_str(), clrFont, clrTransparent, fontSmall); + } + pixmapTextScroller->DrawText(cPoint(5, heightEPGInfo), strEpgInfo.c_str(), clrFont, clrTransparent, fontSmall); } } diff --git a/po/ca_ES.po b/po/ca_ES.po index a3752f5..ff6bb11 100644 --- a/po/ca_ES.po +++ b/po/ca_ES.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: skinnopacity 0.0.1\n" "Report-Msgid-Bugs-To: <see README>\n" -"POT-Creation-Date: 2013-08-25 17:54+0200\n" +"POT-Creation-Date: 2013-09-09 17:06+0200\n" "PO-Revision-Date: 2013-03-19 22:56+0100\n" "Last-Translator: Gabychan <gbonich@gmail.com>\n" "Language-Team: \n" @@ -347,9 +347,15 @@ msgstr "Informació Transponedor" msgid "Current Schedule" msgstr "Programació actual" +msgid "Plain Channels" +msgstr "" + msgid "Menu Items display mode" msgstr "Mode visualització Elements de menú" +msgid "Display schedules with time info" +msgstr "" + msgid "Number of EPG Entries in Schedules Info Window" msgstr "Nombre d'entrades EPG a la Finestra de Programació" diff --git a/po/de_DE.po b/po/de_DE.po index bb56e54..7726b4e 100644 --- a/po/de_DE.po +++ b/po/de_DE.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: skinnopacity 0.0.1\n" "Report-Msgid-Bugs-To: <see README>\n" -"POT-Creation-Date: 2013-08-24 09:40+0200\n" +"POT-Creation-Date: 2013-09-09 17:06+0200\n" "PO-Revision-Date: 2012-11-11 17:49+0200\n" "Last-Translator: louis\n" "Language-Team: \n" @@ -344,9 +344,15 @@ msgstr "Transponder Information" msgid "Current Schedule" msgstr "Aktuelles Programm" +msgid "Plain Channels" +msgstr "Nur Kanäle" + msgid "Menu Items display mode" msgstr "Anzeigemodus Menüelemente" +msgid "Display schedules with time info" +msgstr "Programm mit Zeitinformation anzeigen" + msgid "Number of EPG Entries in Schedules Info Window" msgstr "Anzahl der EPG Einträge im Programm Info Fenster" diff --git a/po/it_IT.po b/po/it_IT.po index abd87ed..4231b93 100644 --- a/po/it_IT.po +++ b/po/it_IT.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: skinnopacity 0.0.1\n" "Report-Msgid-Bugs-To: <see README>\n" -"POT-Creation-Date: 2013-08-24 09:40+0200\n" +"POT-Creation-Date: 2013-09-09 17:06+0200\n" "PO-Revision-Date: 2013-03-19 22:56+0100\n" "Last-Translator: Diego Pierotto <vdr-italian@tiscali.it>\n" "Language-Team: \n" @@ -347,9 +347,15 @@ msgstr "" msgid "Current Schedule" msgstr "" +msgid "Plain Channels" +msgstr "" + msgid "Menu Items display mode" msgstr "" +msgid "Display schedules with time info" +msgstr "" + msgid "Number of EPG Entries in Schedules Info Window" msgstr "" diff --git a/po/sk_SK.po b/po/sk_SK.po index 5e98449..66c21ee 100644 --- a/po/sk_SK.po +++ b/po/sk_SK.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: vdr-skinnopacity 0.0.6\n" "Report-Msgid-Bugs-To: <see README>\n" -"POT-Creation-Date: 2013-08-24 09:40+0200\n" +"POT-Creation-Date: 2013-09-09 17:06+0200\n" "PO-Revision-Date: 2013-03-12 15:59+0100\n" "Last-Translator: Milan Hrala <hrala.milan@gmail.com>\n" "Language-Team: \n" @@ -347,9 +347,15 @@ msgstr "" msgid "Current Schedule" msgstr "" +msgid "Plain Channels" +msgstr "" + msgid "Menu Items display mode" msgstr "" +msgid "Display schedules with time info" +msgstr "" + msgid "Number of EPG Entries in Schedules Info Window" msgstr "" @@ -139,6 +139,7 @@ void cNopacitySetup::Store(void) { SetupStore("displayAdditionalRecEPGPictures", config.displayAdditionalRecEPGPictures); SetupStore("numAdditionalRecEPGPictures", config.numAdditionalRecEPGPictures); SetupStore("menuChannelDisplayMode", config.menuChannelDisplayMode); + SetupStore("menuChannelDisplayTime", config.menuChannelDisplayTime); SetupStore("numEPGEntriesChannelsMenu", config.numEPGEntriesChannelsMenu); SetupStore("menuFadeTime", config.menuFadeTime); SetupStore("menuScrollDelay", config.menuScrollDelay); @@ -397,6 +398,7 @@ void cNopacitySetupMenuDisplaySchedules::Set(void) { cNopacitySetupMenuDisplayChannels::cNopacitySetupMenuDisplayChannels(cNopacityConfig* data) : cMenuSetupSubMenu(tr("VDR Menu: Channels Menu"), data) { displayModes[0] = tr("Transponder Information"); displayModes[1] = tr("Current Schedule"); + displayModes[2] = tr("Plain Channels"); Set(); } @@ -407,7 +409,10 @@ void cNopacitySetupMenuDisplayChannels::Set(void) { Add(new cMenuEditBoolItem(tr("Use narrow menu"), &tmpNopacityConfig->narrowChannelMenu)); if (tmpNopacityConfig->narrowChannelMenu) Add(new cMenuEditIntItem(cString::sprintf("%s%s", *spacer, tr("Width (Percent of OSD Width)")), &tmpNopacityConfig->menuWidthChannels, 10, 97)); - Add(new cMenuEditStraItem(tr("Menu Items display mode"), &tmpNopacityConfig->menuChannelDisplayMode, 2, displayModes)); + Add(new cMenuEditStraItem(tr("Menu Items display mode"), &tmpNopacityConfig->menuChannelDisplayMode, 3, displayModes)); + if (tmpNopacityConfig->menuChannelDisplayMode == 1) { + Add(new cMenuEditBoolItem(cString::sprintf("%s%s", *spacer, tr("Display schedules with time info")), &tmpNopacityConfig->menuChannelDisplayTime)); + } Add(new cMenuEditIntItem(tr("Number of EPG Entries in Schedules Info Window"), &tmpNopacityConfig->numEPGEntriesChannelsMenu, 1, 100)); Add(new cMenuEditIntItem(tr("Adjust Font Size - Menu Item"), &tmpNopacityConfig->fontMenuitemChannel, -20, 20)); Add(new cMenuEditIntItem(tr("Adjust Font Size - Menu Item Small"), &tmpNopacityConfig->fontMenuitemChannelSmall, -20, 20)); @@ -58,7 +58,7 @@ class cNopacitySetupMenuDisplaySchedules : public cMenuSetupSubMenu { class cNopacitySetupMenuDisplayChannels : public cMenuSetupSubMenu { protected: - const char *displayModes[2]; + const char *displayModes[3]; void Set(void); public: cNopacitySetupMenuDisplayChannels(cNopacityConfig *data); |