summaryrefslogtreecommitdiffstats
path: root/kppp/kpppwidget.cpp
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 /kppp/kpppwidget.cpp
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 'kppp/kpppwidget.cpp')
-rw-r--r--kppp/kpppwidget.cpp260
1 files changed, 130 insertions, 130 deletions
diff --git a/kppp/kpppwidget.cpp b/kppp/kpppwidget.cpp
index 9572efbf..2006489e 100644
--- a/kppp/kpppwidget.cpp
+++ b/kppp/kpppwidget.cpp
@@ -24,16 +24,16 @@
#include "kpppwidget.h"
-#include <qapplication.h>
-#include <qcombobox.h>
-#include <qdir.h>
-#include <qevent.h>
-#include <qdialog.h>
-#include <qlabel.h>
-#include <qpushbutton.h>
-#include <qregexp.h>
+#include <tqapplication.h>
+#include <tqcombobox.h>
+#include <tqdir.h>
+#include <tqevent.h>
+#include <tqdialog.h>
+#include <tqlabel.h>
+#include <tqpushbutton.h>
+#include <tqregexp.h>
#include <kdialogbase.h>
-#include <qwhatsthis.h>
+#include <tqwhatsthis.h>
#include <kaboutdata.h>
#include <kapplication.h>
@@ -74,8 +74,8 @@
extern KPPPWidget *p_kppp;
-KPPPWidget::KPPPWidget( QWidget *parent, const char *name )
- : DCOPObject( "KpppIface" ), QWidget(parent, name)
+KPPPWidget::KPPPWidget( TQWidget *parent, const char *name )
+ : DCOPObject( "KpppIface" ), TQWidget(parent, name)
, acct(0)
, m_bCmdlAccount (false)
, m_bCmdlModem (false)
@@ -90,45 +90,45 @@ KPPPWidget::KPPPWidget( QWidget *parent, const char *name )
installEventFilter(this);
- QVBoxLayout *tl = new QVBoxLayout(this, 10, 10);
+ TQVBoxLayout *tl = new TQVBoxLayout(this, 10, 10);
- l1 = new QGridLayout(4, 4);
+ l1 = new TQGridLayout(4, 4);
tl->addLayout(l1);
l1->addColSpacing(0, 10);
l1->addColSpacing(3, 10);
l1->setColStretch(1, 3);
l1->setColStretch(2, 4);
- label1 = new QLabel(i18n("C&onnect to: "), this);
+ label1 = new TQLabel(i18n("C&onnect to: "), this);
l1->addWidget(label1, 0, 1);
- connectto_c = new QComboBox(false, this);
+ connectto_c = new TQComboBox(false, this);
label1->setBuddy(connectto_c);
- connect(connectto_c, SIGNAL(activated(int)),
- SLOT(newdefaultaccount(int)));
+ connect(connectto_c, TQT_SIGNAL(activated(int)),
+ TQT_SLOT(newdefaultaccount(int)));
l1->addWidget(connectto_c, 0, 2);
- label7 = new QLabel(i18n("Use &modem: "), this);
+ label7 = new TQLabel(i18n("Use &modem: "), this);
// l1->addWidget(label7, 1, 1); (done in resetmodems())
- modem_c = new QComboBox(false, this);
+ modem_c = new TQComboBox(false, this);
label7->setBuddy(connectto_c);
m_bModemCShown = false;
- connect(modem_c, SIGNAL(activated(int)),
- SLOT(newdefaultmodem(int)));
+ connect(modem_c, TQT_SIGNAL(activated(int)),
+ TQT_SLOT(newdefaultmodem(int)));
// l1->addWidget(modem_c, 1, 2); (done in resetmodems())
- ID_Label = new QLabel(i18n("&Login ID:"), this);
+ ID_Label = new TQLabel(i18n("&Login ID:"), this);
l1->addWidget(ID_Label, 2, 1);
// the entry line for usernames
- ID_Edit = new QLineEdit(this);
+ ID_Edit = new TQLineEdit(this);
ID_Label->setBuddy(ID_Edit);
l1->addWidget(ID_Edit, 2, 2);
- connect(ID_Edit, SIGNAL(returnPressed()),
- this, SLOT(enterPressedInID()));
- QString tmp = i18n("<p>Type in the username that you got from your\n"
+ connect(ID_Edit, TQT_SIGNAL(returnPressed()),
+ this, TQT_SLOT(enterPressedInID()));
+ TQString tmp = i18n("<p>Type in the username that you got from your\n"
"ISP. This is especially important for PAP\n"
"and CHAP. You may omit this when you use\n"
"terminal-based or script-based authentication.\n"
@@ -136,18 +136,18 @@ KPPPWidget::KPPPWidget( QWidget *parent, const char *name )
"<b>Important</b>: case is important here:\n"
"<i>myusername</i> is not the same as <i>MyUserName</i>.");
- QWhatsThis::add(ID_Label,tmp);
- QWhatsThis::add(ID_Edit,tmp);
+ TQWhatsThis::add(ID_Label,tmp);
+ TQWhatsThis::add(ID_Edit,tmp);
- PW_Label = new QLabel(i18n("&Password:"), this);
+ PW_Label = new TQLabel(i18n("&Password:"), this);
l1->addWidget(PW_Label, 3, 1);
- PW_Edit= new QLineEdit(this);
+ PW_Edit= new TQLineEdit(this);
PW_Label->setBuddy(PW_Edit);
- PW_Edit->setEchoMode(QLineEdit::Password);
+ PW_Edit->setEchoMode(TQLineEdit::Password);
l1->addWidget(PW_Edit, 3, 2);
- connect(PW_Edit, SIGNAL(returnPressed()),
- this, SLOT(enterPressedInPW()));
+ connect(PW_Edit, TQT_SIGNAL(returnPressed()),
+ this, TQT_SLOT(enterPressedInPW()));
tmp = i18n("<p>Type in the password that you got from your\n"
"ISP. This is especially important for PAP\n"
@@ -157,21 +157,21 @@ KPPPWidget::KPPPWidget( QWidget *parent, const char *name )
"<b>Important</b>: case is important here:\n"
"<i>mypassword</i> is not the same as <i>MyPassword</i>.");
- QWhatsThis::add(PW_Label,tmp);
- QWhatsThis::add(PW_Edit,tmp);
+ TQWhatsThis::add(PW_Label,tmp);
+ TQWhatsThis::add(PW_Edit,tmp);
- QHBoxLayout *l3 = new QHBoxLayout;
+ TQHBoxLayout *l3 = new QHBoxLayout;
tl->addSpacing(5);
tl->addLayout(l3);
tl->addSpacing(5);
l3->addSpacing(10);
- log = new QCheckBox(i18n("Show lo&g window"), this);
- connect(log, SIGNAL(toggled(bool)),
- this, SLOT(log_window_toggled(bool)));
+ log = new TQCheckBox(i18n("Show lo&g window"), this);
+ connect(log, TQT_SIGNAL(toggled(bool)),
+ this, TQT_SLOT(log_window_toggled(bool)));
log->setChecked(gpppdata.get_show_log_window());
l3->addWidget(log);
- QWhatsThis::add(log,
+ TQWhatsThis::add(log,
i18n("<p>This controls whether a log window is shown.\n"
"A log window shows the communication between\n"
"<i>kppp</i> and your modem. This will help you\n"
@@ -183,17 +183,17 @@ KPPPWidget::KPPPWidget( QWidget *parent, const char *name )
fline = new KSeparator( KSeparator::HLine, this);
tl->addWidget(fline);
- QHBoxLayout *l2 = new QHBoxLayout;
+ TQHBoxLayout *l2 = new QHBoxLayout;
tl->addLayout(l2);
int minw = 0;
quit_b = new KPushButton(KStdGuiItem::quit(), this);
- connect( quit_b, SIGNAL(clicked()), SLOT(quitbutton()));
+ connect( quit_b, TQT_SIGNAL(clicked()), TQT_SLOT(quitbutton()));
if(quit_b->sizeHint().width() > minw)
minw = quit_b->sizeHint().width();
setup_b = new KPushButton(KGuiItem(i18n("Co&nfigure..."), "configure"), this);
- connect( setup_b, SIGNAL(clicked()), SLOT(expandbutton()));
+ connect( setup_b, TQT_SIGNAL(clicked()), TQT_SLOT(expandbutton()));
if(setup_b->sizeHint().width() > minw)
minw = setup_b->sizeHint().width();
@@ -201,18 +201,18 @@ KPPPWidget::KPPPWidget( QWidget *parent, const char *name )
setup_b->setEnabled(false);
help_b = new KPushButton(KStdGuiItem::help(), this);
- connect( help_b, SIGNAL(clicked()), SLOT(helpbutton()));
+ connect( help_b, TQT_SIGNAL(clicked()), TQT_SLOT(helpbutton()));
KHelpMenu *helpMenu = new KHelpMenu(this, KGlobal::instance()->aboutData(), true);
- help_b->setPopup((QPopupMenu*)helpMenu->menu());
+ help_b->setPopup((TQPopupMenu*)helpMenu->menu());
if(help_b->sizeHint().width() > minw)
minw = help_b->sizeHint().width();
- connect_b = new QPushButton(i18n("&Connect"), this);
+ connect_b = new TQPushButton(i18n("&Connect"), this);
connect_b->setDefault(true);
connect_b->setFocus();
- connect(connect_b, SIGNAL(clicked()), SLOT(beginConnect()));
+ connect(connect_b, TQT_SIGNAL(clicked()), TQT_SLOT(beginConnect()));
if(connect_b->sizeHint().width() > minw)
minw = connect_b->sizeHint().width();
@@ -233,7 +233,7 @@ KPPPWidget::KPPPWidget( QWidget *parent, const char *name )
// we also connect cmld_start to the beginConnect so that I can run
// the dialer through a command line argument
- connect(this,SIGNAL(cmdl_start()),this,SLOT(beginConnect()));
+ connect(this,TQT_SIGNAL(cmdl_start()),this,TQT_SLOT(beginConnect()));
stats = new PPPStats;
@@ -256,28 +256,28 @@ KPPPWidget::KPPPWidget( QWidget *parent, const char *name )
resetmodems();
con = new ConnectWidget(0, "con", stats);
KWin::setIcons(con->winId(), kapp->icon(), kapp->miniIcon() );
- connect(this, SIGNAL(begin_connect()),con, SLOT(preinit()));
+ connect(this, TQT_SIGNAL(begin_connect()),con, TQT_SLOT(preinit()));
- QRect desk = KGlobalSettings::desktopGeometry(topLevelWidget());
+ TQRect desk = KGlobalSettings::desktopGeometry(topLevelWidget());
con->setGeometry(desk.center().x()-175, desk.center().y()-55, 350,110);
// connect the ConnectWidgets various signals
- connect(con, SIGNAL(closeDebugWindow()),
- debugwindow, SLOT(hide()));
- connect(con, SIGNAL(debugMessage(const QString &)),
- debugwindow, SLOT(statusLabel(const QString &)));
- connect(con, SIGNAL(toggleDebugWindow()),
- debugwindow, SLOT(toggleVisibility()));
- connect(con, SIGNAL(debugPutChar(unsigned char)),
- debugwindow, SLOT(addChar(unsigned char)));
- connect(con, SIGNAL(startAccounting()),
- this, SLOT(startAccounting()));
- connect(con, SIGNAL(stopAccounting()),
- this, SLOT(stopAccounting()));
- connect(KApplication::kApplication(), SIGNAL(saveYourself()),
- this, SLOT(saveMyself()));
- connect(KApplication::kApplication(), SIGNAL(shutDown()),
- this, SLOT(shutDown()));
+ connect(con, TQT_SIGNAL(closeDebugWindow()),
+ debugwindow, TQT_SLOT(hide()));
+ connect(con, TQT_SIGNAL(debugMessage(const TQString &)),
+ debugwindow, TQT_SLOT(statusLabel(const TQString &)));
+ connect(con, TQT_SIGNAL(toggleDebugWindow()),
+ debugwindow, TQT_SLOT(toggleVisibility()));
+ connect(con, TQT_SIGNAL(debugPutChar(unsigned char)),
+ debugwindow, TQT_SLOT(addChar(unsigned char)));
+ connect(con, TQT_SIGNAL(startAccounting()),
+ this, TQT_SLOT(startAccounting()));
+ connect(con, TQT_SIGNAL(stopAccounting()),
+ this, TQT_SLOT(stopAccounting()));
+ connect(KApplication::kApplication(), TQT_SIGNAL(saveYourself()),
+ this, TQT_SLOT(saveMyself()));
+ connect(KApplication::kApplication(), TQT_SIGNAL(shutDown()),
+ this, TQT_SLOT(shutDown()));
debugwindow->setGeometry(desk.center().x()+190, desk.center().y()-55,
debugwindow->width(),debugwindow->height());
@@ -304,7 +304,7 @@ KPPPWidget::KPPPWidget( QWidget *parent, const char *name )
if(m_bCmdlModem){
bool result = gpppdata.setModem(m_strCmdlModem);
if (!result){
- QString string;
+ TQString string;
string = i18n("No such Modem:\n%1\nFalling back to default").arg(m_strCmdlModem);
KMessageBox::error(this, string);
m_bCmdlModem = false;
@@ -314,7 +314,7 @@ KPPPWidget::KPPPWidget( QWidget *parent, const char *name )
if(m_bCmdlAccount){
bool result = gpppdata.setAccount(m_strCmdlAccount);
if (!result){
- QString string;
+ TQString string;
string = i18n("No such Account:\n%1").arg(m_strCmdlAccount);
KMessageBox::error(this, string);
m_bCmdlAccount = false;
@@ -341,8 +341,8 @@ KPPPWidget::KPPPWidget( QWidget *parent, const char *name )
// this timer will delay the actual disconnection DISCONNECTION_DELAY ms
// to give applications time to shutdown, logout, whatever..
- disconnectTimer = new QTimer(this);
- connect(disconnectTimer, SIGNAL(timeout()), this, SLOT(delayedDisconnect()));
+ disconnectTimer = new TQTimer(this);
+ connect(disconnectTimer, TQT_SIGNAL(timeout()), this, TQT_SLOT(delayedDisconnect()));
}
KPPPWidget::~KPPPWidget()
@@ -350,8 +350,8 @@ KPPPWidget::~KPPPWidget()
delete stats;
}
-bool KPPPWidget::eventFilter(QObject *o, QEvent *e) {
- if(e->type() == QEvent::User) {
+bool KPPPWidget::eventFilter(TQObject *o, TQEvent *e) {
+ if(e->type() == TQEvent::User) {
switch(((SignalEvent*)e)->sigType()) {
case SIGINT:
kdDebug(5002) << "Received a SIGINT" << endl;
@@ -368,8 +368,8 @@ bool KPPPWidget::eventFilter(QObject *o, QEvent *e) {
}
if(o == connect_b) {
- if(e->type() == QEvent::KeyPress) {
- if(connect_b->hasFocus() && ((QKeyEvent *)e)->key() == Qt::Key_Return) {
+ if(e->type() == TQEvent::KeyPress) {
+ if(connect_b->hasFocus() && ((TQKeyEvent *)e)->key() == Qt::Key_Return) {
beginConnect();
return true;
}
@@ -391,16 +391,16 @@ void KPPPWidget::prepareSetupDialog() {
// tabWindow->setFixedSize( 365, 375 );
accounts = new AccountWidget(tabWindow->addPage( i18n("&Accounts"), i18n("Account Setup") ) );
- connect(accounts, SIGNAL(resetaccounts()),
- this, SLOT(resetaccounts()));
- connect(accounts, SIGNAL(resetCosts(const QString &)),
- this, SLOT(resetCosts(const QString &)));
- connect(accounts, SIGNAL(resetVolume(const QString &)),
- this, SLOT(resetVolume(const QString &)));
+ connect(accounts, TQT_SIGNAL(resetaccounts()),
+ this, TQT_SLOT(resetaccounts()));
+ connect(accounts, TQT_SIGNAL(resetCosts(const TQString &)),
+ this, TQT_SLOT(resetCosts(const TQString &)));
+ connect(accounts, TQT_SIGNAL(resetVolume(const TQString &)),
+ this, TQT_SLOT(resetVolume(const TQString &)));
modems = new ModemsWidget(tabWindow->addPage( i18n("&Modems"), i18n("Modems Setup") ) );
- connect(modems, SIGNAL(resetmodems()),
- this, SLOT(resetmodems()));
+ connect(modems, TQT_SIGNAL(resetmodems()),
+ this, TQT_SLOT(resetmodems()));
graph = new GraphSetup( tabWindow->addPage( i18n("&Graph"), i18n("Throughput Graph" ) ) );
general = new GeneralWidget( tabWindow->addPage( i18n("M&isc"), i18n("Miscellaneous Settings") ) );
@@ -476,11 +476,11 @@ void KPPPWidget::resetaccounts() {
PW_Edit->setText(gpppdata.storedPassword());
}
- connect(ID_Edit, SIGNAL(textChanged(const QString &)),
- this, SLOT(usernameChanged(const QString &)));
+ connect(ID_Edit, TQT_SIGNAL(textChanged(const TQString &)),
+ this, TQT_SLOT(usernameChanged(const TQString &)));
- connect(PW_Edit, SIGNAL(textChanged(const QString &)),
- this, SLOT(passwordChanged(const QString &)));
+ connect(PW_Edit, TQT_SIGNAL(textChanged(const TQString &)),
+ this, TQT_SLOT(passwordChanged(const TQString &)));
if (ID_Edit->text().isEmpty())
ID_Edit->setFocus();
@@ -580,10 +580,10 @@ void KPPPWidget::sigPPPDDied() {
// stop the disconnect timer (just in case)
disconnectTimer->stop();
// signal other applications that we are disconnected now
- kapp->dcopClient()->emitDCOPSignal("KpppIface", "disconnected()", QByteArray());
+ kapp->dcopClient()->emitDCOPSignal("KpppIface", "disconnected()", TQByteArray());
kdDebug(5002) << "Executing command on disconnect since pppd has died." << endl;
- QApplication::flushX();
+ TQApplication::flushX();
execute_command(gpppdata.command_on_disconnect());
stopAccounting();
@@ -611,7 +611,7 @@ void KPPPWidget::sigPPPDDied() {
gpppdata.setpppdRunning(false);
// // not in a signal handler !!! KNotifyClient::beep();
- QString msg;
+ TQString msg;
if (gpppdata.pppdError() == E_IF_TIMEOUT)
msg = i18n("Timeout expired while waiting for the PPP interface "
"to come up.");
@@ -661,7 +661,7 @@ void KPPPWidget::sigChld() {
// if(id == helperPid && helperPid != -1) {
// kdDebug(5002) << "It was the setuid child that died" << endl;
// helperPid = -1;
- QString msg = i18n("kppp's helper process just died.\n"
+ TQString msg = i18n("kppp's helper process just died.\n"
"Since further execution would be pointless, "
"kppp will shut down now.");
KMessageBox::error(0L, msg);
@@ -700,7 +700,7 @@ void KPPPWidget::beginConnect() {
gpppdata.setPassword(gpppdata.storedPassword());
}
- QFileInfo info(pppdPath());
+ TQFileInfo info(pppdPath());
if(!info.exists()){
KMessageBox::error(this, i18n("Cannot find the PPP daemon!\n"
@@ -711,7 +711,7 @@ void KPPPWidget::beginConnect() {
#if 0
if(!info.isExecutable()){
- QString string;
+ TQString string;
string = i18n("kppp cannot execute:\n %1\n"
"Please make sure that you have given kppp "
"setuid permission and that "
@@ -723,16 +723,16 @@ void KPPPWidget::beginConnect() {
#endif
KCmdLineArgs *args = KCmdLineArgs::parsedArgs();
- QString device = "";
+ TQString device = "";
if (args->isSet("dev"))
device = args->getOption("dev");
else
device = gpppdata.modemDevice();
- QFileInfo info2(device);
+ TQFileInfo info2(device);
if(!info2.exists()){
- QString string;
+ TQString string;
string = i18n("kppp can not find:\n %1\nPlease make sure you have setup "
"your modem device properly "
"and/or adjust the location of the modem device on "
@@ -758,7 +758,7 @@ void KPPPWidget::beginConnect() {
if(!Requester::rq->setSecret(gpppdata.authMethod(),
encodeWord(gpppdata.storedUsername()),
encodeWord(gpppdata.password()))) {
- QString s;
+ TQString s;
s = i18n("Cannot create PAP/CHAP authentication\n"
"file \"%1\"").arg(PAP_AUTH_FILE);
KMessageBox::error(this, s);
@@ -768,14 +768,14 @@ void KPPPWidget::beginConnect() {
}
if (gpppdata.phonenumber().isEmpty()) {
- QString s = i18n("You must specify a telephone number.");
+ TQString s = i18n("You must specify a telephone number.");
KMessageBox::error(this, s);
return;
}
hide();
- QString tit = i18n("Connecting to: %1").arg(gpppdata.accname());
+ TQString tit = i18n("Connecting to: %1").arg(gpppdata.accname());
con->setCaption(tit);
con->enableButtons();
con->show();
@@ -797,7 +797,7 @@ void KPPPWidget::disconnect() {
if (disconnectTimer->isActive()) return; // you had already pressed disconnect before
// signal other applications that we are about to go offline now
- kapp->dcopClient()->emitDCOPSignal("KpppIface", "aboutToDisconnect()", QByteArray());
+ kapp->dcopClient()->emitDCOPSignal("KpppIface", "aboutToDisconnect()", TQByteArray());
con_win->hide();
con->show();
con->disableButtons(); // will reenable them later in delayedDisconnect()
@@ -807,7 +807,7 @@ void KPPPWidget::disconnect() {
con->setMsg(i18n("Executing command before disconnection."));
kapp->processEvents();
- QApplication::flushX();
+ TQApplication::flushX();
pid_t id = execute_command(gpppdata.command_before_disconnect());
int i, status;
@@ -835,9 +835,9 @@ void KPPPWidget::delayedDisconnect() {
Requester::rq->killPPPDaemon();
// signal other applications that we are disconnected now
- kapp->dcopClient()->emitDCOPSignal("KpppIface", "disconnected()", QByteArray());
+ kapp->dcopClient()->emitDCOPSignal("KpppIface", "disconnected()", TQByteArray());
- QApplication::flushX();
+ TQApplication::flushX();
execute_command(gpppdata.command_on_disconnect());
Requester::rq->removeSecret(AUTH_PAP);
@@ -879,9 +879,9 @@ void KPPPWidget::quitbutton() {
disconnectTimer->stop();
// signal other applications that we are disconnected now
- kapp->dcopClient()->emitDCOPSignal("KpppIface", "disconnected()", QByteArray());
+ kapp->dcopClient()->emitDCOPSignal("KpppIface", "disconnected()", TQByteArray());
- QApplication::flushX();
+ TQApplication::flushX();
execute_command(gpppdata.command_on_disconnect());
removedns();
Modem::modem->unlockdevice();
@@ -910,24 +910,24 @@ void KPPPWidget::startAccounting() {
if(!gpppdata.AcctEnabled())
return;
- QString d = AccountingBase::getAccountingFile(gpppdata.accountingFile());
+ TQString d = AccountingBase::getAccountingFile(gpppdata.accountingFile());
// if(::access(d.data(), X_OK) != 0)
acct = new Accounting(this, stats);
// else
// acct = new ExecutableAccounting(this);
// connect to the accounting object
- connect(acct, SIGNAL(changed(QString, QString)),
- con_win, SLOT(slotAccounting(QString, QString)));
+ connect(acct, TQT_SIGNAL(changed(TQString, TQString)),
+ con_win, TQT_SLOT(slotAccounting(TQString, TQString)));
if(!acct->loadRuleSet(gpppdata.accountingFile())) {
- QString s= i18n("Can not load the accounting "
+ TQString s= i18n("Can not load the accounting "
"ruleset \"%1\".").arg(gpppdata.accountingFile());
// starting the messagebox with a timer will prevent us
// from blocking the calling function ConnectWidget::timerEvent
ruleset_load_errmsg = s;
- QTimer::singleShot(0, this, SLOT(rulesetLoadError()));
+ TQTimer::singleShot(0, this, TQT_SLOT(rulesetLoadError()));
return;
} else
acct->slotStart();
@@ -958,13 +958,13 @@ void KPPPWidget::showStats() {
}
-void KPPPWidget::usernameChanged(const QString &) {
+void KPPPWidget::usernameChanged(const TQString &) {
// store username for later use
gpppdata.setStoredUsername(ID_Edit->text());
}
-void KPPPWidget::passwordChanged(const QString &) {
+void KPPPWidget::passwordChanged(const TQString &) {
// store the password if so requested
if(gpppdata.storePassword())
gpppdata.setStoredPassword(PW_Edit->text());
@@ -973,17 +973,17 @@ void KPPPWidget::passwordChanged(const QString &) {
}
-void KPPPWidget::setPW_Edit(const QString &pw) {
+void KPPPWidget::setPW_Edit(const TQString &pw) {
PW_Edit->setText(pw);
}
-void KPPPWidget::resetCosts(const QString &s) {
+void KPPPWidget::resetCosts(const TQString &s) {
AccountingBase::resetCosts(s);
}
-void KPPPWidget::resetVolume(const QString &s) {
+void KPPPWidget::resetVolume(const TQString &s) {
AccountingBase::resetVolume(s);
}
@@ -992,9 +992,9 @@ void KPPPWidget::resetVolume(const QString &s) {
* If we write the username and password to the secrets file
* we'll therefore have to escape back slashes.
*/
-QString KPPPWidget::encodeWord(const QString &s) {
- QString r = s;
- r.replace(QRegExp("\\"), "\\\\");
+TQString KPPPWidget::encodeWord(const TQString &s) {
+ TQString r = s;
+ r.replace(TQRegExp("\\"), "\\\\");
return r;
}
@@ -1010,21 +1010,21 @@ void KPPPWidget::showNews() {
*/
#define QUICKHELP_HINT "Hint_QuickHelp"
if(gpppdata.readNumConfig(GENERAL_GRP, QUICKHELP_HINT, 0) == 0) {
- QDialog dlg(0, 0, true);
+ TQDialog dlg(0, 0, true);
dlg.setCaption(i18n("Recent Changes in KPPP"));
- QVBoxLayout *tl = new QVBoxLayout(&dlg, 10, 10);
- QHBoxLayout *l1 = new QHBoxLayout(10);
- QVBoxLayout *l2 = new QVBoxLayout(10);
+ TQVBoxLayout *tl = new TQVBoxLayout(&dlg, 10, 10);
+ TQHBoxLayout *l1 = new TQHBoxLayout(10);
+ TQVBoxLayout *l2 = new TQVBoxLayout(10);
tl->addLayout(l1);
- QLabel *icon = new QLabel(&dlg);
+ TQLabel *icon = new TQLabel(&dlg);
icon->setPixmap(BarIcon("exclamation"));
icon->setFixedSize(icon->sizeHint());
l1->addWidget(icon);
l1->addLayout(l2);
- QLabel *l = new QLabel(i18n("From version 1.4.8 on, kppp has a new feature\n"
+ TQLabel *l = new TQLabel(i18n("From version 1.4.8 on, kppp has a new feature\n"
"called \"Quickhelp\". It's similar to a tooltip,\n"
"but you can activate it whenever you want.\n"
"\n"
@@ -1036,15 +1036,15 @@ void KPPPWidget::showNews() {
"To test it, right-click somewhere in this text."),
&dlg);
- QCheckBox *cb = new QCheckBox(i18n("Don't show this hint again"), &dlg);
+ TQCheckBox *cb = new TQCheckBox(i18n("Don't show this hint again"), &dlg);
cb->setFixedSize(cb->sizeHint());
KButtonBox *bbox = new KButtonBox(&dlg);
bbox->addStretch(1);
- QPushButton *ok = bbox->addButton(KStdGuiItem::ok());
+ TQPushButton *ok = bbox->addButton(KStdGuiItem::ok());
ok->setDefault(true);
- dlg.connect(ok, SIGNAL(clicked()),
- &dlg, SLOT(accept()));
+ dlg.connect(ok, TQT_SIGNAL(clicked()),
+ &dlg, TQT_SLOT(accept()));
bbox->addStretch(1);
bbox->layout();
@@ -1052,12 +1052,12 @@ void KPPPWidget::showNews() {
l2->addWidget(cb);
tl->addWidget(bbox);
- QString tmp = i18n("This is an example of <b>QuickHelp</b>.\n"
+ TQString tmp = i18n("This is an example of <b>QuickHelp</b>.\n"
"This window will stay open until you\n"
"click a mouse button or a press a key.\n");
- QWhatsThis::add(cb,tmp);
- QWhatsThis::add(l, tmp);
+ TQWhatsThis::add(cb,tmp);
+ TQWhatsThis::add(l, tmp);
dlg.exec();
if(cb->isChecked()) {