From 47c8a359c5276062c4bc17f0e82410f29081b502 Mon Sep 17 00:00:00 2001 From: tpearson Date: Sat, 31 Jul 2010 19:48:06 +0000 Subject: Trinity Qt initial conversion git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdenetwork@1157648 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kppp/miniterm.cpp | 66 +++++++++++++++++++++++++++---------------------------- 1 file changed, 33 insertions(+), 33 deletions(-) (limited to 'kppp/miniterm.cpp') diff --git a/kppp/miniterm.cpp b/kppp/miniterm.cpp index 94b342d5..06c01194 100644 --- a/kppp/miniterm.cpp +++ b/kppp/miniterm.cpp @@ -39,24 +39,24 @@ #include #include -#include -#include -#include -#include +#include +#include +#include +#include extern PPPData gpppdata; -MiniTerm::MiniTerm(QWidget *parent, const char *name) - : QDialog(parent, name, true) +MiniTerm::MiniTerm(TQWidget *parent, const char *name) + : TQDialog(parent, name, true) { setCaption(i18n("Kppp Mini-Terminal")); KWin::setIcons(winId(), kapp->icon(), kapp->miniIcon()); - m_file = new QPopupMenu(this); - m_file->insertItem( SmallIcon("fileclose"), i18n("&Close"), this, SLOT(cancelbutton()) ); - m_options = new QPopupMenu(this); - m_options->insertItem(i18n("&Reset Modem"),this,SLOT(resetModem())); + m_file = new TQPopupMenu(this); + m_file->insertItem( SmallIcon("fileclose"), i18n("&Close"), this, TQT_SLOT(cancelbutton()) ); + m_options = new TQPopupMenu(this); + m_options->insertItem(i18n("&Reset Modem"),this,TQT_SLOT(resetModem())); m_help = new KHelpMenu(this, i18n("MiniTerm - A terminal emulation for KPPP\n\n" @@ -72,21 +72,21 @@ MiniTerm::MiniTerm(QWidget *parent, const char *name) menubar->insertItem( i18n("&Modem"), m_options ); menubar->insertItem( KStdGuiItem::help().text(), m_help->menu()); - statusbar = new QLabel(this); - statusbar->setFrameStyle(QFrame::Panel | QFrame::Sunken); + statusbar = new TQLabel(this); + statusbar->setFrameStyle(TQFrame::Panel | TQFrame::Sunken); terminal = new MyTerm(this, "term"); setupToolbar(); - QVBoxLayout *layout=new QVBoxLayout(this); + TQVBoxLayout *layout=new TQVBoxLayout(this); layout->addWidget(menubar); layout->addWidget(toolbar); layout->addWidget(terminal); layout->addWidget(statusbar); - inittimer = new QTimer(this); - connect(inittimer,SIGNAL(timeout()),this,SLOT(init())); + inittimer = new TQTimer(this); + connect(inittimer,TQT_SIGNAL(timeout()),this,TQT_SLOT(init())); inittimer->start(500); resize(550,400); @@ -103,16 +103,16 @@ void MiniTerm::setupToolbar() { toolbar = new KToolBar( this ); toolbar->insertButton("exit", 0, - SIGNAL(clicked()), this, - SLOT(cancelbutton()), TRUE, i18n("Close MiniTerm")); + TQT_SIGNAL(clicked()), this, + TQT_SLOT(cancelbutton()), TRUE, i18n("Close MiniTerm")); toolbar->insertButton("back", 0, - SIGNAL(clicked()), this, - SLOT(resetModem()), TRUE, i18n("Reset Modem")); + TQT_SIGNAL(clicked()), this, + TQT_SLOT(resetModem()), TRUE, i18n("Reset Modem")); toolbar->insertButton("help", 0, - SIGNAL(clicked()), this, - SLOT(help()), TRUE, i18n("Help")); + TQT_SIGNAL(clicked()), this, + TQT_SLOT(help()), TRUE, i18n("Help")); toolbar->setBarPos( KToolBar::Top ); toolbar->setMovingEnabled(false); @@ -154,7 +154,7 @@ void MiniTerm::init() { kapp->processEvents(); kapp->processEvents(); - Modem::modem->notify(this, SLOT(readChar(unsigned char))); + Modem::modem->notify(this, TQT_SLOT(readChar(unsigned char))); return; } } @@ -214,7 +214,7 @@ void MiniTerm::resetModem() { } -void MiniTerm::closeEvent( QCloseEvent *e ) { +void MiniTerm::closeEvent( TQCloseEvent *e ) { cancelbutton(); e->accept(); } @@ -225,13 +225,13 @@ void MiniTerm::help() { } -MyTerm::MyTerm(QWidget *parent, const char* name) - : QMultiLineEdit(parent, name) +MyTerm::MyTerm(TQWidget *parent, const char* name) + : TQMultiLineEdit(parent, name) { setFont(KGlobalSettings::fixedFont()); } -void MyTerm::keyPressEvent(QKeyEvent *k) { +void MyTerm::keyPressEvent(TQKeyEvent *k) { // ignore meta keys if (k->ascii() == 0) return; @@ -244,22 +244,22 @@ void MyTerm::keyPressEvent(QKeyEvent *k) { void MyTerm::insertChar(unsigned char c) { - QMultiLineEdit::insert(QChar(c)); + TQMultiLineEdit::insert(TQChar(c)); } void MyTerm::newLine() { - QMultiLineEdit::newLine(); + TQMultiLineEdit::newLine(); } void MyTerm::del() { - QMultiLineEdit::del(); + TQMultiLineEdit::del(); } void MyTerm::backspace() { - QMultiLineEdit::backspace(); + TQMultiLineEdit::backspace(); } @@ -269,13 +269,13 @@ void MyTerm::myreturn() { getCursorPosition(&line,&column); for (int i = 0; i < column;i++) - QMultiLineEdit::cursorLeft(); + TQMultiLineEdit::cursorLeft(); } void MyTerm::mynewline() { - QMultiLineEdit::end(FALSE); - QMultiLineEdit::newLine(); + TQMultiLineEdit::end(FALSE); + TQMultiLineEdit::newLine(); } #include "miniterm.moc" -- cgit v1.2.1