From 78735b180c2ba56fa1cf4fd578726d457626e80a Mon Sep 17 00:00:00 2001 From: Elvio Basello Date: Mon, 10 Jan 2011 18:36:59 +0000 Subject: killed some QString helpers. Pay attention to the localizations: format strings have changed!; updated translation files; git-svn-id: https://svn.kvirc.de/svn/trunk/kvirc@5328 17fca916-40b9-46aa-a4ea-0a15b648b75c --- src/modules/list/ListWindow.cpp | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) (limited to 'src/modules/list/ListWindow.cpp') diff --git a/src/modules/list/ListWindow.cpp b/src/modules/list/ListWindow.cpp index c45601b51..9497774f2 100644 --- a/src/modules/list/ListWindow.cpp +++ b/src/modules/list/ListWindow.cpp @@ -36,7 +36,6 @@ #include "KviOptions.h" #include "KviIrcConnection.h" #include "KviIrcConnection.h" -#include "KviQString.h" #include "KviTopicWidget.h" #include "KviConfigurationFile.h" #include "KviFileDialog.h" @@ -293,11 +292,9 @@ void ListWindow::connectionStateChange() m_pRequestButton->setEnabled(st == KviIrcContext::Connected); if(st == KviIrcContext::Connected) { - QString szTmp; - KviQString::sprintf(szTmp, - __tr2qs("Connected to %s (%s)"), - m_pConsole->connection()->currentServerName().toUtf8().data(), - m_pConsole->currentNetworkName().toUtf8().data()); + QString szTmp = QString(__tr2qs("Connected to %1 (%2)")).arg( + m_pConsole->connection()->currentServerName(), + m_pConsole->currentNetworkName()); m_pInfoLabel->setText(szTmp); } else { m_pInfoLabel->setText(__tr2qs("List cannot be requested: Not connected to a server")); @@ -323,7 +320,7 @@ QSize ListWindow::sizeHint() const void ListWindow::fillCaptionBuffers() { - KviQString::sprintf(m_szPlainTextCaption,__tr2qs("Channel List [IRC Context %u]"),m_pConsole->context()->id()); + m_szPlainTextCaption = QString(__tr2qs("Channel List [IRC Context %1]")).arg(m_pConsole->context()->id()); } void ListWindow::die() @@ -357,8 +354,7 @@ void ListWindow::exportList() szDate = date.toString(Qt::SystemLocaleDate); break; } - KviQString::sprintf(szFile,__tr2qs("Channel list for %Q - %Q"), - &(connection()->currentNetworkName()),&(szDate)); + szFile = QString(__tr2qs("Channel list for %1 - %2")).arg(connection()->currentNetworkName(),szDate); } else { szFile = __tr2qs("Channel list"); } -- cgit v1.3.1-10-gc9f91