update to enigma2-plugin-skins-avalon_3.0_mipsel
authorChristian Weiske <cweiske@cweiske.de>
Wed, 2 Dec 2009 17:20:14 +0000 (18:20 +0100)
committerChristian Weiske <cweiske@cweiske.de>
Wed, 2 Dec 2009 17:20:14 +0000 (18:20 +0100)
CONTROL/control
usr/lib/enigma2/python/Components/Renderer/SmartLabel.py [new file with mode: 0644]
usr/share/enigma2/Avalon_II/skin.xml
usr/share/enigma2/Avalon_II/window/ex_label.png [new file with mode: 0644]
usr/share/enigma2/Avalon_II/window/infobar.png

index 158453a..0cc8280 100644 (file)
@@ -1,11 +1,11 @@
 Package: enigma2-plugin-skins-avalon
-Version: 2.1-r0
-Description: Avalon II skin by vali
+Version: 3.0
+Description: Avalon II skin by Vali
 Section: extra
 Priority: optional
-Maintainer: vali <vali@lycos.at>
+Maintainer: vali <vali@no.info>
 Architecture: mipsel
-OE: avalon-2.1
+OE: avalon_II.3.0
 Homepage: www.unknown.at
 Depends:
-Source: ftp://7025/vali/Avalon_II_CVS_100.tar.gz
+Source: ftp://7025/vali/Avalon_II_CVS.tar.gz
diff --git a/usr/lib/enigma2/python/Components/Renderer/SmartLabel.py b/usr/lib/enigma2/python/Components/Renderer/SmartLabel.py
new file mode 100644 (file)
index 0000000..2374a49
--- /dev/null
@@ -0,0 +1,71 @@
+from Components.VariableText import VariableText\r
+from enigma import eLabel, iServiceInformation\r
+from Renderer import Renderer\r
+\r
+\r
+\r
+class SmartLabel(Renderer, VariableText):\r
+       def __init__(self):\r
+               Renderer.__init__(self)\r
+               VariableText.__init__(self)\r
+\r
+       GUI_WIDGET = eLabel\r
+\r
+       def changed(self, what):\r
+               service = self.source.service\r
+               info = service and service.info()\r
+               if info is not None:\r
+                       if (info.getInfo(iServiceInformation.sIsCrypted) == 1):\r
+                               decID = ""\r
+                               decFrom = ""\r
+                               xresol = 0\r
+                               yresol = 0\r
+                               try:\r
+                                       f = open("/tmp/ecm.info", "r")\r
+                                       flines = f.readlines()\r
+                                       f.close()\r
+                                       for cell in flines:\r
+                                               if ("caid" in cell)or("CAID" in cell)or("CaID" in cell)or("caID" in cell)or("Caid" in cell):\r
+                                                       cellmembers = cell.split()\r
+                                                       for x in range(len(cellmembers)):\r
+                                                               if ("caid" in cellmembers[x])or("CAID" in cellmembers[x])or("CaID" in cellmembers[x])or("caID" in cellmembers[x])or("Caid" in cellmembers[x]):\r
+                                                                       if x<(len(cellmembers)-1):\r
+                                                                               if cellmembers[x+1] != "0x000":\r
+                                                                                       decID = cellmembers[x+1]\r
+                                                                                       decID = decID .lstrip("0x")\r
+                                                                                       decID = decID.strip(",;.:-*_<>()[]{}")\r
+                                                                                       if (len(decID)<4):\r
+                                                                                               decID = decID + "0"\r
+                                                                               else:\r
+                                                                                       decID = ""\r
+                                       if decID != "":\r
+                                               idnames = ("0100,01FF,SE","0500,05FF,VI","0600,06FF,IR","0900,09FF,NDS","0B00,0BFF,CO","0D00,0DFF,CW","1700,17FF,BC","1800,18FF,NA")\r
+                                               for idline in idnames:\r
+                                                       IDlist = idline.split(",")\r
+                                                       try:\r
+                                                               if (int(decID,16)>=int(IDlist[0],16)) and (int(decID,16)<=int(IDlist[1],16)):\r
+                                                                       decID = IDlist[2] + " " + decID\r
+                                                                       break\r
+                                                       except:\r
+                                                               pass\r
+                                       for cell in flines:\r
+                                               if ("using:" in cell) or ("source:" in cell):\r
+                                                       cellmembers = cell.split()\r
+                                                       for x in range(len(cellmembers)):\r
+                                                               if ("using:" in cellmembers[x]) or ("source:" in cellmembers[x]):\r
+                                                                       if x<(len(cellmembers)-1):\r
+                                                                               if cellmembers[x+1] != "fta":\r
+                                                                                       decFrom = cellmembers[x+1]\r
+                                                                               else:\r
+                                                                                       decFrom = ""\r
+                               except:\r
+                                       pass\r
+                               self.text = decFrom + " " + decID\r
+                       else:\r
+                               xresol = info.getInfo(iServiceInformation.sVideoWidth)\r
+                               yresol = info.getInfo(iServiceInformation.sVideoHeight)\r
+                               if xresol>0:\r
+                                       self.text = str(xresol) + " x " + str(yresol)\r
+\r
+\r
+\r
index dc31aa5..d7a69f6 100644 (file)
@@ -34,7 +34,7 @@
                <font filename="valis_enigma.ttf" name="Regular" scale="100" replacement="1" />\r
                <font filename="valis_lcd.ttf" name="LCD" scale="100" />\r
                <font filename="goodtime.ttf" name="OLED" scale="100" />\r
