示例#1
0
    def quit(self, justHide=False):
        """ Finish the program execution """
        if justHide:
            self.root.withdraw()
        else:
            try:
                scheds = self.scheduler_processes.keys()
                for t in scheds:
                    self.try_stop_scheduler(t)
            except:
                pass
            try:
                newcron.stopcron()
            except:
                pass
            try:
                self.server.stop()
            except:
                pass
            try:
                self.tb.Destroy()
            except:
                pass

            self.root.destroy()
            sys.exit(0)
示例#2
0
    def quit(self, justHide=False):
        """ Finish the program execution """
        if justHide:
            self.root.withdraw()
        else:
            try:
                scheds = self.scheduler_processes.keys()
                for t in scheds:
                    self.try_stop_scheduler(t)
            except:
                pass
            try:
                newcron.stopcron()
            except:
                pass
            try:
                self.server.stop()
            except:
                pass
            try:
                self.tb.Destroy()
            except:
                pass

            self.root.destroy()
            sys.exit(0)
示例#3
0
 def stop(self, stoplogging=False):
     """
     stop cron and the web server
     """
     newcron.stopcron()
     self.server.stop(stoplogging)
     try:
         os.unlink(self.pid_filename)
     except:
         pass
示例#4
0
 def stop(self, stoplogging=False):
     """
     stop cron and the web server
     """
     newcron.stopcron()
     self.server.stop(stoplogging)
     try:
         os.unlink(self.pid_filename)
     except:
         pass