aboutsummaryrefslogtreecommitdiff
path: root/lib/python/Plugins/SystemPlugins
diff options
context:
space:
mode:
authorghost <andreas.monzner@multimedia-labs.de>2009-08-05 18:10:36 +0200
committerghost <andreas.monzner@multimedia-labs.de>2009-08-05 18:10:36 +0200
commit96ac5ba0afb7fb1ea96aee24fc497e76dc2c652b (patch)
tree38003c2b38257a2c6c68e356f92519671c7fe266 /lib/python/Plugins/SystemPlugins
parent344ffd10a4f5b54546fe5e382dbf40a8cf7ecdbb (diff)
downloadenigma2-96ac5ba0afb7fb1ea96aee24fc497e76dc2c652b.tar.gz
enigma2-96ac5ba0afb7fb1ea96aee24fc497e76dc2c652b.zip
SystemPlugins/Videomode: show HDMI on DM500HD instead of DVI
Diffstat (limited to 'lib/python/Plugins/SystemPlugins')
-rw-r--r--lib/python/Plugins/SystemPlugins/Videomode/VideoHardware.py16
-rw-r--r--lib/python/Plugins/SystemPlugins/Videomode/VideoWizard.py7
2 files changed, 18 insertions, 5 deletions
diff --git a/lib/python/Plugins/SystemPlugins/Videomode/VideoHardware.py b/lib/python/Plugins/SystemPlugins/Videomode/VideoHardware.py
index 71529a03..adc63d2c 100644
--- a/lib/python/Plugins/SystemPlugins/Videomode/VideoHardware.py
+++ b/lib/python/Plugins/SystemPlugins/Videomode/VideoHardware.py
@@ -2,6 +2,7 @@ from enigma import eTimer
from Components.config import config, ConfigSelection, ConfigSubDict, ConfigYesNo
from Tools.CList import CList
+from Tools.HardwareInfo import HardwareInfo
# The "VideoHardware" is the interface to /proc/stb/video.
# It generates hotplug events, and gives you the list of
@@ -228,20 +229,27 @@ class VideoHardware:
return res
def createConfig(self, *args):
- # create list of output ports
- portlist = self.getPortList()
+ hw_type = HardwareInfo().get_device_name()
+ lst = []
- # create list of available modes
- config.av.videoport = ConfigSelection(choices = [(port, _(port)) for port in portlist])
config.av.videomode = ConfigSubDict()
config.av.videorate = ConfigSubDict()
+ # create list of output ports
+ portlist = self.getPortList()
for port in portlist:
+ descr = port
+ if descr == 'DVI' and hw_type == 'dm500hd':
+ descr = 'HDMI'
+ lst.append((port, descr))
+
+ # create list of available modes
modes = self.getModeList(port)
if len(modes):
config.av.videomode[port] = ConfigSelection(choices = [mode for (mode, rates) in modes])
for (mode, rates) in modes:
config.av.videorate[mode] = ConfigSelection(choices = rates)
+ config.av.videoport = ConfigSelection(choices = lst)
def setConfiguredMode(self):
port = config.av.videoport.value
diff --git a/lib/python/Plugins/SystemPlugins/Videomode/VideoWizard.py b/lib/python/Plugins/SystemPlugins/Videomode/VideoWizard.py
index 8f8bea09..bceb6bc7 100644
--- a/lib/python/Plugins/SystemPlugins/Videomode/VideoWizard.py
+++ b/lib/python/Plugins/SystemPlugins/Videomode/VideoWizard.py
@@ -7,6 +7,7 @@ from Components.Pixmap import Pixmap, MovingPixmap, MultiPixmap
from Components.config import config, ConfigBoolean, configfile
from Tools.Directories import resolveFilename, SCOPE_PLUGINS
+from Tools.HardwareInfo import HardwareInfo
config.misc.showtestcard = ConfigBoolean(default = False)
@@ -75,11 +76,15 @@ class VideoWizard(WizardLanguage, Rc):
configfile.save()
def listInputChannels(self):
+ hw_type = HardwareInfo().get_device_name()
list = []
for port in self.hw.getPortList():
if self.hw.isPortUsed(port):
- list.append((port,port))
+ descr = port
+ if descr == 'DVI' and hw_type == 'dm500hd':
+ descr = 'HDMI'
+ list.append((descr,port))
list.sort(key = lambda x: x[0])
print "listInputChannels:", list
return list