use new/delete instead of malloc/free
[enigma2.git] / lib / python / Screens / PictureInPicture.py
index ce959209733c87de0c160b50d89eff5f83109fd5..5c49683335535660fc034d7a39576f2174245ada 100644 (file)
@@ -3,12 +3,17 @@ from enigma import ePoint, eSize, eServiceCenter
 from Components.VideoWindow import VideoWindow
 from Components.config import config, ConfigPosition
 
+pip_config_initialized = False
+
 class PictureInPicture(Screen):
        def __init__(self, session):
+               global pip_config_initialized
                Screen.__init__(self, session)
                self["video"] = VideoWindow()
                self.currentService = None
-               config.av.pip = ConfigPosition(default=[-1, -1, -1, -1], limits = (719, 567, 720, 568))
+               if not pip_config_initialized:
+                       config.av.pip = ConfigPosition(default=[-1, -1, -1, -1], args = (719, 567, 720, 568))
+                       pip_config_initialized = True
                self.onLayoutFinish.append(self.LayoutFinished)
 
        def LayoutFinished(self):