diff options
-rw-r--r-- | HISTORY | 2 | ||||
-rw-r--r-- | config.c | 2 | ||||
-rw-r--r-- | geometrymanager.c | 9 | ||||
-rw-r--r-- | geometrymanager.h | 2 | ||||
-rw-r--r-- | imagecache.c | 4 | ||||
-rw-r--r-- | po/ca_ES.po | 14 | ||||
-rw-r--r-- | po/de_DE.po | 14 | ||||
-rw-r--r-- | po/it_IT.po | 14 | ||||
-rw-r--r-- | po/sk_SK.po | 14 | ||||
-rw-r--r-- | setup.c | 2 | ||||
-rw-r--r-- | timers.c | 10 |
11 files changed, 47 insertions, 40 deletions
@@ -350,3 +350,5 @@ Version 0.1.4 in schedules menu - changed build environment that every class is build seperately (thanks @Helmut Auer) +- changed channel logos in main menu timers display to scale + automatically @@ -102,8 +102,6 @@ void cNopacityConfig::LoadDefaults(void) { conf.insert(std::pair<std::string, int>("numRecordingsMenuItems", 10)); conf.insert(std::pair<std::string, int>("menuHeaderLogoWidth", 160)); conf.insert(std::pair<std::string, int>("menuHeaderLogoHeight", 70)); - conf.insert(std::pair<std::string, int>("timersLogoWidth", 90)); - conf.insert(std::pair<std::string, int>("timersLogoHeight", 70)); conf.insert(std::pair<std::string, int>("epgImageWidth", 210)); conf.insert(std::pair<std::string, int>("epgImageHeight", 160)); conf.insert(std::pair<std::string, int>("epgImageWidthLarge", 525)); diff --git a/geometrymanager.c b/geometrymanager.c index 976d328..776632f 100644 --- a/geometrymanager.c +++ b/geometrymanager.c @@ -85,7 +85,7 @@ void cGeometryManager::SetDisplayMenuSizes() { config.GetValue("logoHeightOriginal")); menuLogoWidth = logoSize.Width(); menuLogoHeight = logoSize.Height(); - + cSize logoSizeVDRHeader = ScaleToFit(1000, menuHeaderHeight - 4, config.GetValue("menuHeaderLogoWidth"), @@ -98,6 +98,13 @@ void cGeometryManager::SetDisplayMenuSizes() { menuDiskUsageWidth = menuDiskUsageHeight = osdWidth * config.GetValue("menuSizeDiskUsage") / 100; menuTimersWidth = osdWidth * config.GetValue("menuWidthRightItems") / 100; + cSize timersLogoSize = ScaleToFit(menuTimersWidth - 8 * config.GetValue("spaceMenu"), + 1000, + config.GetValue("logoWidthOriginal"), + config.GetValue("logoHeightOriginal")); + menuTimersLogoWidth = timersLogoSize.Width(); + menuTimersLogoHeight = timersLogoSize.Height(); + menuMessageWidth = 0.8 * osdWidth; menuMessageHeight = 0.1 * osdHeight; } diff --git a/geometrymanager.h b/geometrymanager.h index f9e2166..3c4cf28 100644 --- a/geometrymanager.h +++ b/geometrymanager.h @@ -53,6 +53,8 @@ class cGeometryManager { int menuMainMenuIconSize; int menuLogoWidth; int menuLogoHeight; + int menuTimersLogoWidth; + int menuTimersLogoHeight; int menuHeaderVDRLogoWidth; int menuButtonsBorder; int menuButtonWidth; diff --git a/imagecache.c b/imagecache.c index ee59d49..9162d7d 100644 --- a/imagecache.c +++ b/imagecache.c @@ -401,8 +401,8 @@ cPoint cImageCache::LogoSize(eCacheType type) { height = geoManager->menuLogoHeight; break; case ctLogoTimer: - width = config.GetValue("timersLogoWidth"); - height = config.GetValue("timersLogoHeight"); + width = geoManager->menuTimersLogoWidth; + height = geoManager->menuTimersLogoHeight; break; default: width = 1; diff --git a/po/ca_ES.po b/po/ca_ES.po index 44fd27c..4eabef5 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-11-03 14:34+0100\n" +"POT-Creation-Date: 2013-11-07 17:08+0100\n" "PO-Revision-Date: 2013-03-19 22:56+0100\n" "Last-Translator: Gabychan <gbonich@gmail.com>\n" "Language-Team: \n" @@ -266,12 +266,6 @@ msgstr "Nombre mà xim de timers" msgid "Width of Timers (Percent of OSD Width)" msgstr "Amplada dels timers (% amplada OSD)" -msgid "Channel Logo Width" -msgstr "Amplada logo canal" - -msgid "Channel Logo Height" -msgstr "Alçada logo canal" - msgid "Adjust Font Size - Title" msgstr "Ajusta mida de la Font - TÃtol" @@ -557,6 +551,12 @@ msgstr "conflicte" msgid "conflicts" msgstr "conflictes" +#~ msgid "Channel Logo Width" +#~ msgstr "Amplada logo canal" + +#~ msgid "Channel Logo Height" +#~ msgstr "Alçada logo canal" + #~ msgid "Header Icon Size (Square Header Menu Icons)" #~ msgstr "Mida icona capçalera (Icones del Quadre)" diff --git a/po/de_DE.po b/po/de_DE.po index 477f972..4fe3823 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-11-03 14:34+0100\n" +"POT-Creation-Date: 2013-11-07 17:08+0100\n" "PO-Revision-Date: 2012-11-11 17:49+0200\n" "Last-Translator: louis\n" "Language-Team: \n" @@ -263,12 +263,6 @@ msgstr "Maximale Timer Anzahl" msgid "Width of Timers (Percent of OSD Width)" msgstr "Breite der Timer (% der OSD Breite)" -msgid "Channel Logo Width" -msgstr "Breite der Kanallogos" - -msgid "Channel Logo Height" -msgstr "Höhe der Kanallogos" - msgid "Adjust Font Size - Title" msgstr "Schriftgröße anpassen - Titel" @@ -554,6 +548,12 @@ msgstr "Konflikt" msgid "conflicts" msgstr "Konflikte" +#~ msgid "Channel Logo Width" +#~ msgstr "Breite der Kanallogos" + +#~ msgid "Channel Logo Height" +#~ msgstr "Höhe der Kanallogos" + #~ msgid "Header Icon Size (Square Header Menu Icons)" #~ msgstr "Größe der quadratischen Headericons" diff --git a/po/it_IT.po b/po/it_IT.po index cb8910d..b5bcdbc 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-11-03 14:34+0100\n" +"POT-Creation-Date: 2013-11-07 17:08+0100\n" "PO-Revision-Date: 2013-03-19 22:56+0100\n" "Last-Translator: Diego Pierotto <vdr-italian@tiscali.it>\n" "Language-Team: \n" @@ -266,12 +266,6 @@ msgstr "" msgid "Width of Timers (Percent of OSD Width)" msgstr "Larghezza di Timer (% larghezza OSD)" -msgid "Channel Logo Width" -msgstr "Larghezza logo canale" - -msgid "Channel Logo Height" -msgstr "Altezza logo canale" - msgid "Adjust Font Size - Title" msgstr "Adatta dim. caratteri - Titolo" @@ -557,6 +551,12 @@ msgstr "conflitto" msgid "conflicts" msgstr "conflitti" +#~ msgid "Channel Logo Width" +#~ msgstr "Larghezza logo canale" + +#~ msgid "Channel Logo Height" +#~ msgstr "Altezza logo canale" + #~ msgid "Header Icon Size (Square Header Menu Icons)" #~ msgstr "Dim. icona intestazione (icone menu intestazione quadrato)" diff --git a/po/sk_SK.po b/po/sk_SK.po index 0b7b195..aa7b225 100644 --- a/po/sk_SK.po +++ b/po/sk_SK.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: vdr-skinnopacity\n" "Report-Msgid-Bugs-To: <see README>\n" -"POT-Creation-Date: 2013-11-03 14:34+0100\n" +"POT-Creation-Date: 2013-11-07 17:08+0100\n" "PO-Revision-Date: 2013-09-16 19:34+0100\n" "Last-Translator: Milan Hrala <hrala.milan@gmail.com>\n" "Language-Team: \n" @@ -263,12 +263,6 @@ msgstr "Maximálny poèet zobrazených plánov" msgid "Width of Timers (Percent of OSD Width)" msgstr "©írka zobrazeného plánu nahrávania (Percento s OSD ¹írky)" -msgid "Channel Logo Width" -msgstr "©írka loga kanálu" - -msgid "Channel Logo Height" -msgstr "Vý¹ka loga kanálu" - msgid "Adjust Font Size - Title" msgstr "Nastavenie veµkosti písma - Názov" @@ -554,6 +548,12 @@ msgstr "konflikt" msgid "conflicts" msgstr "konflikty" +#~ msgid "Channel Logo Width" +#~ msgstr "©írka loga kanálu" + +#~ msgid "Channel Logo Height" +#~ msgstr "Vý¹ka loga kanálu" + #~ msgid "Header Icon Size (Square Header Menu Icons)" #~ msgstr "Veµkos» ikony hlavièky (ikona hlavièky do ¹tvorca)" @@ -205,8 +205,6 @@ void cNopacitySetupMenuDisplayMain::Set(void) { if (tmpConf->GetValue("showTimers")) { Add(new cMenuEditIntItem(cString::sprintf("%s%s", *spacer, tr("Maximum number of Timers")), tmpConf->GetValueRef("numberTimers"), 1, 10)); Add(new cMenuEditIntItem(cString::sprintf("%s%s", *spacer, tr("Width of Timers (Percent of OSD Width)")), tmpConf->GetValueRef("menuWidthRightItems"), 5, 30)); - Add(new cMenuEditIntItem(cString::sprintf("%s%s", *spacer, tr("Channel Logo Width")), tmpConf->GetValueRef("timersLogoWidth"), 30, 300)); - Add(new cMenuEditIntItem(cString::sprintf("%s%s", *spacer, tr("Channel Logo Height")), tmpConf->GetValueRef("timersLogoHeight"), 30, 300)); Add(new cMenuEditIntItem(cString::sprintf("%s%s", *spacer, tr("Adjust Font Size - Header")), tmpConf->GetValueRef("fontTimersHead"), -20, 20)); Add(new cMenuEditIntItem(cString::sprintf("%s%s", *spacer, tr("Adjust Font Size - Title")), tmpConf->GetValueRef("fontTimers"), -20, 20)); } @@ -111,7 +111,7 @@ void cNopacityTimer::CalculateHeight(int space) { height = numLines * lineHeight + 2*space; } else { int lineHeight = font->Height(); - height = config.GetValue("timersLogoHeight") + (numLines +1)* lineHeight + 2*space; + height = geoManager->menuTimersLogoHeight + (numLines +1)* lineHeight + 2*space; } } @@ -164,10 +164,10 @@ void cNopacityTimer::Render(void) { } } - pixmapText->DrawText(cPoint(5, config.GetValue("timersLogoHeight")), *Date, Theme.Color(clrMenuFontTimersHeader), clrTransparent, fontLarge); + pixmapText->DrawText(cPoint(5, geoManager->menuTimersLogoHeight), *Date, Theme.Color(clrMenuFontTimersHeader), clrTransparent, fontLarge); int lineHeight = font->Height(); - int yStart = config.GetValue("timersLogoHeight") + lineHeight + 3; + int yStart = geoManager->menuTimersLogoHeight + lineHeight + 3; int numLines = showName.Lines(); for (int line=0; line<numLines; line++) pixmapText->DrawText(cPoint(5, yStart+line*(lineHeight-2)), showName.GetLine(line), Theme.Color(clrMenuFontTimers), clrTransparent, font); @@ -177,8 +177,8 @@ void cNopacityTimer::Render(void) { void cNopacityTimer::DrawLogo(void) { pixmapLogo->Fill(clrTransparent); int showTimerLogo = (config.GetValue("showTimers") < 2) ? 1 : 0; - int logoWidth = config.GetValue("timersLogoWidth"); - int logoHeight = config.GetValue("timersLogoHeight"); + int logoWidth = geoManager->menuTimersLogoWidth; + int logoHeight = geoManager->menuTimersLogoHeight; const cChannel *Channel = timer->Channel(); if (Channel) { bool logoFound = false; |