add comment
[enigma2.git] / lib / python / Screens / Screen.py
index 5f1cf6d610193b848db2aba773613a11ff83ce87..0727f78ba034ae3ef2a3fdd79cd6e681841e74af 100644 (file)
@@ -1,5 +1,6 @@
 from Components.HTMLSkin import *
 from Components.GUISkin import *
+from Components.Sources.Source import Source
 
 import sys
 
@@ -99,7 +100,7 @@ class Screen(dict, HTMLSkin, GUISkin):
                for x in self.onShow:
                        x()
                for val in self.values() + self.renderer:
-                       if isinstance(val, GUIComponent):
+                       if isinstance(val, GUIComponent) or isinstance(val, Source):
                                val.onShow()
 
        def hide(self):
@@ -110,5 +111,8 @@ class Screen(dict, HTMLSkin, GUISkin):
                for x in self.onHide:
                        x()
                for val in self.values() + self.renderer:
-                       if isinstance(val, GUIComponent):
+                       if isinstance(val, GUIComponent) or isinstance(val, Source):
                                val.onHide()
+
+       def __repr__(self):
+               return str(type(self))