From 97d1732e257f8700488d7ca1660ae7eba8fc6065 Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Thu, 15 Dec 2011 15:47:36 -0600 Subject: Rename a number of old tq methods that are no longer tq specific --- kbattleship/CLIENTS | 2 +- kbattleship/kbattleship/dialogs/connectDlg.ui | 6 +++--- kbattleship/kbattleship/dialogs/serverDlg.ui | 4 ++-- kbattleship/kbattleship/dialogs/statDlg.ui | 20 ++++++++++---------- kbattleship/kbattleship/kbattleship.cpp | 14 +++++++------- kbattleship/kbattleship/kbattleshipserver.cpp | 2 +- kbattleship/kbattleship/kbattleshipview.cpp | 10 +++++----- kbattleship/kbattleship/kclientdialog.cpp | 4 ++-- kbattleship/kbattleship/konnectionhandling.cpp | 8 ++++---- kbattleship/kbattleship/kserverdialog.cpp | 2 +- 10 files changed, 36 insertions(+), 36 deletions(-) (limited to 'kbattleship') diff --git a/kbattleship/CLIENTS b/kbattleship/CLIENTS index 54c82ec3..393dda40 100644 --- a/kbattleship/CLIENTS +++ b/kbattleship/CLIENTS @@ -1,6 +1,6 @@ Information about other KBattleship-compatible clients: -Client OS tqStatus Homepage/Screenshots +Client OS Status Homepage/Screenshots KBattleship Linux/KDE 100% http://games.kde.org/kbattleship Mac KBattleship Mac OS + Mac OS X 100% http://www.sebek.de/ diff --git a/kbattleship/kbattleship/dialogs/connectDlg.ui b/kbattleship/kbattleship/dialogs/connectDlg.ui index 2bf0e8d5..40ec9609 100644 --- a/kbattleship/kbattleship/dialogs/connectDlg.ui +++ b/kbattleship/kbattleship/dialogs/connectDlg.ui @@ -38,7 +38,7 @@ &Nick name: - + AlignVCenter|AlignLeft @@ -73,7 +73,7 @@ &Server: - + AlignVCenter|AlignLeft @@ -135,7 +135,7 @@ &Port: - + AlignVCenter|AlignLeft diff --git a/kbattleship/kbattleship/dialogs/serverDlg.ui b/kbattleship/kbattleship/dialogs/serverDlg.ui index e1888e8d..daf40894 100644 --- a/kbattleship/kbattleship/dialogs/serverDlg.ui +++ b/kbattleship/kbattleship/dialogs/serverDlg.ui @@ -63,7 +63,7 @@ &Port: - + AlignVCenter|AlignLeft @@ -95,7 +95,7 @@ &Nick name: - + AlignVCenter|AlignLeft diff --git a/kbattleship/kbattleship/dialogs/statDlg.ui b/kbattleship/kbattleship/dialogs/statDlg.ui index feea1778..dc863d24 100644 --- a/kbattleship/kbattleship/dialogs/statDlg.ui +++ b/kbattleship/kbattleship/dialogs/statDlg.ui @@ -32,7 +32,7 @@ Expanding - + 20 20 @@ -63,7 +63,7 @@ Expanding - + 20 20 @@ -97,7 +97,7 @@ : - + AlignCenter @@ -116,7 +116,7 @@ 0 - + AlignVCenter|AlignRight @@ -132,7 +132,7 @@ Expanding - + 20 20 @@ -151,7 +151,7 @@ Expanding - + 20 20 @@ -224,7 +224,7 @@ Expanding - + 20 20 @@ -315,7 +315,7 @@ Expanding - + 20 20 @@ -403,7 +403,7 @@ Expanding - + 20 20 @@ -441,7 +441,7 @@ Expanding - + 20 20 diff --git a/kbattleship/kbattleship/kbattleship.cpp b/kbattleship/kbattleship/kbattleship.cpp index 62952b19..eb624bf5 100644 --- a/kbattleship/kbattleship/kbattleship.cpp +++ b/kbattleship/kbattleship/kbattleship.cpp @@ -15,7 +15,7 @@ * * ***************************************************************************/ -#include +#include #include #include @@ -84,8 +84,8 @@ void KBattleshipWindow::initStatusBar() { m_ownNickname = "-"; m_enemyNickname = "-"; - statusBar()->insertItem(i18n(" Player 1: %1 ").tqarg(m_ownNickname), ID_PLAYER_OWN, 0, true); - statusBar()->insertItem(i18n(" Player 2: %1 ").tqarg(m_enemyNickname), ID_PLAYER_ENEMY, 0, true); + statusBar()->insertItem(i18n(" Player 1: %1 ").arg(m_ownNickname), ID_PLAYER_OWN, 0, true); + statusBar()->insertItem(i18n(" Player 2: %1 ").arg(m_enemyNickname), ID_PLAYER_ENEMY, 0, true); statusBar()->insertItem(i18n("Ready"), ID_STATUS_MSG, 1); statusBar()->setItemAlignment(ID_STATUS_MSG, AlignLeft); } @@ -1075,14 +1075,14 @@ void KBattleshipWindow::parseCommandLine() { if( !u.isValid()) { KMessageBox::sorry(this, i18n("The URL passed to KDE Battleship '%1' is not a valid url") - .tqarg(args->arg(0))); + .arg(args->arg(0))); return; } if( u.protocol() != "kbattleship" ) { KMessageBox::sorry(this, i18n("The URL passed to KDE Battleship '%1' is not recognised " "as a Battleship game.") - .tqarg(args->arg(0))); + .arg(args->arg(0))); return; } @@ -1198,13 +1198,13 @@ void KBattleshipWindow::slotStatusMsg(const TQString &text) void KBattleshipWindow::slotChangeOwnPlayer(const TQString &text) { statusBar()->clear(); - statusBar()->changeItem(i18n(" Player 1: %1 ").tqarg(text), ID_PLAYER_OWN); + statusBar()->changeItem(i18n(" Player 1: %1 ").arg(text), ID_PLAYER_OWN); } void KBattleshipWindow::slotChangeEnemyPlayer(const TQString &text) { statusBar()->clear(); - statusBar()->changeItem(i18n(" Player 2: %1 ").tqarg(text), ID_PLAYER_ENEMY); + statusBar()->changeItem(i18n(" Player 2: %1 ").arg(text), ID_PLAYER_ENEMY); } void KBattleshipWindow::slotSinglePlayer() diff --git a/kbattleship/kbattleship/kbattleshipserver.cpp b/kbattleship/kbattleship/kbattleshipserver.cpp index 7b10d4fd..85e90ffa 100644 --- a/kbattleship/kbattleship/kbattleshipserver.cpp +++ b/kbattleship/kbattleship/kbattleshipserver.cpp @@ -41,7 +41,7 @@ void KBattleshipServer::init() { if(listen()) { - KMessageBox::error(0L, i18n("Failed to bind to local port \"%1\"\n\nPlease check if another KBattleship server instance\nis running or another application uses this port.").tqarg(m_port)); + KMessageBox::error(0L, i18n("Failed to bind to local port \"%1\"\n\nPlease check if another KBattleship server instance\nis running or another application uses this port.").arg(m_port)); emit sigServerFailure(); return; } diff --git a/kbattleship/kbattleship/kbattleshipview.cpp b/kbattleship/kbattleship/kbattleshipview.cpp index 3e70a2a4..e938b77c 100644 --- a/kbattleship/kbattleship/kbattleshipview.cpp +++ b/kbattleship/kbattleship/kbattleshipview.cpp @@ -15,7 +15,7 @@ * * ***************************************************************************/ -#include +#include #include #include @@ -106,11 +106,11 @@ void KBattleshipView::drawEnemyShipsHuman(KMessage *msg, KShipList *list) int posx, posy, placedLeft; bool left; int i = 3; - while (!msg->field(TQString("ship%1").tqarg(i)).isNull()) + while (!msg->field(TQString("ship%1").arg(i)).isNull()) { - posx = msg->field(TQString("ship%1").tqarg(i)).section(" ", 0, 0).toInt(); - posy = msg->field(TQString("ship%1").tqarg(i)).section(" ", 1, 1).toInt(); - placedLeft = msg->field(TQString("ship%1").tqarg(i)).section(" ", 2, 2).toInt(); + posx = msg->field(TQString("ship%1").arg(i)).section(" ", 0, 0).toInt(); + posy = msg->field(TQString("ship%1").arg(i)).section(" ", 1, 1).toInt(); + placedLeft = msg->field(TQString("ship%1").arg(i)).section(" ", 2, 2).toInt(); if (placedLeft == 0) left = false; else left = true; list->addNewShip(!left, posx, posy); diff --git a/kbattleship/kbattleship/kclientdialog.cpp b/kbattleship/kbattleship/kclientdialog.cpp index f52e9472..be8c8f4f 100644 --- a/kbattleship/kbattleship/kclientdialog.cpp +++ b/kbattleship/kbattleship/kclientdialog.cpp @@ -21,7 +21,7 @@ #include #include #include -#include +#include #include "kbattleshipserver.h" // for BATTLESHIP_SERVICE #include "kclientdialog.moc" @@ -42,7 +42,7 @@ KClientDialog::KClientDialog(TQWidget *parent, const char *name) connect(m_mainWidget->serverEdit, TQT_SIGNAL(textChanged(const TQString &)), this, TQT_SLOT(slotCheckEnableOk())); m_config->setGroup("History"); - m_browser = new DNSSD::ServiceBrowser(TQString::tqfromLatin1(BATTLESHIP_SERVICE)); + m_browser = new DNSSD::ServiceBrowser(TQString::fromLatin1(BATTLESHIP_SERVICE)); connect(m_browser,TQT_SIGNAL(finished()),TQT_SLOT(nextBatch())); m_browser->startBrowse(); connect(m_mainWidget->lanBox,TQT_SIGNAL(activated(int)),TQT_SLOT(gameSelected(int))); diff --git a/kbattleship/kbattleship/konnectionhandling.cpp b/kbattleship/kbattleship/konnectionhandling.cpp index 45a2a452..5d5c1026 100644 --- a/kbattleship/kbattleship/konnectionhandling.cpp +++ b/kbattleship/kbattleship/konnectionhandling.cpp @@ -94,7 +94,7 @@ void KonnectionHandling::slotNewMessage(KMessage *msg) case KMessage::DISCARD: if(msg->field("kmversion") == TQString("true")) { - KMessageBox::error(0L, i18n("Connection dropped by enemy. The client's protocol implementation (%1) is not compatible with our (%2) version.").tqarg(msg->field("reason")).tqarg(protocolVersion)); + KMessageBox::error(0L, i18n("Connection dropped by enemy. The client's protocol implementation (%1) is not compatible with our (%2) version.").arg(msg->field("reason")).arg(protocolVersion)); emit sigAbortNetworkGame(); } else @@ -156,10 +156,10 @@ void KonnectionHandling::slotNewMessage(KMessage *msg) { // First message....got client information case KMessage::GETVERSION: - if(msg->field("protocolVersion") != TQString::tqfromLatin1(protocolVersion)) + if(msg->field("protocolVersion") != TQString::fromLatin1(protocolVersion)) { m_kbserver->slotDiscardClient(protocolVersion, true, false); - KMessageBox::error(0L, i18n("Connection to client dropped. The client's protocol implementation (%1) is not compatible with our (%2) version.").tqarg(msg->field("protocolVersion")).tqarg(protocolVersion)); + KMessageBox::error(0L, i18n("Connection to client dropped. The client's protocol implementation (%1) is not compatible with our (%2) version.").arg(msg->field("protocolVersion")).arg(protocolVersion)); } else emit sigClientInformation(msg->field("clientName"), msg->field("clientVersion"), msg->field("clientDescription"), msg->field("protocolVersion")); @@ -232,7 +232,7 @@ void KonnectionHandling::slotSocketError(int error) break; default: - KMessageBox::error(0L, i18n("Unknown error; No: %1").tqarg(error)); + KMessageBox::error(0L, i18n("Unknown error; No: %1").arg(error)); break; } diff --git a/kbattleship/kbattleship/kserverdialog.cpp b/kbattleship/kbattleship/kserverdialog.cpp index d8fa1b1d..72b53695 100644 --- a/kbattleship/kbattleship/kserverdialog.cpp +++ b/kbattleship/kbattleship/kserverdialog.cpp @@ -17,7 +17,7 @@ #include #include -#include +#include #include "kserverdialog.h" -- cgit v1.2.1