aboutsummaryrefslogtreecommitdiff
path: root/lib/python
diff options
context:
space:
mode:
Diffstat (limited to 'lib/python')
-rw-r--r--lib/python/Components/About.py17
-rw-r--r--lib/python/Components/Makefile.am2
-rw-r--r--lib/python/Screens/About.py3
3 files changed, 20 insertions, 2 deletions
diff --git a/lib/python/Components/About.py b/lib/python/Components/About.py
new file mode 100644
index 00000000..24bfb2b0
--- /dev/null
+++ b/lib/python/Components/About.py
@@ -0,0 +1,17 @@
+from Tools.Directories import *
+
+class About:
+ def __init__(self):
+ pass
+
+ def getVersionString(self):
+ file = open(resolveFilename(SCOPE_SYSETC, 'image-version'), 'r')
+ lines = file.readlines()
+ for x in lines:
+ splitted = x.split('=')
+ if splitted[0] == "version":
+ return "2.0-" + str(splitted[1])
+ file.close()
+ return "2.0b"
+
+about = About() \ No newline at end of file
diff --git a/lib/python/Components/Makefile.am b/lib/python/Components/Makefile.am
index 656527b2..a5058cf9 100644
--- a/lib/python/Components/Makefile.am
+++ b/lib/python/Components/Makefile.am
@@ -11,4 +11,4 @@ install_PYTHON = \
AVSwitch.py Network.py RFmod.py DiskInfo.py NimManager.py Lcd.py \
EpgList.py ScrollLabel.py Timezones.py Language.py HelpMenuList.py \
BlinkingPixmap.py Pixmap.py ConditionalWidget.py Slider.py LanguageList.py \
- PluginList.py PluginComponent.py RecordingConfig.py
+ PluginList.py PluginComponent.py RecordingConfig.py About.py
diff --git a/lib/python/Screens/About.py b/lib/python/Screens/About.py
index 2e267a07..5bd5f273 100644
--- a/lib/python/Screens/About.py
+++ b/lib/python/Screens/About.py
@@ -4,12 +4,13 @@ from Components.Label import Label
from Components.Harddisk import Harddisk
from Components.NimManager import nimmanager
from Components.MenuList import MenuList
+from Components.About import about
class About(Screen):
def __init__(self, session):
Screen.__init__(self, session)
- self["text"] = Label("Enigma v2.0b")
+ self["text"] = Label("Enigma v" + about.getVersionString())
self["tuner"] = Label(_("Detected NIMs:"))