summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--menu.c2
-rw-r--r--po/de_DE.po23
-rw-r--r--po/fi_FI.po23
-rw-r--r--po/it_IT.po23
-rw-r--r--screen.c119
-rw-r--r--screen.h3
-rw-r--r--setup.c4
-rw-r--r--setup.h1
8 files changed, 129 insertions, 69 deletions
diff --git a/menu.c b/menu.c
index ecd3d62..66566f9 100644
--- a/menu.c
+++ b/menu.c
@@ -25,6 +25,7 @@ void cText2SkinSetupPage::Setup(void) {
Add(new cMenuEditBoolItem(tr("Use 'epgsearch' to check timer-conflicts"), &mData.CheckTimerConflict));
Add(new cOsdItem(tr("Flush image cache"), osUser1));
Add(new cMenuEditIntItem(tr("Max. image cache size"), &mData.MaxCacheFill, 1));
+ Add(new cMenuEditBoolItem(tr("Old Skin compatibility (<1.0)"), &mData.SupportOldSkins, tr("no"), tr("yes")));
SetCurrent(Get(current));
Display();
@@ -41,6 +42,7 @@ void cText2SkinSetupPage::Store(void) {
SetupStore("StripAux", mData.StripAux);
SetupStore("CheckTimerConflict", mData.CheckTimerConflict);
SetupStore("MaxCacheFill", mData.MaxCacheFill);
+ SetupStore("SupportOldSkins", mData.SupportOldSkins);
Text2SkinSetup = mData;
}
diff --git a/po/de_DE.po b/po/de_DE.po
index 5372a8b..662e4f1 100644
--- a/po/de_DE.po
+++ b/po/de_DE.po
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: vdr-text2skin 1.3\n"
"Report-Msgid-Bugs-To: http://projects.vdr-developer.org/projects/show/plg-text2skin\n"
-"POT-Creation-Date: 2011-10-22 15:13+0300\n"
+"POT-Creation-Date: 2012-04-23 20:50+0200\n"
"PO-Revision-Date: 2009-06-07 12:12+0200\n"
"Last-Translator: Andreas Brugger <brougs78@gmx.net>\n"
"Language-Team: German <vdr@linuxtv.org>\n"
@@ -17,12 +17,6 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-msgid "Loader for text-based skins"
-msgstr "Lader für textbasierte Skins"
-
-msgid "Skin too large or incorrectly aligned"
-msgstr "Skin zu groß oder nicht korrekt ausgerichtet"
-
msgid "RERUNS OF THIS SHOW"
msgstr "WIEDERHOLUNGEN DIESER SENDUNG"
@@ -32,6 +26,9 @@ msgstr "ZUSATZINFOS"
msgid "Search timer"
msgstr "Suchtimer"
+msgid "Skin too large or incorrectly aligned"
+msgstr "Skin zu groß oder nicht korrekt ausgerichtet"
+
msgid "Show scrollbar in the menus"
msgstr "Zeige Bildlaufleiste in Menüs"
@@ -63,5 +60,17 @@ msgstr "Bildspeicher leeren"
msgid "Max. image cache size"
msgstr "Max. Größe des Bildspeichers"
+msgid "Old Skin compatibility (<1.0)"
+msgstr "Unterstützung alter Skins (<1.0)"
+
+msgid "no"
+msgstr "nein"
+
+msgid "yes"
+msgstr "ja"
+
msgid "Flushing image cache..."
msgstr "Bildspeicher wird geleert..."
+
+msgid "Loader for text-based skins"
+msgstr "Lader für textbasierte Skins"
diff --git a/po/fi_FI.po b/po/fi_FI.po
index d3f0b72..7e731d1 100644
--- a/po/fi_FI.po
+++ b/po/fi_FI.po
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: vdr-text2skin 1.3\n"
"Report-Msgid-Bugs-To: http://projects.vdr-developer.org/projects/show/plg-text2skin\n"
-"POT-Creation-Date: 2011-10-22 15:13+0300\n"
+"POT-Creation-Date: 2012-04-23 20:50+0200\n"
"PO-Revision-Date: 2011-05-28 15:38+0200\n"
"Last-Translator: Ville Skyttä <ville.skytta@iki.fi>\n"
"Language-Team: Finnish <vdr@linuxtv.org>\n"
@@ -17,12 +17,6 @@ msgstr ""
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
-msgid "Loader for text-based skins"
-msgstr "Helposti muokattavat ulkoasut"
-
-msgid "Skin too large or incorrectly aligned"
-msgstr "Ulkoasu on liian suuri tai väärin asemoitu"
-
msgid "RERUNS OF THIS SHOW"
msgstr "UUSINNAT"
@@ -32,6 +26,9 @@ msgstr "LISÄTIEDOT"
msgid "Search timer"
msgstr "Hakuajastin"
+msgid "Skin too large or incorrectly aligned"
+msgstr "Ulkoasu on liian suuri tai väärin asemoitu"
+
msgid "Show scrollbar in the menus"
msgstr "Näytä vierityspalkki valikoissa"
@@ -63,5 +60,17 @@ msgstr "Tyhjennä kuvat välimuistista"
msgid "Max. image cache size"
msgstr "Välimuistin maksimikoko"
+msgid "Old Skin compatibility (<1.0)"
+msgstr ""
+
+msgid "no"
+msgstr ""
+
+msgid "yes"
+msgstr ""
+
msgid "Flushing image cache..."
msgstr "Tyhjennetään välimuistia..."
+
+msgid "Loader for text-based skins"
+msgstr "Helposti muokattavat ulkoasut"
diff --git a/po/it_IT.po b/po/it_IT.po
index 14ec57c..4b02b2e 100644
--- a/po/it_IT.po
+++ b/po/it_IT.po
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: vdr-text2skin 1.2\n"
"Report-Msgid-Bugs-To: http://projects.vdr-developer.org/projects/show/plg-text2skin\n"
-"POT-Creation-Date: 2011-10-22 15:13+0300\n"
+"POT-Creation-Date: 2012-04-23 20:50+0200\n"
"PO-Revision-Date: 2009-07-15 23:45+0100\n"
"Last-Translator: Diego Pierotto <vdr-italian@tiscali.it>\n"
"Language-Team: Italian <vdr@linuxtv.org>\n"
@@ -19,12 +19,6 @@ msgstr ""
"X-Poedit-Country: ITALY\n"
"X-Poedit-SourceCharset: utf-8\n"
-msgid "Loader for text-based skins"
-msgstr "Gestore di stili interfaccia basati su testo"
-
-msgid "Skin too large or incorrectly aligned"
-msgstr "Interfaccia troppo grande o allineamento incorretto"
-
msgid "RERUNS OF THIS SHOW"
msgstr "REPLICHE DI QUESTO SPETTACOLO"
@@ -34,6 +28,9 @@ msgstr "INFORMAZIONI AUSILIARIE"
msgid "Search timer"
msgstr "Cerca timer"
+msgid "Skin too large or incorrectly aligned"
+msgstr "Interfaccia troppo grande o allineamento incorretto"
+
msgid "Show scrollbar in the menus"
msgstr "Mostra barra scorrimento nei menu"
@@ -65,5 +62,17 @@ msgstr "Svuota cache immagini"
msgid "Max. image cache size"
msgstr "Dim. massima cache immagini"
+msgid "Old Skin compatibility (<1.0)"
+msgstr ""
+
+msgid "no"
+msgstr ""
+
+msgid "yes"
+msgstr ""
+
msgid "Flushing image cache..."
msgstr "Svuotamento cache immagini..."
+
+msgid "Loader for text-based skins"
+msgstr "Gestore di stili interfaccia basati su testo"
diff --git a/screen.c b/screen.c
index 770bed0..0314956 100644
--- a/screen.c
+++ b/screen.c
@@ -26,10 +26,12 @@ eOsdError cText2SkinScreen::SetAreas(const tArea *Areas, int NumAreas)
}
mNumRegions = NumAreas;
-#ifndef DIRECTBLIT
- for (int i = 0; i < mNumRegions; ++i)
- mRegions[i] = new cBitmap(Areas[i].Width(), Areas[i].Height(), Areas[i].bpp, Areas[i].x1, Areas[i].y1);
-#endif
+//#ifndef DIRECTBLIT
+ if (!Text2SkinSetup.SupportOldSkins) {
+ for (int i = 0; i < mNumRegions; ++i)
+ mRegions[i] = new cBitmap(Areas[i].Width(), Areas[i].Height(), Areas[i].bpp, Areas[i].x1, Areas[i].y1);
+ }
+//#endif
Clear();
return oeOk;
@@ -38,74 +40,98 @@ eOsdError cText2SkinScreen::SetAreas(const tArea *Areas, int NumAreas)
void cText2SkinScreen::Clear(void)
{
for (int i = 0; i < mNumRegions; ++i) {
-#ifndef DIRECTBLIT
- mRegions[i]->Reset();
- mRegions[i]->Clean();
- mRegions[i]->DrawRectangle(mRegions[i]->X0(), mRegions[i]->Y0(), mRegions[i]->X0() + mRegions[i]->Width() - 1, mRegions[i]->Y0() + mRegions[i]->Height() - 1, clrTransparent);
-#else
+//#ifndef DIRECTBLIT
+ if (!Text2SkinSetup.SupportOldSkins) {
+ mRegions[i]->Reset();
+ mRegions[i]->Clean();
+ mRegions[i]->DrawRectangle(mRegions[i]->X0(), mRegions[i]->Y0(), mRegions[i]->X0() + mRegions[i]->Width() - 1, mRegions[i]->Y0() + mRegions[i]->Height() - 1, clrTransparent);
+ }
+ else {
+//#else
cBitmap *b = mOsd->GetBitmap(i);
- if (b) {
- b->Reset();
- b->Clean();
- b->DrawRectangle(b->X0(), b->Y0(), b->X0() + b->Width() - 1, b->Y0() + b->Height() - 1, clrTransparent);
+ if (b) {
+ b->Reset();
+ b->Clean();
+ b->DrawRectangle(b->X0(), b->Y0(), b->X0() + b->Width() - 1, b->Y0() + b->Height() - 1, clrTransparent);
+ }
}
-#endif
+//#endif
}
}
void cText2SkinScreen::DrawBitmap(int x, int y, const cBitmap &Bitmap, const tColor *ColorMask)
{
-#ifndef DIRECTBLIT
- for (int i = 0; i < mNumRegions; ++i)
- DrawBitmapOverlay(*mRegions[i], x, y, (cBitmap&)Bitmap, ColorMask);
- //mRegions[i]->DrawBitmap(x, y, Bitmap);
-#else
+//#ifndef DIRECTBLIT
+ if (!Text2SkinSetup.SupportOldSkins) {
+ for (int i = 0; i < mNumRegions; ++i)
+ DrawBitmapOverlay(*mRegions[i], x, y, (cBitmap&)Bitmap, ColorMask);
+ //mRegions[i]->DrawBitmap(x, y, Bitmap);
+ }
+ else {
+//#else
// mOsd->DrawBitmap(x, y, Bitmap, ColorFg, ColorBg);
cBitmap *bm = NULL;
for (int i = 0; (bm = mOsd->GetBitmap(i)) != NULL; ++i)
DrawBitmapOverlay(*bm, x, y, (cBitmap&)Bitmap, ColorMask);
-#endif
+ }
+//#endif
}
void cText2SkinScreen::DrawRectangle(int x1, int y1, int x2, int y2, tColor Color)
{
-#ifndef DIRECTBLIT
- for (int i = 0; i < mNumRegions; ++i)
- mRegions[i]->DrawRectangle(x1, y1, x2, y2, Color);
-#else
+//#ifndef DIRECTBLIT
+ if (!Text2SkinSetup.SupportOldSkins) {
+ for (int i = 0; i < mNumRegions; ++i)
+ mRegions[i]->DrawRectangle(x1, y1, x2, y2, Color);
+ }
+ else {
+//#else
mOsd->DrawRectangle(x1, y1, x2, y2, Color);
-#endif
+ }
+//#endif
}
void cText2SkinScreen::DrawText(int x, int y, const char *s, tColor ColorFg, tColor ColorBg,
const cFont *Font, int Width, int Height, int Alignment)
{
-#ifndef DIRECTBLIT
- for (int i = 0; i < mNumRegions; ++i)
- mRegions[i]->DrawText(x, y, s, ColorFg, ColorBg, Font, Width, Height, Alignment);
-#else
- mOsd->DrawText(x, y, s, ColorFg, ColorBg, Font, Width, Height, Alignment);
-#endif
+//#ifndef DIRECTBLIT
+ if (!Text2SkinSetup.SupportOldSkins) {
+ for (int i = 0; i < mNumRegions; ++i)
+ mRegions[i]->DrawText(x, y, s, ColorFg, ColorBg, Font, Width, Height, Alignment);
+ }
+ else {
+//#else
+ mOsd->DrawText(x, y, s, ColorFg, ColorBg, Font, Width, Height, Alignment);
+ }
+//#endif
}
void cText2SkinScreen::DrawEllipse(int x1, int y1, int x2, int y2, tColor Color, int Quadrants)
{
-#ifndef DIRECTBLIT
- for (int i = 0; i < mNumRegions; ++i)
- mRegions[i]->DrawEllipse(x1, y1, x2, y2, Color, Quadrants);
-#else
- mOsd->DrawEllipse(x1, y1, x2, y2, Color, Quadrants);
-#endif
+//#ifndef DIRECTBLIT
+ if (!Text2SkinSetup.SupportOldSkins) {
+ for (int i = 0; i < mNumRegions; ++i)
+ mRegions[i]->DrawEllipse(x1, y1, x2, y2, Color, Quadrants);
+ }
+ else {
+//#else
+ mOsd->DrawEllipse(x1, y1, x2, y2, Color, Quadrants);
+ }
+//#endif
}
void cText2SkinScreen::DrawSlope(int x1, int y1, int x2, int y2, tColor Color, int Type)
{
-#ifndef DIRECTBLIT
- for (int i = 0; i < mNumRegions; ++i)
- mRegions[i]->DrawSlope(x1, y1, x2, y2, Color, Type);
-#else
- mOsd->DrawSlope(x1, y1, x2, y2, Color, Type);
-#endif
+//#ifndef DIRECTBLIT
+ if (!Text2SkinSetup.SupportOldSkins) {
+ for (int i = 0; i < mNumRegions; ++i)
+ mRegions[i]->DrawSlope(x1, y1, x2, y2, Color, Type);
+ }
+ else {
+//#else
+ mOsd->DrawSlope(x1, y1, x2, y2, Color, Type);
+ }
+//#endif
}
void cText2SkinScreen::Flush(void)
@@ -113,10 +139,11 @@ void cText2SkinScreen::Flush(void)
for (int i = 0; i < mNumRegions; ++i) {
if (mOffScreen)
mScreen->DrawBitmap(mRegions[i]->X0(), mRegions[i]->Y0(), *mRegions[i]);
-#ifndef DIRECTBLIT
- else
+//#ifndef DIRECTBLIT
+// else
+ if (!Text2SkinSetup.SupportOldSkins)
mOsd->DrawBitmap(mRegions[i]->X0(), mRegions[i]->Y0(), *mRegions[i]);
-#endif
+//#endif
}
#ifdef BENCH
int x1 = 0, y1 = 0, x2 = 0, y2 = 0;
diff --git a/screen.h b/screen.h
index 72f0978..efb14ed 100644
--- a/screen.h
+++ b/screen.h
@@ -4,10 +4,11 @@
#define VDR_TEXT2SKIN_SCREEN_H
#include "common.h"
+#include "setup.h"
#include <vdr/osd.h>
// #undef DIRECTBLIT
-#define DIRECTBLIT
+//#define DIRECTBLIT
class cText2SkinScreen {
/* Skin Editor */
diff --git a/setup.c b/setup.c
index d59b7fa..18da5ba 100644
--- a/setup.c
+++ b/setup.c
@@ -13,7 +13,8 @@ cText2SkinSetup::cText2SkinSetup(void):
ShowAux(true),
StripAux(true),
CheckTimerConflict(false),
- MaxCacheFill(25)
+ MaxCacheFill(25),
+ SupportOldSkins(true)
{
}
@@ -25,6 +26,7 @@ bool cText2SkinSetup::SetupParse(const char *Name, const char *Value) {
else if (strcmp(Name, "StripAux") == 0) StripAux = atoi(Value);
else if (strcmp(Name, "CheckTimerConflict") == 0) CheckTimerConflict = atoi(Value);
else if (strcmp(Name, "MaxCacheFill") == 0) MaxCacheFill = atoi(Value);
+ else if (strcmp(Name, "SupportOldSkins") == 0) SupportOldSkins = atoi(Value);
else return false;
return true;
}
diff --git a/setup.h b/setup.h
index 178b9f7..a698cb8 100644
--- a/setup.h
+++ b/setup.h
@@ -18,6 +18,7 @@ public:
int StripAux;
int CheckTimerConflict;
int MaxCacheFill;
+ int SupportOldSkins;
};
extern cText2SkinSetup Text2SkinSetup;