160 "Created: / 03-06-2014 / 00:36:00 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
160 "Created: / 03-06-2014 / 00:36:00 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
161 "Modified: / 04-06-2014 / 09:28:59 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
161 "Modified: / 04-06-2014 / 09:28:59 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
162 ! |
162 ! |
163 |
163 |
164 onRunningEvent: aGDBRunningEvent |
164 onRunningEvent: aGDBRunningEvent |
165 self nextInferiorStateSequnceNumber |
165 | threads threadId | |
|
166 |
|
167 threadId := aGDBRunningEvent threadId. |
|
168 threadId = 'all' ifFalse:[ |
|
169 threadId := threadId asInteger. |
|
170 ]. |
|
171 self nextInferiorStateSequnceNumber. |
|
172 threads := Set new. |
|
173 inferiors do:[:inferior | |
|
174 inferior threads do:[:thread | |
|
175 (threadId isString or:[thread id = threadId]) ifTrue:[ |
|
176 thread setStatus: GDBThreadStatusRunning theOneAndOnlyInstance. |
|
177 threads add: thread. |
|
178 ]. |
|
179 ]. |
|
180 ]. |
|
181 aGDBRunningEvent setThreads: threads |
166 |
182 |
167 "Created: / 07-09-2014 / 23:34:05 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
183 "Created: / 07-09-2014 / 23:34:05 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
168 ! |
184 "Modified: / 08-09-2014 / 23:51:04 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
169 |
185 ! |
170 onStoppedEvent: aGDBRunningEvent |
186 |
|
187 onStoppedEvent: aGDBStoppedEvent |
|
188 | threads threadIds | |
|
189 |
|
190 threadIds := aGDBStoppedEvent stoppedThreadIds. |
|
191 threadIds = 'all' ifFalse:[ |
|
192 threadIds := threadIds collect:[:e | e asInteger ]. |
|
193 ]. |
|
194 threads := Set new. |
|
195 inferiors do:[:inferior | |
|
196 inferior threads do:[:thread | |
|
197 (threadIds isString or:[threadIds includes: thread id]) ifTrue:[ |
|
198 thread setStatus: GDBThreadStatusStopped new. |
|
199 threads add: thread. |
|
200 ]. |
|
201 ]. |
|
202 ]. |
|
203 aGDBStoppedEvent setThreads: threads |
171 |
204 |
172 "Created: / 07-09-2014 / 23:34:12 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
205 "Created: / 07-09-2014 / 23:34:12 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
206 "Modified: / 08-09-2014 / 23:50:54 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
173 ! |
207 ! |
174 |
208 |
175 onThreadCreatedEvent:aGDBThreadCreatedEvent |
209 onThreadCreatedEvent:aGDBThreadCreatedEvent |
176 | inferior | |
210 | inferior | |
177 |
211 |