aboutsummaryrefslogtreecommitdiff
path: root/lib/python/Plugins/SystemPlugins/Videomode
diff options
context:
space:
mode:
authorFelix Domke <tmbinc@elitedvb.net>2008-01-24 23:10:44 +0000
committerFelix Domke <tmbinc@elitedvb.net>2008-01-24 23:10:44 +0000
commit71f08ddecd2acdde935476ea53503d4fd95b5a46 (patch)
treea176b71ded0f7f4492462a717e1d1dd6a752c2d3 /lib/python/Plugins/SystemPlugins/Videomode
parent22091210a13049f7a5a0da83cc6213c371bc287c (diff)
downloadenigma2-71f08ddecd2acdde935476ea53503d4fd95b5a46.tar.gz
enigma2-71f08ddecd2acdde935476ea53503d4fd95b5a46.zip
remove debug, add (untested) isPortUsed
Diffstat (limited to 'lib/python/Plugins/SystemPlugins/Videomode')
-rw-r--r--lib/python/Plugins/SystemPlugins/Videomode/VideoHardware.py10
1 files changed, 7 insertions, 3 deletions
diff --git a/lib/python/Plugins/SystemPlugins/Videomode/VideoHardware.py b/lib/python/Plugins/SystemPlugins/Videomode/VideoHardware.py
index 333c6160..4d5b09f9 100644
--- a/lib/python/Plugins/SystemPlugins/Videomode/VideoHardware.py
+++ b/lib/python/Plugins/SystemPlugins/Videomode/VideoHardware.py
@@ -91,7 +91,6 @@ class VideoHardware:
# check if a high-level mode with a given rate is available.
def isModeAvailable(self, port, mode, rate):
- print "isModeAvailable:", port, mode, rate,
rate = self.rates[mode][rate]
for mode in rate.values():
# DVI modes must be in "modes_preferred"
@@ -100,9 +99,7 @@ class VideoHardware:
# print "no, not preferred"
# return False
if mode not in self.modes_available:
- print "no, not available"
return False
- print "yes"
return True
def setMode(self, port, mode, rate, force = None):
@@ -131,6 +128,13 @@ class VideoHardware:
# fixme
return True
+ def isPortUsed(self, port):
+ if port == "DVI":
+ self.readPreferredModes()
+ return len(self.modes_preferred) != 0
+ else:
+ return True
+
def getPortList(self):
return [port for port in self.modes if self.isPortAvailable(port)]