예제 #1
0
void
CliContext::ThreadStateChanged(const Team::ThreadEvent& threadEvent)
{
	if (threadEvent.GetThread()->State() != THREAD_STATE_STOPPED)
		return;

	_QueueEvent(
		new(std::nothrow) Event(EVENT_THREAD_STOPPED, threadEvent.GetThread()));
	_SignalInputLoop(EVENT_THREAD_STOPPED);
}
예제 #2
0
파일: TeamWindow.cpp 프로젝트: DonCN/haiku
void
TeamWindow::ThreadStackTraceChanged(const Team::ThreadEvent& event)
{
	BMessage message(MSG_THREAD_STACK_TRACE_CHANGED);
	message.AddInt32("thread", event.GetThread()->ID());
	PostMessage(&message);
}
예제 #3
0
파일: TeamWindow.cpp 프로젝트: DonCN/haiku
void
TeamWindow::ThreadCpuStateChanged(const Team::ThreadEvent& event)
{
	BMessage message(MSG_THREAD_CPU_STATE_CHANGED);
	message.AddInt32("thread", event.GetThread()->ID());
	PostMessage(&message);
}
예제 #4
0
void
CliContext::ThreadRemoved(const Team::ThreadEvent& threadEvent)
{
	_QueueEvent(
		new(std::nothrow) Event(EVENT_THREAD_REMOVED, threadEvent.GetThread()));
	_SignalInputLoop(EVENT_THREAD_REMOVED);
}
예제 #5
0
void
TeamDebugger::ThreadStateChanged(const ::Team::ThreadEvent& event)
{
	BMessage message(MSG_THREAD_STATE_CHANGED);
	message.AddInt32("thread", event.GetThread()->ID());
	PostMessage(&message);
}
예제 #6
0
void
DebugReportGenerator::ThreadStackTraceChanged(const ::Team::ThreadEvent& event)
{
	if (fTraceWaitingThread == event.GetThread()) {
		fTraceWaitingThread = NULL;
		release_sem(fTeamDataSem);
	}
}
예제 #7
0
void
ThreadListView::ThreadStateChanged(const Team::ThreadEvent& event)
{
	BMessage message(MSG_SYNC_THREAD_LIST);
	message.AddInt32("thread", event.GetThread()->ID());

	Looper()->PostMessage(&message, this);
}
예제 #8
0
void
InspectorWindow::ThreadStateChanged(const Team::ThreadEvent& event)
{
	BMessage message(MSG_THREAD_STATE_CHANGED);
	BReference< ::Thread> threadReference(event.GetThread());
	message.AddPointer("thread", threadReference.Get());

	if (PostMessage(&message) == B_OK)
		threadReference.Detach();
}
예제 #9
0
void
CommandLineUserInterface::ThreadStateChanged(const Team::ThreadEvent& event)
{
	if (fSaveReport) {
		Thread* thread = event.GetThread();
		// If we were asked to attach/report on a specific thread
		// rather than a team, and said thread was still
		// running, when we attached, we need to wait for its corresponding
		// stop state before generating a report, else we might not get its
		// stack trace.
		if (thread->ID() == fReportTargetThread
			&& thread->State() == THREAD_STATE_STOPPED) {
			_SubmitSaveReport();
		}
	}
}