It only goes into tyhe loop on a line nubmer change, since running the two call backs gets to interrupts per line. I don't care, they are handled and I sort the difference later. But, the call back trace function simply waits until the flag is not zero, and exits. At that pony, the previous call to message loop from main takes over, again. The root update methods are re-entrant.
TestCode.flag = 0
if TestCode.lineno != TestCode.prevlineno : BreakHalt()
while True :
if TestCode.flag != 0 :
break
TestCode.root.update_idletasks()
TestCode.root.update()
ANdhere is the run command as triggered in the mainloop called from app star:
self.flag= 1
exec(self.sourcetext,self.globals,self.locals)
self.flag= -2
All of the debug control clicks take place within the exec call, via service interrupts.
No comments:
Post a Comment