-               <font filename="tuxtxt.ttf" name="Console" scale="100" />\r
+               <font filename="valis_enigma.ttf" name="Console" scale="100" />\r
        </fonts>\r
        <windowstyle type="skinned" id="0">\r
                <title offset="15,10" font="Regular;20" />\r
                <widget source="session.RecordState" render="Pixmap" pixmap="Avalon_II/icons/rec.png" position="187,440" zPosition="3" size="12,12" alphatest="on" transparent="1" >\r
                        <convert type="ConditionalShowHide">Blink</convert>\r
                </widget>\r
-               <widget source="session.FrontendStatus" render="Label" position="587,437" zPosition="3" size="75,24" font="Regular;15" halign="right" foregroundColor="clText" transparent="1"  backgroundColor="clBack">\r
+               <widget source="session.FrontendStatus" render="Label" position="587,439" zPosition="3" size="75,24" font="Regular;15" halign="right" foregroundColor="clText" transparent="1"  backgroundColor="clBack">\r
                        <convert type="FrontendInfo">SNRdB</convert>\r
                </widget>\r
+               <widget source="session.CurrentService" render="SmartLabel" position="572,419" zPosition="4" size="90,20" noWrap="1" halign="right" font="Regular;15" foregroundColor="clText" transparent="1"  backgroundColor="clBack" />\r
        </screen>\r
        \r
        \r
        </screen>\r
        <!-- Console -->\r
        <screen name="Console" position="80,87" size="560,430" title="Command execution...">\r
-               <widget name="text" position="10,10" size="540,410" font="Regular;18" />\r
+               <widget name="text" position="10,10" size="540,410" font="Console;20" />\r
        </screen>\r
        <!-- Harddisk setup -->\r
        <screen name="HarddiskSetup" position="140,200" size="420,160" title="Harddisk">\r
                <widget name="status" position="10,60" size="550,45" font="Regular;18" />\r
                <widget name="slider" position="10,100" size="530,15" pixmap="Avalon_II/window/misc_p_bar_big.png" borderWidth="1" borderColor="#cccccc" />\r
        </screen>\r
-       <!-- Nameserver -->\r
-       <screen name="NameserverSetup" position="130,140" size="460,330" title="Nameserver Setup">\r
-               <ePixmap pixmap="Avalon_II/buttons/red.png" position="0,0" size="140,40" alphatest="on" />\r
-               <ePixmap pixmap="Avalon_II/buttons/green.png" position="315,0" size="140,40" alphatest="on" />\r
-               <widget name="red" position="0,0" zPosition="1" size="140,40" font="Regular;20" halign="center" valign="center" transparent="1" />\r
-               <widget name="green" position="315,0" zPosition="1" size="140,40" font="Regular;20" halign="center" valign="center" transparent="1" />\r
-               <widget name="config" position="10,50" size="440,175" scrollbarMode="showOnDemand" />\r
-       </screen>\r
        <!-- Plugin browser -->\r
        <screen name="PluginBrowser" position="160,95" size="400,405" title="Plugin browser">\r
                <ePixmap pixmap="Avalon_II/buttons/red-big.png" position="0,0" size="200,40" alphatest="on" />\r
diff --git a/usr/share/enigma2/Avalon_II/window/ex_label.png b/usr/share/enigma2/Avalon_II/window/ex_label.png
new file mode 100644 (file)
index 0000000..a74c7d8
Binary files /dev/null and b/usr/share/enigma2/Avalon_II/window/ex_label.png differ
index ff5e1b4..f625510 100644 (file)
Binary files a/usr/share/enigma2/Avalon_II/window/infobar.png and b/usr/share/enigma2/Avalon_II/window/infobar.png differ