From a9cfcd75daef74e494a2632af260f1f92b834b4a Mon Sep 17 00:00:00 2001 From: tpearson Date: Wed, 19 Oct 2011 19:05:08 +0000 Subject: TQt port tqt3integration git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebase@1259732 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- tqt3integration/libqtkde/qtkde.cpp | 36 ++++++++++++++++++------------------ tqt3integration/libqtkde/qtkde.h | 9 +++++---- 2 files changed, 23 insertions(+), 22 deletions(-) (limited to 'tqt3integration/libqtkde') diff --git a/tqt3integration/libqtkde/qtkde.cpp b/tqt3integration/libqtkde/qtkde.cpp index 4e737a9a2..79cfbdd98 100644 --- a/tqt3integration/libqtkde/qtkde.cpp +++ b/tqt3integration/libqtkde/qtkde.cpp @@ -23,26 +23,26 @@ #include #include #include -#include -#include -#include -#include +#include +#include +#include +#include #include #include extern Time qt_x_time; -static QString convertFileFilter( const QString& filter ) +static TQString convertFileFilter( const TQString& filter ) { if( filter.isEmpty()) return filter; - QString f2 = filter; - f2.replace( '\n', ";;" ); // Qt says separator is ";;", but it also silently accepts newline + TQString f2 = filter; + f2.replace( '\n', ";;" ); // TQt says separator is ";;", but it also silently accepts newline f2.replace( '/', "\\/" ); // escape /'s for KFileDialog - QStringList items = QStringList::split( ";;", f2 ); - QRegExp reg( "\\((.*)\\)" ); - for( QStringList::Iterator it = items.begin(); + TQStringList items = TQStringList::split( ";;", f2 ); + TQRegExp reg( "\\((.*)\\)" ); + for( TQStringList::Iterator it = items.begin(); it != items.end(); ++it ) { @@ -52,12 +52,12 @@ static QString convertFileFilter( const QString& filter ) return items.join( "\n" ); } -static QString convertBackFileFilter( const QString& filter ) +static TQString convertBackFileFilter( const TQString& filter ) { if( filter.isEmpty()) return filter; - QStringList items = QStringList::split( "\n", filter ); - for( QStringList::Iterator it = items.begin(); + TQStringList items = TQStringList::split( "\n", filter ); + for( TQStringList::Iterator it = items.begin(); it != items.end(); ++it ) { @@ -84,13 +84,13 @@ static DCOPClient* dcopClient() static bool prepared = false; if( !prepared ) { - assert( qApp != NULL ); // TODO + assert( tqApp != NULL ); // TODO prepared = true; dcop->bindToApp(); - if( !qApp->inherits( "KApplication" )) // KApp takes care of input blocking + if( !tqApp->inherits( "KApplication" )) // KApp takes care of input blocking { static qtkde_EventLoop* loop = new qtkde_EventLoop; - QObject::connect( dcop, SIGNAL( blockUserInput( bool )), loop, SLOT( block( bool ))); + TQObject::connect( dcop, TQT_SIGNAL( blockUserInput( bool )), loop, TQT_SLOT( block( bool ))); } } return dcop; @@ -131,7 +131,7 @@ void qtkde_EventLoop::block( bool b ) } // duped in kded module -static QString getHostname() +static TQString getHostname() { char hostname[ 256 ]; if( gethostname( hostname, 255 ) == 0 ) @@ -142,6 +142,6 @@ static QString getHostname() return ""; } -#include "qtkde_functions.cpp" +#include "tqtkde_functions.cpp" #include "qtkde.moc" diff --git a/tqt3integration/libqtkde/qtkde.h b/tqt3integration/libqtkde/qtkde.h index c485537d8..1916cdc6c 100644 --- a/tqt3integration/libqtkde/qtkde.h +++ b/tqt3integration/libqtkde/qtkde.h @@ -18,15 +18,16 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -#ifndef _QTKDE_H -#define _QTKDE_H +#ifndef _TQTKDE_H +#define _TQTKDE_H -#include +#include class qtkde_EventLoop - : public QObject + : public TQObject { Q_OBJECT + TQ_OBJECT public slots: void block( bool ); }; -- cgit v1.2.3