From ffe8a83e053396df448e9413828527613ca3bd46 Mon Sep 17 00:00:00 2001 From: tpearson Date: Sat, 31 Jul 2010 19:46:43 +0000 Subject: Trinity Qt initial conversion git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1157647 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kparts/tests/notepad.cpp | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) (limited to 'kparts/tests/notepad.cpp') diff --git a/kparts/tests/notepad.cpp b/kparts/tests/notepad.cpp index 8e6f5462c..e0857a51e 100644 --- a/kparts/tests/notepad.cpp +++ b/kparts/tests/notepad.cpp @@ -3,10 +3,10 @@ #include #include -#include -#include -#include -#include +#include +#include +#include +#include #include #include @@ -16,17 +16,17 @@ #include #include -NotepadPart::NotepadPart( QWidget* parentWidget, const char*, - QObject* parent, const char* name, - const QStringList& ) +NotepadPart::NotepadPart( TQWidget* parentWidget, const char*, + TQObject* parent, const char* name, + const TQStringList& ) : KParts::ReadWritePart( parent, name ) { setInstance( NotepadFactory::instance() ); - m_edit = new QMultiLineEdit( parentWidget, "NotepadPart's multiline edit" ); + m_edit = new TQMultiLineEdit( parentWidget, "NotepadPart's multiline edit" ); setWidget( m_edit ); - (void)new KAction( "Search and replace", 0, this, SLOT( slotSearchReplace() ), actionCollection(), "searchreplace" ); + (void)new KAction( "Search and replace", 0, this, TQT_SLOT( slotSearchReplace() ), actionCollection(), "searchreplace" ); setXMLFile( "notepadpart.rc" ); setReadWrite( true ); } @@ -39,9 +39,9 @@ void NotepadPart::setReadWrite( bool rw ) { m_edit->setReadOnly( !rw ); if (rw) - connect( m_edit, SIGNAL( textChanged() ), this, SLOT( setModified() ) ); + connect( m_edit, TQT_SIGNAL( textChanged() ), this, TQT_SLOT( setModified() ) ); else - disconnect( m_edit, SIGNAL( textChanged() ), this, SLOT( setModified() ) ); + disconnect( m_edit, TQT_SIGNAL( textChanged() ), this, TQT_SLOT( setModified() ) ); ReadWritePart::setReadWrite( rw ); } @@ -55,10 +55,10 @@ bool NotepadPart::openFile() { kdDebug() << "NotepadPart: opening " << m_file << endl; // Hehe this is from a tutorial I did some time ago :) - QFile f(m_file); - QString s; + TQFile f(m_file); + TQString s; if ( f.open(IO_ReadOnly) ) { - QTextStream t( &f ); + TQTextStream t( &f ); while ( !t.eof() ) { s += t.readLine() + "\n"; } @@ -75,10 +75,10 @@ bool NotepadPart::saveFile() { if ( !isReadWrite() ) return false; - QFile f(m_file); - QString s; + TQFile f(m_file); + TQString s; if ( f.open(IO_WriteOnly) ) { - QTextStream t( &f ); + TQTextStream t( &f ); t << m_edit->text(); f.close(); return true; @@ -90,9 +90,9 @@ void NotepadPart::slotSearchReplace() { // What's this ? (David) /* - QValueList plugins = KParts::Plugin::pluginServants( this ); - QValueList::ConstIterator it = plugins.begin(); - QValueList::ConstIterator end = plugins.end(); + TQValueList plugins = KParts::Plugin::pluginServants( this ); + TQValueList::ConstIterator it = plugins.begin(); + TQValueList::ConstIterator end = plugins.end(); for (; it != end; ++it ) factory()->removeServant( *it ); */ -- cgit v1.2.1