GDBThreadGroup.st
changeset 204 657ffb5e85fa
parent 174 18ef81a3fee5
child 208 b0d2028189fa
equal deleted inserted replaced
203:8b883bd72f5a 204:657ffb5e85fa
   217     thread := self threadWithId:aGDBThreadSelectedEvent threadId.
   217     thread := self threadWithId:aGDBThreadSelectedEvent threadId.
   218     frame := aGDBThreadSelectedEvent frame.
   218     frame := aGDBThreadSelectedEvent frame.
   219 
   219 
   220     aGDBThreadSelectedEvent setThread: thread.
   220     aGDBThreadSelectedEvent setThread: thread.
   221     "/ Be carefull, thread may be running!!
   221     "/ Be carefull, thread may be running!!
   222     (thread isStopped and:[frame notNil]) ifTrue:[ 
   222     (false "thread isStopped and:[frame notNil]") ifTrue:[ 
       
   223         "/ This is actually not a good idea. This code is executed
       
   224         "/ within event dispatching process so one may not execute
       
   225         "/ more commands - which is what `thread stack` does. Sigh.
   223         aGDBThreadSelectedEvent setFrame: (thread stack at: (frame level + 1))
   226         aGDBThreadSelectedEvent setFrame: (thread stack at: (frame level + 1))
   224     ] ifFalse:[ 
   227     ] ifFalse:[ 
   225         "/ If it is running, at least fixup it's frame, if there's any (it may not
   228         "/ If it is running, at least fixup it's frame, if there's any (it may not
   226         "/ if the thread is running at the time of =thread-select event.
   229         "/ if the thread is running at the time of =thread-select event.
   227         "/ Uff, so many cases...
   230         "/ Uff, so many cases...
   231                 setThread: thread.
   234                 setThread: thread.
   232         ].
   235         ].
   233     ].
   236     ].
   234 
   237 
   235     "Created: / 29-07-2018 / 22:21:48 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   238     "Created: / 29-07-2018 / 22:21:48 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   236     "Modified: / 26-01-2019 / 23:35:58 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   239     "Modified: / 20-11-2019 / 22:09:37 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   237 ! !
   240 ! !
   238 
   241 
   239 !GDBThreadGroup methodsFor:'initialization'!
   242 !GDBThreadGroup methodsFor:'initialization'!
   240 
   243 
   241 initialize
   244 initialize