lpcmanager

Parents af9416e32a92
Children 86063716d41d
For linux run thread.join needed. Command Show True execute loading else not.
  • +8 -12
    LPCManager.py
  • --- a/LPCManager.py Tue Jul 04 12:36:46 2017 +0200
    +++ b/LPCManager.py Thu Jul 06 14:47:47 2017 +0200
    @@ -2338,13 +2338,13 @@
    Beremiz.__init__(self, parent, projectOpen, buildpath, ctr, debug)
    - def Show(self):
    + def Show(self, loading=True):
    wx.Frame.Show(self)
    - loading = splash.SmartehScreenSplash(self, bitmap=GetPath(splash.SPLASH_FN), signal=signal_init)
    - thread = Thread(target=loading.Show)
    - thread.start()
    -
    -
    + if loading:
    + loading_splash = splash.SmartehScreenSplash(self, bitmap=GetPath(splash.SPLASH_FN), signal=signal_init)
    + thread = Thread(target=loading_splash.Show)
    + thread.start()
    + thread.join()
    def CheckEnabler(self, event):
    global _checkBlocks
    @@ -2353,8 +2353,6 @@
    else:
    _checkBlocks = 1
    -
    -
    def OnCloseFrame(self, event):
    global frame
    @@ -2556,16 +2554,14 @@
    def do_EOF(self, line):
    return self.Exit()
    - def Show(self):
    + def Show(self, loading=False):
    global frame
    if frame is not None:
    self.CTR.SetAppFrame(frame, frame.Log)
    self.CTR.UpdateMethodsFromPLCStatus()
    - frame.Show()
    + frame.Show(loading)
    frame.Raise()
    self.restore_last_state = True
    - # global signal_init
    - # signal_init.send("show")
    #self.RestartTimer()
    def Refresh(self):