diff -r d881023c13eb -r cbb1bfb7ebfb qtms/src/qtmsclientsource.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/qtms/src/qtmsclientsource.cpp Fri May 14 16:21:14 2010 +0300 @@ -0,0 +1,98 @@ +/* + * Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies). + * All rights reserved. + * This component and the accompanying materials are made available + * under the terms of "Eclipse Public License v1.0" + * which accompanies this distribution, and is available + * at the URL "http://www.eclipse.org/legal/epl-v10.html". + * + * Initial Contributors: + * Nokia Corporation - initial contribution. + * + * Contributors: + * + * Description: QT Bindings for TMS + * + */ + +#include +#include +#include + +using namespace QTMS; +using namespace TMS; + +QTMSClientSource::QTMSClientSource() : + iSource(NULL) + { + } + +QTMSClientSource::~QTMSClientSource() + { + delete iSource; + } + +gint QTMSClientSource::SetEnqueueMode(const gboolean enable) + { + gint status(QTMS_RESULT_UNINITIALIZED_OBJECT); + if (iSource) + { + status = static_cast (iSource)->SetEnqueueMode( + enable); + } + return status; + } + +gint QTMSClientSource::GetEnqueueMode(gboolean& enable) + { + gint status(QTMS_RESULT_UNINITIALIZED_OBJECT); + if (iSource) + { + status = static_cast (iSource)->GetEnqueueMode( + enable); + } + return status; + } + +gint QTMSClientSource::Flush() + { + gint status(QTMS_RESULT_UNINITIALIZED_OBJECT); + if (iSource) + { + status = static_cast (iSource)->Flush(); + } + return status; + } + +gint QTMSClientSource::GetType(QTMSSourceType& sourcetype) + { + gint status(QTMS_RESULT_UNINITIALIZED_OBJECT); + if (iSource) + { + status = static_cast (iSource)->GetType(sourcetype); + } + return status; + } + +gint QTMSClientSource::BufferFilled(TMS::TMSBuffer& buffer) + { + gint status(QTMS_RESULT_UNINITIALIZED_OBJECT); + if (iSource) + { + status = static_cast (iSource)->BufferFilled(buffer); + } + return status; + } + +// Push mode +gint QTMSClientSource::ProcessBuffer(TMS::TMSBuffer* buffer) + { + gint status(QTMS_RESULT_UNINITIALIZED_OBJECT); + if (iSource) + { + status = static_cast (iSource)->ProcessBuffer(buffer); + } + return status; + } + +// End of file