summaryrefslogtreecommitdiffstats
path: root/kopete/protocols/msn/webcam
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:48:06 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:48:06 +0000
commit47c8a359c5276062c4bc17f0e82410f29081b502 (patch)
tree2d54a5f60a5b74067632f9ef6df58c2bc38155e6 /kopete/protocols/msn/webcam
parent6f82532777a35e0e60bbd2b290b2e93e646f349b (diff)
downloadtdenetwork-47c8a359c5276062c4bc17f0e82410f29081b502.tar.gz
tdenetwork-47c8a359c5276062c4bc17f0e82410f29081b502.zip
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdenetwork@1157648 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kopete/protocols/msn/webcam')
-rw-r--r--kopete/protocols/msn/webcam/mimicwrapper.cpp28
-rw-r--r--kopete/protocols/msn/webcam/mimicwrapper.h6
-rw-r--r--kopete/protocols/msn/webcam/msnwebcamdialog.cpp24
-rw-r--r--kopete/protocols/msn/webcam/msnwebcamdialog.h6
4 files changed, 32 insertions, 32 deletions
diff --git a/kopete/protocols/msn/webcam/mimicwrapper.cpp b/kopete/protocols/msn/webcam/mimicwrapper.cpp
index f7a43d93..a9d3b131 100644
--- a/kopete/protocols/msn/webcam/mimicwrapper.cpp
+++ b/kopete/protocols/msn/webcam/mimicwrapper.cpp
@@ -18,7 +18,7 @@
//#include <qbytearray.h>
#include <kdebug.h>
-#include <qimage.h>
+#include <tqimage.h>
MimicWrapper::MimicWrapper() : m_init(false)
{
@@ -31,35 +31,35 @@ MimicWrapper::~MimicWrapper()
}
-QPixmap MimicWrapper::decode(const QByteArray& data)
+TQPixmap MimicWrapper::decode(const TQByteArray& data)
{
if(!m_init)
{
if(!mimic_decoder_init(m_mimctx, (guchar*)(data.data())))
{
kdWarning(14140) << k_funcinfo << "Impossible to init decoder" << endl;
- return QPixmap();
+ return TQPixmap();
}
if (!mimic_get_property( m_mimctx, "buffer_size", &m_bufferSize) )
{
kdWarning(14140) << k_funcinfo << "Impossible to get buffer size" << endl;
- return QPixmap();
+ return TQPixmap();
}
m_init=true;
}
- QByteArray buff(m_bufferSize);
+ TQByteArray buff(m_bufferSize);
if(!mimic_decode_frame(m_mimctx, (guchar*)(data.data()) , (guchar*)(buff.data()) ) )
{
kdWarning(14140) << k_funcinfo << "Impossible to decode frame" << endl;
- return QPixmap();
+ return TQPixmap();
}
int width,height;
mimic_get_property(m_mimctx, "width", &width);
mimic_get_property(m_mimctx, "height", &height);
- QByteArray buff2(m_bufferSize*4/3);
+ TQByteArray buff2(m_bufferSize*4/3);
uint b2=0;
for(uint f=0;f<m_bufferSize;f+=3)
{
@@ -70,34 +70,34 @@ QPixmap MimicWrapper::decode(const QByteArray& data)
b2+=4;
}
- QImage img( (uchar*)(buff2.data()) , width , height , 32 , 0L , 0, QImage::BigEndian );
- return QPixmap(img);
+ TQImage img( (uchar*)(buff2.data()) , width , height , 32 , 0L , 0, TQImage::BigEndian );
+ return TQPixmap(img);
}
-QByteArray MimicWrapper::encode(const QByteArray& data)
+TQByteArray MimicWrapper::encode(const TQByteArray& data)
{
if(!m_init)
{
if(!mimic_encoder_init(m_mimctx, MIMIC_RES_HIGH))
{
kdWarning(14140) << k_funcinfo << "Impossible to init encoder" << endl;
- return QByteArray();
+ return TQByteArray();
}
if (!mimic_get_property( m_mimctx, "buffer_size", &m_bufferSize) )
{
kdWarning(14140) << k_funcinfo << "Impossible to get buffer size" << endl;
- return QByteArray();
+ return TQByteArray();
}
m_init=true;
m_numFrames=0;
}
- QByteArray buff(m_bufferSize);
+ TQByteArray buff(m_bufferSize);
int buff_new_size;
if(!mimic_encode_frame(m_mimctx, (guchar*)(data.data()) , (guchar*)(buff.data()) , (gint*)(&buff_new_size) , m_numFrames%15==0 ) )
{
kdWarning(14140) << k_funcinfo << "Impossible to decode frame" << endl;
- return QByteArray();
+ return TQByteArray();
}
buff.resize(buff_new_size);
++m_numFrames;
diff --git a/kopete/protocols/msn/webcam/mimicwrapper.h b/kopete/protocols/msn/webcam/mimicwrapper.h
index c4a7475f..1ed048a2 100644
--- a/kopete/protocols/msn/webcam/mimicwrapper.h
+++ b/kopete/protocols/msn/webcam/mimicwrapper.h
@@ -14,7 +14,7 @@
#ifndef MIMICWRAPPER_H
#define MIMICWREPPER_H
-#include <qpixmap.h>
+#include <tqpixmap.h>
#include "kopete_export.h"
@@ -26,8 +26,8 @@ class KOPETE_EXPORT MimicWrapper
MimicWrapper();
~MimicWrapper();
- QPixmap decode(const QByteArray &data);
- QByteArray encode(const QByteArray &data);
+ TQPixmap decode(const TQByteArray &data);
+ TQByteArray encode(const TQByteArray &data);
private:
MimCtx *m_mimctx;
diff --git a/kopete/protocols/msn/webcam/msnwebcamdialog.cpp b/kopete/protocols/msn/webcam/msnwebcamdialog.cpp
index 092135f0..b0540cbb 100644
--- a/kopete/protocols/msn/webcam/msnwebcamdialog.cpp
+++ b/kopete/protocols/msn/webcam/msnwebcamdialog.cpp
@@ -19,31 +19,31 @@
#include "msnwebcamdialog.h"
-#include <qframe.h>
-#include <qobject.h>
-#include <qwidget.h>
+#include <tqframe.h>
+#include <tqobject.h>
+#include <tqwidget.h>
#include <kdebug.h>
#include <klocale.h>
-MSNWebcamDialog::MSNWebcamDialog( const QString& contact, QWidget * parent, const char * name )
+MSNWebcamDialog::MSNWebcamDialog( const TQString& contact, TQWidget * parent, const char * name )
: KDialogBase( KDialogBase::Plain, i18n( "Webcam for %1" ).arg( contact ),
KDialogBase::Close, KDialogBase::Close, parent, name, false, true /*seperator*/ ),
m_imageContainer( this )
{
- setInitialSize( QSize(320,290), true );
+ setInitialSize( TQSize(320,290), true );
setEscapeButton( KDialogBase::Close );
/*
- QObject::connect( contact, SIGNAL( signalReceivedWebcamImage( const QPixmap& ) ),
- this, SLOT( newImage( const QPixmap& ) ) );
+ TQObject::connect( contact, TQT_SIGNAL( signalReceivedWebcamImage( const TQPixmap& ) ),
+ this, TQT_SLOT( newImage( const TQPixmap& ) ) );
*/
- QObject::connect( this, SIGNAL( closeClicked() ), this, SIGNAL( closingWebcamDialog() ) );
+ TQObject::connect( this, TQT_SIGNAL( closeClicked() ), this, TQT_SIGNAL( closingWebcamDialog() ) );
/*
- QObject::connect( contact, SIGNAL( webcamClosed( int ) ), this, SLOT( webcamClosed( int ) ) );
+ TQObject::connect( contact, TQT_SIGNAL( webcamClosed( int ) ), this, TQT_SLOT( webcamClosed( int ) ) );
*/
- QFrame* page = plainPage();
+ TQFrame* page = plainPage();
if ( page )
{
kdDebug(14180) << k_funcinfo << "Adding webcam image container" << endl;
@@ -59,7 +59,7 @@ MSNWebcamDialog::~ MSNWebcamDialog( )
}
-void MSNWebcamDialog::newImage( const QPixmap & image )
+void MSNWebcamDialog::newImage( const TQPixmap & image )
{
kdDebug(14180) << k_funcinfo << "New image received" << endl;
// kdDebug(14180) << image << endl;
@@ -72,7 +72,7 @@ void MSNWebcamDialog::webcamClosed( int reason )
{
kdDebug(14180) << k_funcinfo << "webcam closed with reason?? " << reason <<endl;
//m_imageContainer.clear();
- //m_imageContainer.setText( i18n( "Webcam closed with reason %1" ).arg( QString::number( reason ) ) );
+ //m_imageContainer.setText( i18n( "Webcam closed with reason %1" ).arg( TQString::number( reason ) ) );
//m_imageContainer.setAlignment( Qt::AlignCenter );
//show();
}
diff --git a/kopete/protocols/msn/webcam/msnwebcamdialog.h b/kopete/protocols/msn/webcam/msnwebcamdialog.h
index dc10285d..a86050c4 100644
--- a/kopete/protocols/msn/webcam/msnwebcamdialog.h
+++ b/kopete/protocols/msn/webcam/msnwebcamdialog.h
@@ -21,7 +21,7 @@
#ifndef YAHOOWEBCAMDIALOG_H_
#define YAHOOWEBCAMDIALOG_H_
-//#include <qlabel.h>
+//#include <tqlabel.h>
#include <webcamwidget.h>
#include <kdialogbase.h>
@@ -36,11 +36,11 @@ class KOPETE_EXPORT MSNWebcamDialog : public KDialogBase
{
Q_OBJECT
public:
- MSNWebcamDialog( const QString& contact, QWidget* parent = 0, const char* name = 0 );
+ MSNWebcamDialog( const TQString& contact, TQWidget* parent = 0, const char* name = 0 );
~MSNWebcamDialog();
public slots:
- void newImage( const QPixmap& image );
+ void newImage( const TQPixmap& image );
void webcamClosed( int );
signals: