예제 #1
0
파일: main.py 프로젝트: eschen42/mastr-ms
class MDataSyncApp(wx.PySimpleApp):
    def __init__(self, config=None, *args, **kwargs):
        self.config = config or MSDSConfig.load()
        super(MDataSyncApp, self).__init__(*args, **kwargs)

    def OnInit(self):
        #w = wx.LogChain(wx.LogStderr() )
        #wx.Log_SetActiveTarget( wx.LogStderr() )
        #wx.Log_SetActiveTarget( wx.LogGui() )

        win = MainWindow(self.config, None)
        self.win = win
        self.msds = MSDataSyncAPI(self.config, win.getLog())

        #let the jobs execute in threads
        #disable this for debugging
        self.msds.startThread()

        win.MSDSCheckFn = self.msds.checkRsync
        win.MSDSHandshakeFn = self.msds.handshakeRsync
        win.msds = self.msds
        win.resetTimeTillNextSync()
        #wx.Log_SetActiveTarget( wx.LogWindow(None, 'loggin...') )
        win.Show(True)
        self.SetTopWindow(win)
        return True
예제 #2
0
class MDataSyncApp(wx.PySimpleApp):
    def __init__(self, config=None, *args, **kwargs):
        self.config = config or MSDSConfig.load()
        super(MDataSyncApp, self).__init__(*args, **kwargs)

    def OnInit(self):
        #w = wx.LogChain(wx.LogStderr() )
        #wx.Log_SetActiveTarget( wx.LogStderr() )
        #wx.Log_SetActiveTarget( wx.LogGui() )

        win = MainWindow(self.config, None)
        self.win = win
        self.msds = MSDataSyncAPI(self.config, win.getLog())

        #let the jobs execute in threads
        #disable this for debugging
        self.msds.startThread()

        win.MSDSCheckFn = self.msds.checkRsync
        win.MSDSHandshakeFn = self.msds.handshakeRsync
        win.msds = self.msds
        win.resetTimeTillNextSync()
        #wx.Log_SetActiveTarget( wx.LogWindow(None, 'loggin...') )
        win.Show(True)
        self.SetTopWindow(win)
        return True
예제 #3
0
파일: main.py 프로젝트: eschen42/mastr-ms
    def OnInit(self):
        #w = wx.LogChain(wx.LogStderr() )
        #wx.Log_SetActiveTarget( wx.LogStderr() )
        #wx.Log_SetActiveTarget( wx.LogGui() )

        win = MainWindow(self.config, None)
        self.win = win
        self.msds = MSDataSyncAPI(self.config, win.getLog())

        #let the jobs execute in threads
        #disable this for debugging
        self.msds.startThread()

        win.MSDSCheckFn = self.msds.checkRsync
        win.MSDSHandshakeFn = self.msds.handshakeRsync
        win.msds = self.msds
        win.resetTimeTillNextSync()
        #wx.Log_SetActiveTarget( wx.LogWindow(None, 'loggin...') )
        win.Show(True)
        self.SetTopWindow(win)
        return True
예제 #4
0
    def OnInit(self):
        #w = wx.LogChain(wx.LogStderr() )
        #wx.Log_SetActiveTarget( wx.LogStderr() )
        #wx.Log_SetActiveTarget( wx.LogGui() )

        win = MainWindow(self.config, None)
        self.win = win
        self.msds = MSDataSyncAPI(self.config, win.getLog())

        #let the jobs execute in threads
        #disable this for debugging
        self.msds.startThread()

        win.MSDSCheckFn = self.msds.checkRsync
        win.MSDSHandshakeFn = self.msds.handshakeRsync
        win.msds = self.msds
        win.resetTimeTillNextSync()
        #wx.Log_SetActiveTarget( wx.LogWindow(None, 'loggin...') )
        win.Show(True)
        self.SetTopWindow(win)
        return True