示例#1
0
status_t
AbstractProcess::Stop()
{
	status_t result = B_CANCELED;
    AbstractProcessListener* listener = NULL;

	{
		AutoLocker<BLocker> locker(&fLock);

		if (!fWasStopped) {
			fWasStopped = true;
			result = StopInternal();

			if (fProcessState == PROCESS_INITIAL) {
				listener = fListener;
				fProcessState = PROCESS_COMPLETE;
			}
		}
	}

	if (listener != NULL)
		listener->ProcessExited();

	return result;
}
void SStopWatch::Stop()
{
	Root* const root = m_root;

	if (root && (root->extensions&EXTENSION_STOPPED) == 0) {
		StopInternal(root);
	}
};
示例#3
0
//-----------------------------------------------------------------------------
//!
//-----------------------------------------------------------------------------
tIMX51Video::~tIMX51Video()
{
    StopInternal();
    if(m_pGstPipeline)
    {
        gst_object_unref( GST_OBJECT( m_pGstPipeline ) );    
        m_pGstPipeline = 0;
    }
}
示例#4
0
文件: thread.cpp 项目: tangjie/app
	void Thread::Stop() {
		if (!was_started()) {
			return;
		}
		StopInternal();
		ThreadHelper::Join(thread_handle_);
		assert(!message_loop_);
		was_started_ = false;
		stopping_ = false;
	}
示例#5
0
//-----------------------------------------------------------------------------
void tIMX51Video::SetColourKey(const QColor &key)
{
    m_ColourKey = key;

    if( m_RunningInternal )
    {
        StopInternal();
        RunInternal();
    }
}
示例#6
0
//-----------------------------------------------------------------------------
void tIMX51Video::SetGeometryInternal()
{
    UpdateVideoGeometry();
    if( m_RunningInternal )
    {
        StopInternal();
        RunInternal();
    }
    else if(m_pGstSource)
    {
        g_object_set(m_pGstSource, "capture-width", m_VideoGeometry.width(), NULL);
        g_object_set(m_pGstSource, "capture-height", m_VideoGeometry.height(), NULL);
        g_object_set(m_pGstSource, "preview-width", m_VideoGeometry.width(), NULL);
        g_object_set(m_pGstSource, "preview-height", m_VideoGeometry.height(), NULL);
        g_object_set(m_pGstSource, "preview-top", m_VideoGeometry.top(), NULL);
        g_object_set(m_pGstSource, "preview-left", m_VideoGeometry.left(), NULL);
    }
}
void SStopWatch::StopFast()
{
	StopInternal(m_root);
}