summaryrefslogtreecommitdiffstats
path: root/kopete/protocols/irc
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-15 15:49:40 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-15 15:49:40 -0600
commit808e453c56036211f57482ed847d54aca01bba68 (patch)
tree75515d5768dea10d4fbe4cd772e0a89c1c4b3aa9 /kopete/protocols/irc
parentcd9b9ed7fd0ac8a75106148254aa58e2e5c04863 (diff)
downloadtdenetwork-808e453c56036211f57482ed847d54aca01bba68.tar.gz
tdenetwork-808e453c56036211f57482ed847d54aca01bba68.zip
Rename a number of old tq methods that are no longer tq specific
Diffstat (limited to 'kopete/protocols/irc')
-rw-r--r--kopete/protocols/irc/ircaccount.cpp90
-rw-r--r--kopete/protocols/irc/ircaccount.h2
-rw-r--r--kopete/protocols/irc/ircaddcontactpage.cpp2
-rw-r--r--kopete/protocols/irc/ircchannelcontact.cpp64
-rw-r--r--kopete/protocols/irc/ircchannelcontact.h4
-rw-r--r--kopete/protocols/irc/irccontact.cpp32
-rw-r--r--kopete/protocols/irc/irccontact.h2
-rw-r--r--kopete/protocols/irc/ircprotocol.cpp148
-rw-r--r--kopete/protocols/irc/ircprotocol.h6
-rw-r--r--kopete/protocols/irc/ircservercontact.cpp16
-rw-r--r--kopete/protocols/irc/ircservercontact.h2
-rw-r--r--kopete/protocols/irc/irctransferhandler.cpp2
-rw-r--r--kopete/protocols/irc/ircusercontact.cpp128
-rw-r--r--kopete/protocols/irc/ircusercontact.h2
-rw-r--r--kopete/protocols/irc/kcodecaction.cpp2
-rw-r--r--kopete/protocols/irc/ksparser.cpp24
-rw-r--r--kopete/protocols/irc/libkirc/kircengine.cpp40
-rw-r--r--kopete/protocols/irc/libkirc/kircengine.h12
-rw-r--r--kopete/protocols/irc/libkirc/kircengine_commands.cpp10
-rw-r--r--kopete/protocols/irc/libkirc/kircengine_ctcp.cpp30
-rw-r--r--kopete/protocols/irc/libkirc/kircengine_numericreplies.cpp2
-rw-r--r--kopete/protocols/irc/libkirc/kircentity.cpp6
-rw-r--r--kopete/protocols/irc/libkirc/kircmessage.cpp24
-rw-r--r--kopete/protocols/irc/libkirc/kircmessage.h2
-rw-r--r--kopete/protocols/irc/libkirc/kircmessageredirector.cpp6
-rw-r--r--kopete/protocols/irc/libkirc/kirctransfer.cpp4
-rw-r--r--kopete/protocols/irc/libkirc/kirctransfer.h6
-rw-r--r--kopete/protocols/irc/libkirc/kirctransferhandler.cpp2
-rw-r--r--kopete/protocols/irc/libkirc/ksslsocket.cpp4
-rw-r--r--kopete/protocols/irc/ui/channellist.cpp30
-rw-r--r--kopete/protocols/irc/ui/channellist.h4
-rw-r--r--kopete/protocols/irc/ui/channellistdialog.cpp2
-rw-r--r--kopete/protocols/irc/ui/ircadd.ui6
-rw-r--r--kopete/protocols/irc/ui/irceditaccount.ui34
-rw-r--r--kopete/protocols/irc/ui/irceditaccountwidget.cpp10
-rw-r--r--kopete/protocols/irc/ui/networkconfig.ui6
36 files changed, 383 insertions, 383 deletions
diff --git a/kopete/protocols/irc/ircaccount.cpp b/kopete/protocols/irc/ircaccount.cpp
index 9dbdfc4a..e9d88985 100644
--- a/kopete/protocols/irc/ircaccount.cpp
+++ b/kopete/protocols/irc/ircaccount.cpp
@@ -54,14 +54,14 @@
#include <knotifyclient.h>
#include <kpopupmenu.h>
-#include <tqlayout.h>
+#include <layout.h>
#include <tqtimer.h>
-const TQString IRCAccount::CONFIG_CODECMIB = TQString::tqfromLatin1("Codec");
-const TQString IRCAccount::CONFIG_NETWORKNAME = TQString::tqfromLatin1("NetworkName");
-const TQString IRCAccount::CONFIG_NICKNAME = TQString::tqfromLatin1("NickName");
-const TQString IRCAccount::CONFIG_USERNAME = TQString::tqfromLatin1("UserName");
-const TQString IRCAccount::CONFIG_REALNAME = TQString::tqfromLatin1("RealName");
+const TQString IRCAccount::CONFIG_CODECMIB = TQString::fromLatin1("Codec");
+const TQString IRCAccount::CONFIG_NETWORKNAME = TQString::fromLatin1("NetworkName");
+const TQString IRCAccount::CONFIG_NICKNAME = TQString::fromLatin1("NickName");
+const TQString IRCAccount::CONFIG_USERNAME = TQString::fromLatin1("UserName");
+const TQString IRCAccount::CONFIG_REALNAME = TQString::fromLatin1("RealName");
IRCAccount::IRCAccount(IRCProtocol *protocol, const TQString &accountId, const TQString &autoChan, const TQString& netName, const TQString &nickName)
: Kopete::PasswordedAccount(protocol, accountId, 0, true), autoConnect( autoChan ), commandSource(0)
@@ -79,7 +79,7 @@ IRCAccount::IRCAccount(IRCProtocol *protocol, const TQString &accountId, const T
for( TQMap< TQString, TQString >::ConstIterator it = replies.begin(); it != replies.end(); ++it )
m_engine->addCustomCtcp( it.key(), it.data() );
- TQString version=i18n("Kopete IRC Plugin %1 [http://kopete.kde.org]").tqarg(kapp->aboutData()->version());
+ TQString version=i18n("Kopete IRC Plugin %1 [http://kopete.kde.org]").arg(kapp->aboutData()->version());
m_engine->setVersionString( version );
TQObject::connect(m_engine, TQT_SIGNAL(successfullyChangedNick(const TQString &, const TQString &)),
@@ -100,8 +100,8 @@ IRCAccount::IRCAccount(IRCProtocol *protocol, const TQString &accountId, const T
TQObject::connect(m_engine, TQT_SIGNAL(incomingCtcpReply(const TQString &, const TQString &, const TQString &)),
this, TQT_SLOT( slotNewCtcpReply(const TQString&, const TQString &, const TQString &)));
- TQObject::connect(m_engine, TQT_SIGNAL(statusChanged(KIRC::Engine::tqStatus)),
- this, TQT_SLOT(engineStatusChanged(KIRC::Engine::tqStatus)));
+ TQObject::connect(m_engine, TQT_SIGNAL(statusChanged(KIRC::Engine::Status)),
+ this, TQT_SLOT(engineStatusChanged(KIRC::Engine::Status)));
TQObject::connect(m_engine, TQT_SIGNAL(incomingServerLoadTooHigh()),
this, TQT_SLOT(slotServerBusy()));
@@ -173,7 +173,7 @@ IRCAccount::IRCAccount(IRCProtocol *protocol, const TQString &accountId, const T
/* Could not find this host. Add it to the networks structure */
m_network = new IRCNetwork;
- m_network->name = i18n("Temporary Network - %1").tqarg( hostName );
+ m_network->name = i18n("Temporary Network - %1").arg( hostName );
m_network->description = i18n("Network imported from previous version of Kopete, or an IRC URI");
IRCHost *host = new IRCHost;
@@ -204,7 +204,7 @@ IRCAccount::IRCAccount(IRCProtocol *protocol, const TQString &accountId, const T
m_contactManager = new IRCContactManager(mNickName, this);
setMyself( m_contactManager->mySelf() );
- setAccountLabel( TQString::tqfromLatin1("%1@%2").tqarg(mNickName,networkName) );
+ setAccountLabel( TQString::fromLatin1("%1@%2").arg(mNickName,networkName) );
m_myServer = m_contactManager->myServer();
m_joinChannelAction = new KAction ( i18n("Join Channel..."), TQString(), 0, this,
@@ -226,7 +226,7 @@ void IRCAccount::slotNickInUse( const TQString &nick )
{
TQString newNick = KInputDialog::getText(
i18n("IRC Plugin"),
- i18n("The nickname %1 is already in use. Please enter an alternate nickname:").tqarg(nick),
+ i18n("The nickname %1 is already in use. Please enter an alternate nickname:").arg(nick),
nick);
if (newNick.isNull())
@@ -243,23 +243,23 @@ void IRCAccount::slotNickInUse( const TQString &nick )
void IRCAccount::slotNickInUseAlert( const TQString &nick )
{
- KMessageBox::error(Kopete::UI::Global::mainWidget(), i18n("The nickname %1 is already in use").tqarg(nick), i18n("IRC Plugin"));
+ KMessageBox::error(Kopete::UI::Global::mainWidget(), i18n("The nickname %1 is already in use").arg(nick), i18n("IRC Plugin"));
}
void IRCAccount::setAltNick( const TQString &altNick )
{
- configGroup()->writeEntry(TQString::tqfromLatin1( "altNick" ), altNick);
+ configGroup()->writeEntry(TQString::fromLatin1( "altNick" ), altNick);
}
const TQString IRCAccount::altNick() const
{
- return configGroup()->readEntry(TQString::tqfromLatin1("altNick"));
+ return configGroup()->readEntry(TQString::fromLatin1("altNick"));
}
void IRCAccount::setAutoShowServerWindow( bool show )
{
autoShowServerWindow = show;
- configGroup()->writeEntry(TQString::tqfromLatin1( "AutoShowServerWindow" ), autoShowServerWindow);
+ configGroup()->writeEntry(TQString::fromLatin1( "AutoShowServerWindow" ), autoShowServerWindow);
}
const TQString IRCAccount::networkName() const
@@ -306,8 +306,8 @@ void IRCAccount::setNetwork( const TQString &network )
KMessageBox::queuedMessageBox(
Kopete::UI::Global::mainWidget(), KMessageBox::Error,
i18n("<qt>The network associated with this account, <b>%1</b>, no longer exists. Please"
- " ensure that the account has a valid network. The account will not be enabled until you do so.</qt>").tqarg(network),
- i18n("Problem Loading %1").tqarg( accountId() ), 0 );
+ " ensure that the account has a valid network. The account will not be enabled until you do so.</qt>").arg(network),
+ i18n("Problem Loading %1").arg( accountId() ), 0 );
}
}
@@ -338,29 +338,29 @@ TQTextCodec *IRCAccount::codec() const
// FIXME: Move this to a dictionnary
void IRCAccount::setDefaultPart( const TQString &defaultPart )
{
- configGroup()->writeEntry( TQString::tqfromLatin1( "defaultPart" ), defaultPart );
+ configGroup()->writeEntry( TQString::fromLatin1( "defaultPart" ), defaultPart );
}
// FIXME: Move this to a dictionnary
void IRCAccount::setDefaultQuit( const TQString &defaultQuit )
{
- configGroup()->writeEntry( TQString::tqfromLatin1( "defaultQuit" ), defaultQuit );
+ configGroup()->writeEntry( TQString::fromLatin1( "defaultQuit" ), defaultQuit );
}
// FIXME: Move this to a dictionnary
const TQString IRCAccount::defaultPart() const
{
- TQString partMsg = configGroup()->readEntry(TQString::tqfromLatin1("defaultPart"));
+ TQString partMsg = configGroup()->readEntry(TQString::fromLatin1("defaultPart"));
if( partMsg.isEmpty() )
- return TQString::tqfromLatin1("Kopete %1 : http://kopete.kde.org").tqarg( kapp->aboutData()->version() );
+ return TQString::fromLatin1("Kopete %1 : http://kopete.kde.org").arg( kapp->aboutData()->version() );
return partMsg;
}
const TQString IRCAccount::defaultQuit() const
{
- TQString quitMsg = configGroup()->readEntry(TQString::tqfromLatin1("defaultQuit"));
+ TQString quitMsg = configGroup()->readEntry(TQString::fromLatin1("defaultQuit"));
if( quitMsg.isEmpty() )
- return TQString::tqfromLatin1("Kopete %1 : http://kopete.kde.org").tqarg(kapp->aboutData()->version());
+ return TQString::fromLatin1("Kopete %1 : http://kopete.kde.org").arg(kapp->aboutData()->version());
return quitMsg;
}
@@ -370,7 +370,7 @@ void IRCAccount::setCustomCtcpReplies( const TQMap< TQString, TQString > &replie
for( TQMap< TQString, TQString >::ConstIterator it = replies.begin(); it != replies.end(); ++it )
{
m_engine->addCustomCtcp( it.key(), it.data() );
- val.append( TQString::tqfromLatin1("%1=%2").tqarg( it.key() ).tqarg( it.data() ) );
+ val.append( TQString::fromLatin1("%1=%2").arg( it.key() ).arg( it.data() ) );
}
configGroup()->writeEntry( "CustomCtcp", val );
@@ -416,7 +416,7 @@ void IRCAccount::setMessageDestinations( int serverNotices, int serverMessages,
KActionMenu *IRCAccount::actionMenu()
{
- TQString menuTitle = TQString::tqfromLatin1( " %1 <%2> " ).tqarg( accountId() ).tqarg( myself()->onlinetqStatus().description() );
+ TQString menuTitle = TQString::fromLatin1( " %1 <%2> " ).arg( accountId() ).arg( myself()->onlineStatus().description() );
KActionMenu *mActionMenu = Kopete::Account::actionMenu();
@@ -455,14 +455,14 @@ void IRCAccount::connectWithPassword(const TQString &password)
{
KMessageBox::queuedMessageBox(
Kopete::UI::Global::mainWidget(), KMessageBox::Error,
- i18n("<qt>The network associated with this account, <b>%1</b>, has no valid hosts. Please ensure that the account has a valid network.</qt>").tqarg(m_network->name),
+ i18n("<qt>The network associated with this account, <b>%1</b>, has no valid hosts. Please ensure that the account has a valid network.</qt>").arg(m_network->name),
i18n("Network is Empty"), 0 );
}
else if( currentHost == hosts.count() )
{
KMessageBox::queuedMessageBox(
Kopete::UI::Global::mainWidget(), KMessageBox::Error,
- i18n("<qt>Kopete could not connect to any of the servers in the network associated with this account (<b>%1</b>). Please try again later.</qt>").tqarg(m_network->name),
+ i18n("<qt>Kopete could not connect to any of the servers in the network associated with this account (<b>%1</b>). Please try again later.</qt>").arg(m_network->name),
i18n("Network is Unavailable"), 0 );
currentHost = 0;
@@ -490,7 +490,7 @@ void IRCAccount::connectWithPassword(const TQString &password)
}
IRCHost *host = hosts[ currentHost++ ];
- myServer()->appendMessage( i18n("Connecting to %1...").tqarg( host->host ) );
+ myServer()->appendMessage( i18n("Connecting to %1...").arg( host->host ) );
if( host->ssl )
myServer()->appendMessage( i18n("Using SSL") );
@@ -505,13 +505,13 @@ void IRCAccount::connectWithPassword(const TQString &password)
}
}
-void IRCAccount::engineStatusChanged(KIRC::Engine::tqStatus newtqStatus)
+void IRCAccount::engineStatusChanged(KIRC::Engine::Status newStatus)
{
kdDebug(14120) << k_funcinfo << endl;
- mySelf()->updatetqStatus();
+ mySelf()->updateStatus();
- switch (newtqStatus)
+ switch (newStatus)
{
case KIRC::Engine::Idle:
// Do nothing.
@@ -563,7 +563,7 @@ void IRCAccount::slotPerformOnConnectCommands()
return;
if (!autoConnect.isEmpty())
- Kopete::CommandHandler::commandHandler()->processMessage( TQString::tqfromLatin1("/join %1").tqarg(autoConnect), manager);
+ Kopete::CommandHandler::commandHandler()->processMessage( TQString::fromLatin1("/join %1").arg(autoConnect), manager);
TQStringList commands(connectCommands());
for (TQStringList::Iterator it=commands.begin(); it != commands.end(); ++it)
@@ -597,7 +597,7 @@ void IRCAccount::slotSearchChannels()
if( !m_channelList )
{
m_channelList = new ChannelListDialog( m_engine,
- i18n("Channel List for %1").tqarg( m_engine->currentHost() ), this,
+ i18n("Channel List for %1").arg( m_engine->currentHost() ), this,
TQT_SLOT( slotJoinNamedChannel( const TQString & ) ) );
}
else
@@ -653,17 +653,17 @@ void IRCAccount::slotShowServerWindow()
bool IRCAccount::isConnected()
{
-// return ( myself()->onlinetqStatus().status() != Kopete::OnlineStatus::Offline );
+// return ( myself()->onlineStatus().status() != Kopete::OnlineStatus::Offline );
return m_engine->isConnected();
}
void IRCAccount::setOnlineStatus( const Kopete::OnlineStatus& status , const TQString &reason )
{
if ( status.status() == Kopete::OnlineStatus::Online &&
- myself()->onlinetqStatus().status() == Kopete::OnlineStatus::Offline )
+ myself()->onlineStatus().status() == Kopete::OnlineStatus::Offline )
connect();
else if (status.status() == Kopete::OnlineStatus::Online &&
- myself()->onlinetqStatus().status() == Kopete::OnlineStatus::Away )
+ myself()->onlineStatus().status() == Kopete::OnlineStatus::Away )
setAway( false );
else if ( status.status() == Kopete::OnlineStatus::Offline )
disconnect();
@@ -700,7 +700,7 @@ bool IRCAccount::createContact( const TQString &contactId, Kopete::MetaContact *
return false;
}
- else if (contactId.startsWith(TQString::tqfromLatin1("#")))
+ else if (contactId.startsWith(TQString::fromLatin1("#")))
{
c = static_cast<IRCContact*>(contactManager()->findChannel(contactId, m));
}
@@ -714,8 +714,8 @@ bool IRCAccount::createContact( const TQString &contactId, Kopete::MetaContact *
{//This should NEVER happen
Kopete::MetaContact *old = c->metaContact();
c->setMetaContact( m );
- Kopete::ContactPtrList tqchildren = old->contacts();
- if (tqchildren.isEmpty())
+ Kopete::ContactPtrList children = old->contacts();
+ if (children.isEmpty())
Kopete::ContactList::self()->removeMetaContact( old );
}
else if( c->metaContact()->isTemporary() )
@@ -781,7 +781,7 @@ void IRCAccount::slotJoinChannel()
}
KMessageBox::error( Kopete::UI::Global::mainWidget(),
- i18n("\"%1\" is an invalid channel. Channels must start with '#', '!', '+', or '&'.").tqarg(chan),
+ i18n("\"%1\" is an invalid channel. Channels must start with '#', '!', '+', or '&'.").arg(chan),
i18n("IRC Plugin")
);
}
@@ -789,15 +789,15 @@ void IRCAccount::slotJoinChannel()
void IRCAccount::slotNewCtcpReply(const TQString &type, const TQString &/*target*/, const TQString &messageReceived)
{
- appendMessage( i18n("CTCP %1 REPLY: %2").tqarg(type).tqarg(messageReceived), InfoReply );
+ appendMessage( i18n("CTCP %1 REPLY: %2").arg(type).arg(messageReceived), InfoReply );
}
void IRCAccount::slotNoSuchNickname( const TQString &nick )
{
if( KIRC::Entity::isChannel(nick) )
- appendMessage( i18n("The channel \"%1\" does not exist").tqarg(nick), UnknownReply );
+ appendMessage( i18n("The channel \"%1\" does not exist").arg(nick), UnknownReply );
else
- appendMessage( i18n("The nickname \"%1\" does not exist").tqarg(nick), UnknownReply );
+ appendMessage( i18n("The nickname \"%1\" does not exist").arg(nick), UnknownReply );
}
void IRCAccount::appendMessage( const TQString &message, MessageType type )
@@ -852,7 +852,7 @@ void IRCAccount::appendMessage( const TQString &message, MessageType type )
if( destination == KNotify )
{
KNotifyClient::event(
- Kopete::UI::Global::mainWidget()->winId(), TQString::tqfromLatin1("irc_event"), message
+ Kopete::UI::Global::mainWidget()->winId(), TQString::fromLatin1("irc_event"), message
);
}
}
diff --git a/kopete/protocols/irc/ircaccount.h b/kopete/protocols/irc/ircaccount.h
index 3e5bf304..0d8fc313 100644
--- a/kopete/protocols/irc/ircaccount.h
+++ b/kopete/protocols/irc/ircaccount.h
@@ -194,7 +194,7 @@ protected:
virtual bool createContact( const TQString &contactId, Kopete::MetaContact *parentContact ) ;
private slots:
- void engineStatusChanged(KIRC::Engine::tqStatus newtqStatus);
+ void engineStatusChanged(KIRC::Engine::Status newStatus);
void destroyed(IRCContact *contact);
diff --git a/kopete/protocols/irc/ircaddcontactpage.cpp b/kopete/protocols/irc/ircaddcontactpage.cpp
index 6b19721c..f6c3f68e 100644
--- a/kopete/protocols/irc/ircaddcontactpage.cpp
+++ b/kopete/protocols/irc/ircaddcontactpage.cpp
@@ -23,7 +23,7 @@
#include "ircaccount.h"
-#include <tqlayout.h>
+#include <layout.h>
#include <tqlineedit.h>
#include <tqframe.h>
#include <tqtabwidget.h>
diff --git a/kopete/protocols/irc/ircchannelcontact.cpp b/kopete/protocols/irc/ircchannelcontact.cpp
index 45121c34..94d67d3a 100644
--- a/kopete/protocols/irc/ircchannelcontact.cpp
+++ b/kopete/protocols/irc/ircchannelcontact.cpp
@@ -66,7 +66,7 @@ IRCChannelContact::IRCChannelContact(IRCContactManager *contactManager, const TQ
actionModeI = new KToggleAction(i18n("&Invite Only"), 0, this, TQT_SLOT(slotModeChanged()), this );
actionHomePage = 0L;
- updatetqStatus();
+ updateStatus();
}
IRCChannelContact::~IRCChannelContact()
@@ -77,10 +77,10 @@ void IRCChannelContact::slotUpdateInfo()
{
/** This woudl be nice, but it generates server errors too often
- if( !manager(Kopete::Contact::CannotCreate) && onlinetqStatus() == m_protocol->m_ChannelStatusOnline )
- kircEngine()->writeMessage( TQString::tqfromLatin1("LIST %1").tqarg(m_nickName) );
+ if( !manager(Kopete::Contact::CannotCreate) && onlineStatus() == m_protocol->m_ChannelStatusOnline )
+ kircEngine()->writeMessage( TQString::fromLatin1("LIST %1").arg(m_nickName) );
else
- setProperty( TQString::tqfromLatin1("channelMembers"), i18n("Members"), manager()->members().count() );
+ setProperty( TQString::fromLatin1("channelMembers"), i18n("Members"), manager()->members().count() );
*/
KIRC::Engine *engine = kircEngine();
@@ -88,7 +88,7 @@ void IRCChannelContact::slotUpdateInfo()
if (manager(Kopete::Contact::CannotCreate))
{
setProperty(m_protocol->propChannelMembers, manager()->members().count());
- engine->writeMessage(TQString::tqfromLatin1("WHO %1").tqarg(m_nickName));
+ engine->writeMessage(TQString::fromLatin1("WHO %1").arg(m_nickName));
}
else
{
@@ -102,7 +102,7 @@ void IRCChannelContact::slotUpdateInfo()
void IRCChannelContact::slotChannelListed( const TQString &channel, uint members, const TQString &topic )
{
if (!manager(Kopete::Contact::CannotCreate) &&
- onlinetqStatus() == m_protocol->m_ChannelStatusOnline &&
+ onlineStatus() == m_protocol->m_ChannelStatusOnline &&
channel.lower() == m_nickName.lower())
{
mTopic = topic;
@@ -126,9 +126,9 @@ void IRCChannelContact::toggleOperatorActions(bool enabled)
actionModeI->setEnabled(enabled);
}
-void IRCChannelContact::slotOnlineStatusChanged(Kopete::Contact *c, const Kopete::OnlineStatus &status, const Kopete::OnlineStatus &oldtqStatus)
+void IRCChannelContact::slotOnlineStatusChanged(Kopete::Contact *c, const Kopete::OnlineStatus &status, const Kopete::OnlineStatus &oldStatus)
{
- Q_UNUSED(oldtqStatus);
+ Q_UNUSED(oldStatus);
if (c == account()->myself()) {
if (status.internalStatus() & IRCProtocol::Operator) {
@@ -141,9 +141,9 @@ void IRCChannelContact::slotOnlineStatusChanged(Kopete::Contact *c, const Kopete
}
}
-void IRCChannelContact::updatetqStatus()
+void IRCChannelContact::updateStatus()
{
- KIRC::Engine::tqStatus status = kircEngine()->status();
+ KIRC::Engine::Status status = kircEngine()->status();
switch (status)
{
case KIRC::Engine::Idle:
@@ -251,7 +251,7 @@ void IRCChannelContact::slotAddNicknames()
else if( firstChar == '+')
status = m_protocol->m_UserStatusVoice;
else
- status = user->onlinetqStatus();
+ status = user->onlineStatus();
if( user != account->mySelf() )
manager()->addContact(user , status, true);
@@ -272,12 +272,12 @@ void IRCChannelContact::channelTopic(const TQString &topic)
if (mTopic.isEmpty()) {
Kopete::Message msg((Kopete::Contact*)this, mMyself,
- i18n("Topic for %1 is set empty.").tqarg(m_nickName),
+ i18n("Topic for %1 is set empty.").arg(m_nickName),
Kopete::Message::Internal, Kopete::Message::RichText, CHAT_VIEW);
appendMessage(msg);
} else {
Kopete::Message msg((Kopete::Contact*)this, mMyself,
- i18n("Topic for %1 is %2").tqarg(m_nickName).tqarg(mTopic),
+ i18n("Topic for %1 is %2").arg(m_nickName).arg(mTopic),
Kopete::Message::Internal, Kopete::Message::RichText, CHAT_VIEW);
appendMessage(msg);
}
@@ -292,7 +292,7 @@ void IRCChannelContact::channelHomePage(const TQString &url)
void IRCChannelContact::join()
{
if (!manager(Kopete::Contact::CannotCreate) &&
- onlinetqStatus().status() == Kopete::OnlineStatus::Online)
+ onlineStatus().status() == Kopete::OnlineStatus::Online)
{
kdDebug() << k_funcinfo << "My nickname:" << m_nickName << endl;
kdDebug() << k_funcinfo << "My manager:" << manager(Kopete::Contact::CannotCreate) << endl;
@@ -362,7 +362,7 @@ void IRCChannelContact::userJoinedChannel(const TQString &nickname)
kdDebug() << k_funcinfo << "My view:" << manager(Kopete::Contact::CannotCreate)->view(false) << endl;
Kopete::Message msg((Kopete::Contact *)this, mMyself,
- i18n("You have joined channel %1").tqarg(m_nickName),
+ i18n("You have joined channel %1").arg(m_nickName),
Kopete::Message::Internal, Kopete::Message::PlainText,
CHAT_VIEW);
msg.setImportance( Kopete::Message::Low); //set the importance manualy to low
@@ -378,7 +378,7 @@ void IRCChannelContact::userJoinedChannel(const TQString &nickname)
contact->setOnlineStatus( m_protocol->m_UserStatusOnline );
manager()->addContact((Kopete::Contact *)contact, true);
Kopete::Message msg((Kopete::Contact *)this, mMyself,
- i18n("User <b>%1</b> joined channel %2").tqarg(nickname).tqarg(m_nickName),
+ i18n("User <b>%1</b> joined channel %2").arg(nickname).arg(m_nickName),
Kopete::Message::Internal, Kopete::Message::RichText, CHAT_VIEW);
msg.setImportance( Kopete::Message::Low); //set the importance manualy to low
manager()->appendMessage(msg);
@@ -413,9 +413,9 @@ void IRCChannelContact::userKicked(const TQString &nick, const TQString &nickKic
TQString r;
if ((reason != nick) && (reason != nickKicked)) {
- r = i18n( "%1 was kicked by %2. Reason: %3" ).tqarg(nickKicked, nick, reason);
+ r = i18n( "%1 was kicked by %2. Reason: %3" ).arg(nickKicked, nick, reason);
} else {
- r = i18n( "%1 was kicked by %2." ).tqarg(nickKicked, nick);
+ r = i18n( "%1 was kicked by %2." ).arg(nickKicked, nick);
}
manager()->removeContact( c, r );
@@ -434,9 +434,9 @@ void IRCChannelContact::userKicked(const TQString &nick, const TQString &nickKic
TQString r;
if ((reason != nick) && (reason != nickKicked)) {
- r = i18n( "You were kicked from %1 by %2. Reason: %3" ).tqarg(m_nickName, nickKicked, reason);
+ r = i18n( "You were kicked from %1 by %2. Reason: %3" ).arg(m_nickName, nickKicked, reason);
} else {
- r = i18n( "You were kicked from %1 by %2." ).tqarg(m_nickName, nickKicked);
+ r = i18n( "You were kicked from %1 by %2." ).arg(m_nickName, nickKicked);
}
KMessageBox::error(Kopete::UI::Global::mainWidget(), r, i18n("IRC Plugin"));
@@ -468,7 +468,7 @@ void IRCChannelContact::setTopic(const TQString &topic)
else
{
Kopete::Message msg(account->myServer(), manager()->members(),
- i18n("You must be a channel operator on %1 to do that.").tqarg(m_nickName),
+ i18n("You must be a channel operator on %1 to do that.").arg(m_nickName),
Kopete::Message::Internal, Kopete::Message::PlainText, CHAT_VIEW);
manager()->appendMessage(msg);
}
@@ -483,7 +483,7 @@ void IRCChannelContact::topicChanged(const TQString &nick, const TQString &newto
setProperty( m_protocol->propChannelTopic, mTopic );
manager()->setDisplayName( caption() );
Kopete::Message msg(account->myServer(), mMyself,
- i18n("%1 has changed the topic to: %2").tqarg(nick).tqarg(newtopic),
+ i18n("%1 has changed the topic to: %2").arg(nick).arg(newtopic),
Kopete::Message::Internal, Kopete::Message::RichText, CHAT_VIEW);
msg.setImportance(Kopete::Message::Low); //set the importance manualy to low
appendMessage(msg);
@@ -494,7 +494,7 @@ void IRCChannelContact::topicUser(const TQString &nick, const TQDateTime &time)
IRCAccount *account = ircAccount();
Kopete::Message msg(account->myServer(), mMyself,
- i18n("Topic set by %1 at %2").tqarg(nick).tqarg(
+ i18n("Topic set by %1 at %2").arg(nick).arg(
KGlobal::locale()->formatDateTime(time, true)
), Kopete::Message::Internal, Kopete::Message::PlainText, CHAT_VIEW);
msg.setImportance(Kopete::Message::Low); //set the importance manualy to low
@@ -503,7 +503,7 @@ void IRCChannelContact::topicUser(const TQString &nick, const TQDateTime &time)
void IRCChannelContact::incomingModeChange( const TQString &nick, const TQString &mode )
{
- Kopete::Message msg(this, mMyself, i18n("%1 sets mode %2 on %3").tqarg(nick).tqarg(mode).tqarg(m_nickName), Kopete::Message::Internal, Kopete::Message::PlainText, CHAT_VIEW);
+ Kopete::Message msg(this, mMyself, i18n("%1 sets mode %2 on %3").arg(nick).arg(mode).arg(m_nickName), Kopete::Message::Internal, Kopete::Message::PlainText, CHAT_VIEW);
msg.setImportance( Kopete::Message::Low); //set the importance manualy to low
appendMessage(msg);
@@ -564,7 +564,7 @@ void IRCChannelContact::failedChanBanned()
{
manager()->deleteLater();
KMessageBox::error( Kopete::UI::Global::mainWidget(),
- i18n("<qt>You can not join %1 because you have been banned.</qt>").tqarg(m_nickName),
+ i18n("<qt>You can not join %1 because you have been banned.</qt>").arg(m_nickName),
i18n("IRC Plugin") );
}
@@ -572,14 +572,14 @@ void IRCChannelContact::failedChanInvite()
{
manager()->deleteLater();
KMessageBox::error( Kopete::UI::Global::mainWidget(),
- i18n("<qt>You can not join %1 because it is set to invite only, and no one has invited you.</qt>").tqarg(m_nickName), i18n("IRC Plugin") );
+ i18n("<qt>You can not join %1 because it is set to invite only, and no one has invited you.</qt>").arg(m_nickName), i18n("IRC Plugin") );
}
void IRCChannelContact::failedChanFull()
{
manager()->deleteLater();
KMessageBox::error( Kopete::UI::Global::mainWidget(),
- i18n("<qt>You can not join %1 because it has reached its user limit.</qt>").tqarg(m_nickName),
+ i18n("<qt>You can not join %1 because it has reached its user limit.</qt>").arg(m_nickName),
i18n("IRC Plugin") );
}
@@ -587,7 +587,7 @@ void IRCChannelContact::failedChankey()
{
bool ok;
TQString diaPassword = KInputDialog::getText( i18n( "IRC Plugin" ),
- i18n( "Please enter key for channel %1: ").tqarg(m_nickName),
+ i18n( "Please enter key for channel %1: ").arg(m_nickName),
TQString(),
&ok );
@@ -636,9 +636,9 @@ void IRCChannelContact::toggleMode( TQChar mode, bool enabled, bool update )
if( modeMap[mode] != enabled )
{
if( enabled )
- setMode( TQString::tqfromLatin1("+") + mode );
+ setMode( TQString::fromLatin1("+") + mode );
else
- setMode( TQString::tqfromLatin1("-") + mode );
+ setMode( TQString::fromLatin1("-") + mode );
}
}
@@ -717,9 +717,9 @@ void IRCChannelContact::slotHomepage()
const TQString IRCChannelContact::caption() const
{
- TQString cap = TQString::tqfromLatin1("%1 @ %2").tqarg(m_nickName).tqarg(kircEngine()->currentHost());
+ TQString cap = TQString::fromLatin1("%1 @ %2").arg(m_nickName).arg(kircEngine()->currentHost());
if(!mTopic.isEmpty())
- cap.append( TQString::tqfromLatin1(" - %1").tqarg(Kopete::Message::unescape(mTopic)) );
+ cap.append( TQString::fromLatin1(" - %1").arg(Kopete::Message::unescape(mTopic)) );
return cap;
}
diff --git a/kopete/protocols/irc/ircchannelcontact.h b/kopete/protocols/irc/ircchannelcontact.h
index 67fa46c9..7906e0d1 100644
--- a/kopete/protocols/irc/ircchannelcontact.h
+++ b/kopete/protocols/irc/ircchannelcontact.h
@@ -96,7 +96,7 @@ public:
void newAction(const TQString &from, const TQString &action);
public slots:
- void updatetqStatus();
+ void updateStatus();
/**
* Sets the topic of this channel
@@ -128,7 +128,7 @@ private slots:
void slotUpdateInfo();
void slotHomepage();
void slotChannelListed(const TQString &channel, uint members, const TQString &topic);
- void slotOnlineStatusChanged(Kopete::Contact *c, const Kopete::OnlineStatus &status, const Kopete::OnlineStatus &oldtqStatus);
+ void slotOnlineStatusChanged(Kopete::Contact *c, const Kopete::OnlineStatus &status, const Kopete::OnlineStatus &oldStatus);
private:
KAction *actionJoin;
diff --git a/kopete/protocols/irc/irccontact.cpp b/kopete/protocols/irc/irccontact.cpp
index 7df5894c..1ed783e1 100644
--- a/kopete/protocols/irc/irccontact.cpp
+++ b/kopete/protocols/irc/irccontact.cpp
@@ -22,7 +22,7 @@
#include <tqregexp.h>
#include <tqtimer.h>
-#include <tqtextcodec.h>
+#include <textcodec.h>
#include "ircaccount.h"
#include "kopeteglobal.h"
@@ -67,8 +67,8 @@ IRCContact::IRCContact(IRCContactManager *contactManager, const TQString &nick,
TQObject::connect(engine, TQT_SIGNAL(incomingQuitIRC(const TQString &, const TQString &)),
this, TQT_SLOT( slotUserDisconnected(const TQString&, const TQString&)));
- TQObject::connect(engine, TQT_SIGNAL(statusChanged(KIRC::Engine::tqStatus)),
- this, TQT_SLOT(updatetqStatus()));
+ TQObject::connect(engine, TQT_SIGNAL(statusChanged(KIRC::Engine::Status)),
+ this, TQT_SLOT(updateStatus()));
engine->setCodec( m_nickName, codec() );
}
@@ -94,8 +94,8 @@ KIRC::Engine *IRCContact::kircEngine() const
bool IRCContact::isReachable()
{
- if (onlinetqStatus().status() != Kopete::OnlineStatus::Offline &&
- onlinetqStatus().status() != Kopete::OnlineStatus::Unknown)
+ if (onlineStatus().status() != Kopete::OnlineStatus::Offline &&
+ onlineStatus().status() != Kopete::OnlineStatus::Unknown)
return true;
return false;
@@ -111,7 +111,7 @@ const TQString IRCContact::formatedName() const
return TQString();
}
*/
-void IRCContact::updatetqStatus()
+void IRCContact::updateStatus()
{
}
@@ -122,12 +122,12 @@ void IRCContact::privateMessage(IRCContact *, IRCContact *, const TQString &)
void IRCContact::setCodec(const TQTextCodec *codec)
{
kircEngine()->setCodec(m_nickName, codec);
- metaContact()->setPluginData(m_protocol, TQString::tqfromLatin1("Codec"), TQString::number(codec->mibEnum()));
+ metaContact()->setPluginData(m_protocol, TQString::fromLatin1("Codec"), TQString::number(codec->mibEnum()));
}
const TQTextCodec *IRCContact::codec()
{
- TQString codecId = metaContact()->pluginData(m_protocol, TQString::tqfromLatin1("Codec"));
+ TQString codecId = metaContact()->pluginData(m_protocol, TQString::fromLatin1("Codec"));
TQTextCodec *codec = ircAccount()->codec();
if( !codecId.isEmpty() )
@@ -186,7 +186,7 @@ void IRCContact::slotUserDisconnected(const TQString &user, const TQString &reas
Kopete::Contact *c = locateUser( nickname );
if ( c )
{
- m_chatSession->removeContact(c, i18n("Quit: \"%1\" ").tqarg(reason), Kopete::Message::RichText);
+ m_chatSession->removeContact(c, i18n("Quit: \"%1\" ").arg(reason), Kopete::Message::RichText);
c->setOnlineStatus(m_protocol->m_UserStatusOffline);
}
}
@@ -229,9 +229,9 @@ void IRCContact::slotSendMsg(Kopete::Message &message, Kopete::ChatSession *)
// Two-liner in color:
// <span style="color:#403897">Hello<br />World</span>
- if (htmlString.find(TQString::tqfromLatin1("</span")) > -1)
+ if (htmlString.find(TQString::fromLatin1("</span")) > -1)
{
- TQRegExp findTags( TQString::tqfromLatin1("<span style=\"(.*)\">(.*)</span>") );
+ TQRegExp findTags( TQString::fromLatin1("<span style=\"(.*)\">(.*)</span>") );
findTags.setMinimal( true );
int pos = 0;
@@ -249,19 +249,19 @@ void IRCContact::slotSendMsg(Kopete::Message &message, Kopete::ChatSession *)
TQString attribute = (*attrPair).section(':',0,0);
TQString value = (*attrPair).section(':',1);
- if( attribute == TQString::tqfromLatin1("color") )
+ if( attribute == TQString::fromLatin1("color") )
{
int ircColor = KSParser::colorForHTML( value );
if( ircColor > -1 )
replacement.prepend( TQString( TQChar(0x03) ).append( TQString::number(ircColor) ) ).append( TQChar( 0x03 ) );
}
- else if( attribute == TQString::tqfromLatin1("font-weight") &&
- value == TQString::tqfromLatin1("600") ) {
+ else if( attribute == TQString::fromLatin1("font-weight") &&
+ value == TQString::fromLatin1("600") ) {
// Bolding
replacement.prepend( TQChar(0x02) ).append( TQChar(0x02) );
}
- else if( attribute == TQString::tqfromLatin1("text-decoration") &&
- value == TQString::tqfromLatin1("underline") ) {
+ else if( attribute == TQString::fromLatin1("text-decoration") &&
+ value == TQString::fromLatin1("underline") ) {
replacement.prepend( TQChar(31) ).append( TQChar(31) );
}
}
diff --git a/kopete/protocols/irc/irccontact.h b/kopete/protocols/irc/irccontact.h
index 823f23ae..a415929d 100644
--- a/kopete/protocols/irc/irccontact.h
+++ b/kopete/protocols/irc/irccontact.h
@@ -121,7 +121,7 @@ signals:
public slots:
void setCodec( const TQTextCodec *codec );
- virtual void updatetqStatus();
+ virtual void updateStatus();
protected slots:
virtual void slotSendMsg(Kopete::Message &message, Kopete::ChatSession *);
diff --git a/kopete/protocols/irc/ircprotocol.cpp b/kopete/protocols/irc/ircprotocol.cpp
index b60f5a58..a8b39299 100644
--- a/kopete/protocols/irc/ircprotocol.cpp
+++ b/kopete/protocols/irc/ircprotocol.cpp
@@ -72,7 +72,7 @@ IRCProtocol *IRCProtocol::s_protocol = 0L;
IRCProtocolHandler::IRCProtocolHandler() : Kopete::MimeTypeHandler( false )
{
- registerAsProtocolHandler( TQString::tqfromLatin1("irc") );
+ registerAsProtocolHandler( TQString::fromLatin1("irc") );
}
void IRCProtocolHandler::handleURL( const KURL &url ) const
@@ -90,7 +90,7 @@ void IRCProtocolHandler::handleURL( const KURL &url ) const
return;
KUser user( getuid() );
- TQString accountId = TQString::tqfromLatin1("%1@%2:%3").tqarg(
+ TQString accountId = TQString::fromLatin1("%1@%2:%3").arg(
user.loginName(),
url.host(),
TQString::number(port)
@@ -149,141 +149,141 @@ IRCProtocol::IRCProtocol( TQObject *parent, const char *name, const TQStringList
m_StatusUnknown(Kopete::OnlineStatus::Unknown,
999, this, 999, "status_unknown", i18n("Status not available")),
- propChannelTopic(TQString::tqfromLatin1("channelTopic"), i18n("Topic"), TQString(), false, true ),
- propChannelMembers(TQString::tqfromLatin1("channelMembers"), i18n("Members")),
- propHomepage(TQString::tqfromLatin1("homePage"), i18n("Home Page")),
+ propChannelTopic(TQString::fromLatin1("channelTopic"), i18n("Topic"), TQString(), false, true ),
+ propChannelMembers(TQString::fromLatin1("channelMembers"), i18n("Members")),
+ propHomepage(TQString::fromLatin1("homePage"), i18n("Home Page")),
propLastSeen(Kopete::Global::Properties::self()->lastSeen()),
- propUserInfo(TQString::tqfromLatin1("userInfo"), i18n("IRC User")),
- propServer(TQString::tqfromLatin1("ircServer"), i18n("IRC Server")),
- propChannels( TQString::tqfromLatin1("ircChannels"), i18n("IRC Channels")),
- propHops(TQString::tqfromLatin1("ircHops"), i18n("IRC Hops")),
- propFullName(TQString::tqfromLatin1("FormattedName"), i18n("Full Name")),
- propIsIdentified(TQString::tqfromLatin1("identifiedUser"), i18n("User Is Authenticated"))
+ propUserInfo(TQString::fromLatin1("userInfo"), i18n("IRC User")),
+ propServer(TQString::fromLatin1("ircServer"), i18n("IRC Server")),
+ propChannels( TQString::fromLatin1("ircChannels"), i18n("IRC Channels")),
+ propHops(TQString::fromLatin1("ircHops"), i18n("IRC Hops")),
+ propFullName(TQString::fromLatin1("FormattedName"), i18n("Full Name")),
+ propIsIdentified(TQString::fromLatin1("identifiedUser"), i18n("User Is Authenticated"))
{
// kdDebug(14120) << k_funcinfo << endl;
s_protocol = this;
- //m_status = m_unknowntqStatus = m_Unknown;
+ //m_status = m_unknownStatus = m_Unknown;
addAddressBookField("messaging/irc", Kopete::Plugin::MakeIndexField);
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("raw"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("raw"),
TQT_SLOT( slotRawCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /raw <text> - Sends the text in raw form to the server."), 1 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("quote"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("quote"),
TQT_SLOT( slotQuoteCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /quote <text> - Sends the text in quoted form to the server."), 1 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("ctcp"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("ctcp"),
TQT_SLOT( slotCtcpCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /ctcp <nick> <message> - Send the CTCP message to nick<action>."), 2 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("ping"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("ping"),
TQT_SLOT( slotPingCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /ping <nickname> - Alias for /CTCP <nickname> PING."), 1, 1 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("motd"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("motd"),
TQT_SLOT( slotMotdCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /motd [<server>] - Shows the message of the day for the current or the given server.") );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("list"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("list"),
TQT_SLOT( slotListCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /list - List the public channels on the server.") );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("join"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("join"),
TQT_SLOT( slotJoinCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /join <#channel 1> [<password>] - Joins the specified channel."), 1, 2 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("topic"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("topic"),
TQT_SLOT( slotTopicCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /topic [<topic>] - Sets and/or displays the topic for the active channel.") );
//FIXME: Update help text
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("whois"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("whois"),
TQT_SLOT( slotWhoisCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /whois <nickname> - Display whois info on this user."), 1 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("whowas"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("whowas"),
TQT_SLOT( slotWhoWasCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /whowas <nickname> - Display whowas info on this user."), 1, 1 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("who"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("who"),
TQT_SLOT( slotWhoCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /who <nickname|channel> - Display who info on this user/channel."), 1, 1 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("query"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("query"),
TQT_SLOT( slotQueryCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /query <nickname> [<message>] - Open a private chat with this user."), 1 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("mode"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("mode"),
TQT_SLOT( slotModeCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /mode <channel> <modes> - Set modes on the given channel."), 2 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("nick"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("nick"),
TQT_SLOT( slotNickCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /nick <nickname> - Change your nickname to the given one."), 1, 1 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("me"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("me"),
TQT_SLOT( slotMeCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /me <action> - Do something."), 1 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("ame"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("ame"),
TQT_SLOT( slotAllMeCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /ame <action> - Do something in every open chat."), 1 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("kick"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("kick"),
TQT_SLOT( slotKickCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /kick <nickname> [<reason>] - Kick someone from the channel (requires operator status).")
, 1 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("ban"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("ban"),
TQT_SLOT( slotBanCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /ban <mask> - Add someone to this channel's ban list. (requires operator status)."),
1, 1 );
- Kopete::CommandHandler::commandHandler()->registerAlias( this, TQString::tqfromLatin1("bannick"),
- TQString::tqfromLatin1("ban %1!*@*"),
+ Kopete::CommandHandler::commandHandler()->registerAlias( this, TQString::fromLatin1("bannick"),
+ TQString::fromLatin1("ban %1!*@*"),
i18n("USAGE: /bannick <nickname> - Add someone to this channel's ban list. Uses the hostmask nickname!*@* (requires operator status)."), Kopete::CommandHandler::SystemAlias, 1, 1 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("op"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("op"),
TQT_SLOT( slotOpCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /op <nickname 1> [<nickname 2> <...>] - Give channel operator status to someone (requires operator status)."),
1 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("deop"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("deop"),
TQT_SLOT( slotDeopCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /deop <nickname> [<nickname 2> <...>]- Remove channel operator status from someone (requires operator status)."), 1 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("voice"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("voice"),
TQT_SLOT( slotVoiceCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /voice <nickname> [<nickname 2> <...>]- Give channel voice status to someone (requires operator status)."),
1);
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("devoice"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("devoice"),
TQT_SLOT( slotDevoiceCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /devoice <nickname> [<nickname 2> <...>]- Remove channel voice status from someone (requires operator status)."), 1 );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("quit"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("quit"),
TQT_SLOT( slotQuitCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /quit [<reason>] - Disconnect from IRC, optionally leaving a message.") );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("part"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("part"),
TQT_SLOT( slotPartCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /part [<reason>] - Part from a channel, optionally leaving a message.") );
- Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::tqfromLatin1("invite"),
+ Kopete::CommandHandler::commandHandler()->registerCommand( this, TQString::fromLatin1("invite"),
TQT_SLOT( slotInviteCommand( const TQString &, Kopete::ChatSession*) ),
i18n("USAGE: /invite <nickname> [<channel>] - Invite a user to join a channel."), 1 );
- Kopete::CommandHandler::commandHandler()->registerAlias( this, TQString::tqfromLatin1("j"),
- TQString::tqfromLatin1("join %1"),
+ Kopete::CommandHandler::commandHandler()->registerAlias( this, TQString::fromLatin1("j"),
+ TQString::fromLatin1("join %1"),
i18n("USAGE: /j <#channel 1> [<password>] - Alias for JOIN."), Kopete::CommandHandler::SystemAlias,
1, 2 );
- Kopete::CommandHandler::commandHandler()->registerAlias( this, TQString::tqfromLatin1("msg"),
- TQString::tqfromLatin1("query %s"),
+ Kopete::CommandHandler::commandHandler()->registerAlias( this, TQString::fromLatin1("msg"),
+ TQString::fromLatin1("query %s"),
i18n("USAGE: /msg <nickname> [<message>] - Alias for TQUERY <nickname> <message>."), Kopete::CommandHandler::SystemAlias, 1 );
TQObject::connect( Kopete::ChatSessionManager::self(), TQT_SIGNAL(aboutToDisplay(Kopete::Message &)),
@@ -313,7 +313,7 @@ IRCProtocol::~IRCProtocol()
delete m_protocolHandler;
}
-const Kopete::OnlineStatus IRCProtocol::statusLookup( IRCtqStatus status ) const
+const Kopete::OnlineStatus IRCProtocol::statusLookup( IRCStatus status ) const
{
kdDebug(14120) << k_funcinfo << "Looking up status for " << status << endl;
@@ -376,7 +376,7 @@ void IRCProtocol::slotMessageFilter( Kopete::Message &msg )
TQString messageText = msg.escapedBody();
//Add right click for channels, only replace text not in HTML tags
- messageText.replace( TQRegExp( TQString::tqfromLatin1("(?![^<]+>)(#[^#\\s]+)(?![^<]+>)") ), TQString::tqfromLatin1("<span class=\"KopeteLink\" type=\"IRCChannel\">\\1</span>") );
+ messageText.replace( TQRegExp( TQString::fromLatin1("(?![^<]+>)(#[^#\\s]+)(?![^<]+>)") ), TQString::fromLatin1("<span class=\"KopeteLink\" type=\"IRCChannel\">\\1</span>") );
msg.setBody( messageText, Kopete::Message::RichText );
}
@@ -391,7 +391,7 @@ TQPtrList<KAction> *IRCProtocol::customChatWindowPopupActions( const Kopete::Mes
{
activeNode = n;
activeAccount = static_cast<IRCAccount*>( m.from()->account() );
- if( e.getAttribute( TQString::tqfromLatin1("type") ) == TQString::tqfromLatin1("IRCChannel") )
+ if( e.getAttribute( TQString::fromLatin1("type") ) == TQString::fromLatin1("IRCChannel") )
return activeAccount->contactManager()->findChannel(
e.innerText().string() )->customContextMenuActions();
}
@@ -512,7 +512,7 @@ void IRCProtocol::slotTopicCommand( const TQString &args, Kopete::ChatSession *m
else
{
static_cast<IRCAccount*>(manager->account())->engine()->
- writeRawMessage(TQString::tqfromLatin1("TOPIC %1").tqarg(chan->nickName()));
+ writeRawMessage(TQString::fromLatin1("TOPIC %1").arg(chan->nickName()));
}
}
else
@@ -536,7 +536,7 @@ void IRCProtocol::slotJoinCommand( const TQString &arg, Kopete::ChatSession *man
{
static_cast<IRCAccount*>( manager->account() )->appendMessage(
i18n("\"%1\" is an invalid channel. Channels must start with '#', '!', '+', or '&'.")
- .tqarg(args[0]), IRCAccount::ErrorReply );
+ .arg(args[0]), IRCAccount::ErrorReply );
}
}
@@ -556,7 +556,7 @@ void IRCProtocol::slotInviteCommand( const TQString &args, Kopete::ChatSession *
{
static_cast<IRCAccount*>( manager->account() )->appendMessage(
i18n("\"%1\" is an invalid channel. Channels must start with '#', '!', '+', or '&'.")
- .tqarg(argsList[1]), IRCAccount::ErrorReply );
+ .arg(argsList[1]), IRCAccount::ErrorReply );
}
}
else
@@ -568,7 +568,7 @@ void IRCProtocol::slotInviteCommand( const TQString &args, Kopete::ChatSession *
if( c && c->manager()->contactOnlineStatus( manager->myself() ) == m_UserStatusOp )
{
static_cast<IRCAccount*>( manager->account() )->engine()->writeMessage(
- TQString::tqfromLatin1("INVITE %1 %2").tqarg( argsList[0] ).
+ TQString::fromLatin1("INVITE %1 %2").arg( argsList[0] ).
arg( c->nickName() )
);
}
@@ -599,7 +599,7 @@ void IRCProtocol::slotQueryCommand( const TQString &args, Kopete::ChatSession *m
else
{
static_cast<IRCAccount*>( manager->account() )->appendMessage(
- i18n("\"%1\" is an invalid nickname. Nicknames must not start with '#','!','+', or '&'.").tqarg(user),
+ i18n("\"%1\" is an invalid nickname. Nicknames must not start with '#','!','+', or '&'.").arg(user),
IRCAccount::ErrorReply );
}
}
@@ -614,7 +614,7 @@ void IRCProtocol::slotWhoCommand( const TQString &args, Kopete::ChatSession *man
{
TQStringList argsList = Kopete::CommandHandler::parseArguments( args );
static_cast<IRCAccount*>( manager->account() )->engine()->writeMessage(
- TQString::tqfromLatin1("WHO %1").tqarg( argsList.first() ) );
+ TQString::fromLatin1("WHO %1").arg( argsList.first() ) );
static_cast<IRCAccount*>( manager->account() )->setCurrentCommandSource( manager );
}
@@ -622,7 +622,7 @@ void IRCProtocol::slotWhoWasCommand( const TQString &args, Kopete::ChatSession *
{
TQStringList argsList = Kopete::CommandHandler::parseArguments( args );
static_cast<IRCAccount*>( manager->account() )->engine()->writeMessage(
- TQString::tqfromLatin1("WHOWAS %1").tqarg( argsList.first() ) );
+ TQString::fromLatin1("WHOWAS %1").arg( argsList.first() ) );
static_cast<IRCAccount*>( manager->account() )->setCurrentCommandSource( manager );
}
@@ -641,7 +641,7 @@ void IRCProtocol::slotModeCommand(const TQString &args, Kopete::ChatSession *man
{
TQStringList argsList = Kopete::CommandHandler::parseArguments( args );
static_cast<IRCAccount*>( manager->account() )->engine()->mode( argsList.front(),
- args.section( TQRegExp(TQString::tqfromLatin1("\\s+")), 1 ) );
+ args.section( TQRegExp(TQString::fromLatin1("\\s+")), 1 ) );
}
void IRCProtocol::slotMeCommand(const TQString &args, Kopete::ChatSession *manager)
@@ -668,7 +668,7 @@ void IRCProtocol::slotKickCommand(const TQString &args, Kopete::ChatSession *man
{
if (manager->contactOnlineStatus( manager->myself() ) == m_UserStatusOp)
{
- TQRegExp spaces(TQString::tqfromLatin1("\\s+"));
+ TQRegExp spaces(TQString::fromLatin1("\\s+"));
TQString nick = args.section( spaces, 0, 0);
TQString reason = args.section( spaces, 1);
Kopete::ContactPtrList members = manager->members();
@@ -691,7 +691,7 @@ void IRCProtocol::slotBanCommand( const TQString &args, Kopete::ChatSession *man
Kopete::ContactPtrList members = manager->members();
IRCChannelContact *chan = static_cast<IRCChannelContact*>( members.first() );
if( chan && chan->locateUser( argsList.front() ) )
- chan->setMode( TQString::tqfromLatin1("+b %1").tqarg( argsList.front() ) );
+ chan->setMode( TQString::fromLatin1("+b %1").arg( argsList.front() ) );
}
else
{
@@ -724,22 +724,22 @@ void IRCProtocol::slotPartCommand( const TQString &args, Kopete::ChatSession *ma
void IRCProtocol::slotOpCommand( const TQString &args, Kopete::ChatSession *manager )
{
- simpleModeChange( args, manager, TQString::tqfromLatin1("+o") );
+ simpleModeChange( args, manager, TQString::fromLatin1("+o") );
}
void IRCProtocol::slotDeopCommand( const TQString &args, Kopete::ChatSession *manager )
{
- simpleModeChange( args, manager, TQString::tqfromLatin1("-o") );
+ simpleModeChange( args, manager, TQString::fromLatin1("-o") );
}
void IRCProtocol::slotVoiceCommand( const TQString &args, Kopete::ChatSession *manager )
{
- simpleModeChange( args, manager, TQString::tqfromLatin1("+v") );
+ simpleModeChange( args, manager, TQString::fromLatin1("+v") );
}
void IRCProtocol::slotDevoiceCommand( const TQString &args, Kopete::ChatSession *manager )
{
- simpleModeChange( args, manager, TQString::tqfromLatin1("-v") );
+ simpleModeChange( args, manager, TQString::fromLatin1("-v") );
}
void IRCProtocol::simpleModeChange( const TQString &args, Kopete::ChatSession *manager, const TQString &mode )
@@ -754,7 +754,7 @@ void IRCProtocol::simpleModeChange( const TQString &args, Kopete::ChatSession *m
for( TQStringList::iterator it = argsList.begin(); it != argsList.end(); ++it )
{
if( chan->locateUser( *it ) )
- chan->setMode( TQString::tqfromLatin1("%1 %2").tqarg( mode ).tqarg( *it ) );
+ chan->setMode( TQString::fromLatin1("%1 %2").arg( mode ).arg( *it ) );
}
}
}
@@ -770,7 +770,7 @@ void IRCProtocol::editNetworks( const TQString &networkName )
if( !netConf )
{
netConf = new NetworkConfig( Kopete::UI::Global::mainWidget(), "network_config", true );
- netConf->host->setValidator( new TQRegExpValidator( TQString::tqfromLatin1("^[\\w-\\.]*$"), TQT_TQOBJECT(netConf) ) );
+ netConf->host->setValidator( new TQRegExpValidator( TQString::fromLatin1("^[\\w-\\.]*$"), TQT_TQOBJECT(netConf) ) );
netConf->upButton->setIconSet( SmallIconSet( "up" ) );
netConf->downButton->setIconSet( SmallIconSet( "down" ) );
@@ -827,7 +827,7 @@ void IRCProtocol::slotUpdateNetworkConfig()
netConf->hostList->clear();
for( TQValueList<IRCHost*>::iterator it = net->hosts.begin(); it != net->hosts.end(); ++it )
- netConf->hostList->insertItem( (*it)->host + TQString::tqfromLatin1(":") + TQString::number((*it)->port) );
+ netConf->hostList->insertItem( (*it)->host + TQString::fromLatin1(":") + TQString::number((*it)->port) );
// prevent nested event loop crash
disconnect( netConf->hostList, TQT_SIGNAL( selectionChanged() ), this, TQT_SLOT( slotUpdateNetworkHostConfig() ) );
@@ -871,7 +871,7 @@ void IRCProtocol::storeCurrentHost()
void IRCProtocol::slotHostPortChanged( int value )
{
- TQString entryText = m_uiCurrentHostSelection + TQString::tqfromLatin1(":") + TQString::number( value );
+ TQString entryText = m_uiCurrentHostSelection + TQString::fromLatin1(":") + TQString::number( value );
// changeItem causes a take() and insert, and we don't want a selectionChanged() signal that sets all this off again.
disconnect( netConf->hostList, TQT_SIGNAL( selectionChanged() ), this, TQT_SLOT( slotUpdateNetworkHostConfig() ) );
netConf->hostList->changeItem( entryText, netConf->hostList->currentItem() );
@@ -918,8 +918,8 @@ void IRCProtocol::slotDeleteNetwork()
if( KMessageBox::warningContinueCancel(
Kopete::UI::Global::mainWidget(), i18n("<qt>Are you sure you want to delete the network <b>%1</b>?<br>"
"Any accounts which use this network will have to be modified.</qt>")
- .tqarg(network), i18n("Deleting Network"),
- KGuiItem(i18n("&Delete Network"),"editdelete"), TQString::tqfromLatin1("AskIRCDeleteNetwork") ) == KMessageBox::Continue )
+ .arg(network), i18n("Deleting Network"),
+ KGuiItem(i18n("&Delete Network"),"editdelete"), TQString::fromLatin1("AskIRCDeleteNetwork") ) == KMessageBox::Continue )
{
disconnect( netConf->networkList, TQT_SIGNAL( selectionChanged() ), this, TQT_SLOT( slotUpdateNetworkConfig() ) );
disconnect( netConf->hostList, TQT_SIGNAL( selectionChanged() ), this, TQT_SLOT( slotUpdateNetworkHostConfig() ) );
@@ -944,14 +944,14 @@ void IRCProtocol::slotDeleteHost()
TQString hostName = netConf->host->text();
if ( KMessageBox::warningContinueCancel(
Kopete::UI::Global::mainWidget(), i18n("<qt>Are you sure you want to delete the host <b>%1</b>?</qt>")
- .tqarg(hostName), i18n("Deleting Host"),
- KGuiItem(i18n("&Delete Host"),"editdelete"), TQString::tqfromLatin1("AskIRCDeleteHost")) == KMessageBox::Continue )
+ .arg(hostName), i18n("Deleting Host"),
+ KGuiItem(i18n("&Delete Host"),"editdelete"), TQString::fromLatin1("AskIRCDeleteHost")) == KMessageBox::Continue )
{
IRCHost *host = m_hosts[ hostName ];
if ( host )
{
disconnect( netConf->hostList, TQT_SIGNAL( selectionChanged() ), this, TQT_SLOT( slotUpdateNetworkHostConfig() ) );
- TQString entryText = host->host + TQString::tqfromLatin1(":") + TQString::number(host->port);
+ TQString entryText = host->host + TQString::fromLatin1(":") + TQString::number(host->port);
TQListBoxItem * justAdded = netConf->hostList->findItem( entryText );
netConf->hostList->removeItem( netConf->hostList->index( justAdded ) );
connect( netConf->hostList, TQT_SIGNAL( selectionChanged() ), this, TQT_SLOT( slotUpdateNetworkHostConfig() ) );
@@ -971,12 +971,12 @@ void IRCProtocol::slotNewNetwork()
// create a new network struct
IRCNetwork *net = new IRCNetwork;
// give it the name of 'New Network' (incrementing number if needed)
- TQString netName = TQString::tqfromLatin1( "New Network" );
+ TQString netName = TQString::fromLatin1( "New Network" );
if ( m_networks.find( netName ) )
{
int newIdx = 1;
do {
- netName = TQString::tqfromLatin1( "New Network #%1" ).tqarg( newIdx++ );
+ netName = TQString::fromLatin1( "New Network #%1" ).arg( newIdx++ );
}
while ( m_networks.find( netName ) && newIdx < 100 );
if ( newIdx == 100 ) // pathological case
@@ -1019,7 +1019,7 @@ void IRCProtocol::slotNewHost()
IRCNetwork *net = m_networks[ netConf->networkList->currentText() ];
net->hosts.append( host );
// add it to the gui
- TQString entryText = host->host + TQString::tqfromLatin1(":") + TQString::number(host->port);
+ TQString entryText = host->host + TQString::fromLatin1(":") + TQString::number(host->port);
netConf->hostList->insertItem( entryText );
// select it in the gui
TQListBoxItem * justAdded = netConf->hostList->findItem( entryText );
@@ -1203,7 +1203,7 @@ void IRCProtocol::slotMoveServerUp()
if( currentPos > 0 )
{
netConf->hostList->removeItem( currentPos );
- TQString entryText = selectedHost->host + TQString::tqfromLatin1(":") + TQString::number( selectedHost->port );
+ TQString entryText = selectedHost->host + TQString::fromLatin1(":") + TQString::number( selectedHost->port );
netConf->hostList->insertItem( entryText, --currentPos );
netConf->hostList->setSelected( currentPos, true );
}
@@ -1228,7 +1228,7 @@ void IRCProtocol::slotMoveServerDown()
if( currentPos < ( netConf->hostList->count() - 1 ) )
{
netConf->hostList->removeItem( currentPos );
- TQString entryText = selectedHost->host + TQString::tqfromLatin1(":") + TQString::number( selectedHost->port );
+ TQString entryText = selectedHost->host + TQString::fromLatin1(":") + TQString::number( selectedHost->port );
netConf->hostList->insertItem( entryText, ++currentPos );
netConf->hostList->setSelected( currentPos, true );
}
diff --git a/kopete/protocols/irc/ircprotocol.h b/kopete/protocols/irc/ircprotocol.h
index 725f078a..662b7f8a 100644
--- a/kopete/protocols/irc/ircprotocol.h
+++ b/kopete/protocols/irc/ircprotocol.h
@@ -56,7 +56,7 @@ class IRCProtocolHandler : public Kopete::MimeTypeHandler
void handleURL( const KURL &url ) const;
};
-static const TQString CHAT_VIEW( TQString::tqfromLatin1("kopete_chatwindow") );
+static const TQString CHAT_VIEW( TQString::fromLatin1("kopete_chatwindow") );
/**
* @author Nick Betcher <nbetcher@kde.org>
@@ -67,7 +67,7 @@ class IRCProtocol : public Kopete::Protocol
TQ_OBJECT
public:
- enum IRCtqStatus
+ enum IRCStatus
{
Offline = 1, //! An offline user.
Connecting = 2, //! User that is connecting.
@@ -105,7 +105,7 @@ public:
/**
* Maps the given IRC status to Kopete::OnlineStatus.
*/
- const Kopete::OnlineStatus statusLookup( IRCtqStatus status ) const;
+ const Kopete::OnlineStatus statusLookup( IRCStatus status ) const;
const Kopete::OnlineStatus m_ServerStatusOnline;
const Kopete::OnlineStatus m_ServerStatusOffline;
diff --git a/kopete/protocols/irc/ircservercontact.cpp b/kopete/protocols/irc/ircservercontact.cpp
index 9188963f..5be40dff 100644
--- a/kopete/protocols/irc/ircservercontact.cpp
+++ b/kopete/protocols/irc/ircservercontact.cpp
@@ -63,12 +63,12 @@ IRCServerContact::IRCServerContact(IRCContactManager *contactManager, const TQSt
TQObject::connect(Kopete::ChatSessionManager::self(), TQT_SIGNAL(viewCreated(KopeteView*)),
this, TQT_SLOT(slotViewCreated(KopeteView*)) );
- updatetqStatus();
+ updateStatus();
}
-void IRCServerContact::updatetqStatus()
+void IRCServerContact::updateStatus()
{
- KIRC::Engine::tqStatus status = kircEngine()->status();
+ KIRC::Engine::Status status = kircEngine()->status();
switch( status )
{
case KIRC::Engine::Idle:
@@ -92,7 +92,7 @@ void IRCServerContact::updatetqStatus()
const TQString IRCServerContact::caption() const
{
- return i18n("%1 @ %2").tqarg(ircAccount()->mySelf()->nickName() ).tqarg(
+ return i18n("%1 @ %2").arg(ircAccount()->mySelf()->nickName() ).arg(
kircEngine()->currentHost().isEmpty() ? ircAccount()->networkName() : kircEngine()->currentHost()
);
}
@@ -147,7 +147,7 @@ void IRCServerContact::slotIncomingNotice( const TQString &orig, const TQString
// Prefix missing.
// NOTICE AUTH :*** Checking Ident
- ircAccount()->appendMessage(i18n("NOTICE from %1: %2").tqarg(kircEngine()->currentHost(), notice),
+ ircAccount()->appendMessage(i18n("NOTICE from %1: %2").arg(kircEngine()->currentHost(), notice),
IRCAccount::NoticeReply);
} else {
@@ -155,13 +155,13 @@ void IRCServerContact::slotIncomingNotice( const TQString &orig, const TQString
// :somenick!~fooobar@somehostname.fi NOTICE foobar :hello
if (orig.contains('!')) {
- ircAccount()->appendMessage(i18n("NOTICE from %1 (%2): %3").tqarg(
+ ircAccount()->appendMessage(i18n("NOTICE from %1 (%2): %3").arg(
orig.section('!', 0, 0),
orig.section('!', 1, 1),
notice),
IRCAccount::NoticeReply);
} else {
- ircAccount()->appendMessage(i18n("NOTICE from %1: %2").tqarg(
+ ircAccount()->appendMessage(i18n("NOTICE from %1: %2").arg(
orig, notice), IRCAccount::NoticeReply);
}
}
@@ -184,7 +184,7 @@ void IRCServerContact::slotIncomingMotd(const TQString &message)
void IRCServerContact::slotCannotSendToChannel(const TQString &channel, const TQString &message)
{
- ircAccount()->appendMessage(TQString::tqfromLatin1("%1: %2").tqarg(channel).tqarg(message), IRCAccount::ErrorReply);
+ ircAccount()->appendMessage(TQString::fromLatin1("%1: %2").arg(channel).arg(message), IRCAccount::ErrorReply);
}
void IRCServerContact::appendMessage(Kopete::Message &msg)
diff --git a/kopete/protocols/irc/ircservercontact.h b/kopete/protocols/irc/ircservercontact.h
index b715a65b..f5167a9f 100644
--- a/kopete/protocols/irc/ircservercontact.h
+++ b/kopete/protocols/irc/ircservercontact.h
@@ -61,7 +61,7 @@ class IRCServerContact
virtual void slotSendMsg(Kopete::Message &message, Kopete::ChatSession *);
private slots:
- virtual void updatetqStatus();
+ virtual void updateStatus();
void slotViewCreated( KopeteView* );
void slotDumpMessages();
diff --git a/kopete/protocols/irc/irctransferhandler.cpp b/kopete/protocols/irc/irctransferhandler.cpp
index f4b5af10..e579e94a 100644
--- a/kopete/protocols/irc/irctransferhandler.cpp
+++ b/kopete/protocols/irc/irctransferhandler.cpp
@@ -164,7 +164,7 @@ void IRCTransferHandler::kioresult(KIO::Job *job)
// if (t->)
// kt->userAbort(i18n("User canceled transfer."));
// else
-// kt->userAbort(i18n("User canceled transfer for file:%1").tqarg(t->fileName()));
+// kt->userAbort(i18n("User canceled transfer for file:%1").arg(t->fileName()));
break;
default:
kdDebug(14120) << k_funcinfo << "Transfer halted:" << kt->error() << endl;
diff --git a/kopete/protocols/irc/ircusercontact.cpp b/kopete/protocols/irc/ircusercontact.cpp
index bec7c4b7..c4607cb9 100644
--- a/kopete/protocols/irc/ircusercontact.cpp
+++ b/kopete/protocols/irc/ircusercontact.cpp
@@ -53,39 +53,39 @@ IRCUserContact::IRCUserContact(IRCContactManager *contactManager, const TQString
mInfo.away = false;
mInfo.online = metaContact()->isTemporary();
- updatetqStatus();
+ updateStatus();
}
-void IRCUserContact::updatetqStatus()
+void IRCUserContact::updateStatus()
{
//kdDebug(14120) << k_funcinfo << endl;
- Kopete::OnlineStatus newtqStatus;
+ Kopete::OnlineStatus newStatus;
switch (kircEngine()->status())
{
case KIRC::Engine::Idle:
- newtqStatus = m_protocol->m_UserStatusOffline;
+ newStatus = m_protocol->m_UserStatusOffline;
break;
case KIRC::Engine::Connecting:
case KIRC::Engine::Authentifying:
if (this == ircAccount()->mySelf())
- newtqStatus = m_protocol->m_UserStatusConnecting;
+ newStatus = m_protocol->m_UserStatusConnecting;
else
- newtqStatus = m_protocol->m_UserStatusOffline;
+ newStatus = m_protocol->m_UserStatusOffline;
break;
case KIRC::Engine::Connected:
case KIRC::Engine::Closing:
if (mInfo.away)
- newtqStatus = m_protocol->m_UserStatusAway;
+ newStatus = m_protocol->m_UserStatusAway;
else if (mInfo.online)
- newtqStatus = m_protocol->m_UserStatusOnline;
+ newStatus = m_protocol->m_UserStatusOnline;
break;
default:
- newtqStatus = m_protocol->m_StatusUnknown;
+ newStatus = m_protocol->m_StatusUnknown;
}
// Try hard not to emit several onlineStatusChanged() signals.
@@ -105,31 +105,31 @@ void IRCUserContact::updatetqStatus()
for( TQValueList<IRCChannelContact*>::iterator it = channels.begin(); it != channels.end(); ++it )
{
IRCChannelContact *channel = *it;
- Kopete::OnlineStatus currenttqStatus = channel->manager()->contactOnlineStatus(this);
+ Kopete::OnlineStatus currentStatus = channel->manager()->contactOnlineStatus(this);
- //kdDebug(14120) << k_funcinfo << "iterating channel " << channel->nickName() << " internal status: " << currenttqStatus.internalStatus() << endl;
+ //kdDebug(14120) << k_funcinfo << "iterating channel " << channel->nickName() << " internal status: " << currentStatus.internalStatus() << endl;
- if( currenttqStatus.internalStatus() >= IRCProtocol::Online )
+ if( currentStatus.internalStatus() >= IRCProtocol::Online )
{
onlineStatusChanged = true;
- if( !(currenttqStatus.internalStatus() & IRCProtocol::Away) && newtqStatus == m_protocol->m_UserStatusAway )
+ if( !(currentStatus.internalStatus() & IRCProtocol::Away) && newStatus == m_protocol->m_UserStatusAway )
{
- setOnlineStatus( newtqStatus );
+ setOnlineStatus( newStatus );
//kdDebug(14120) << k_funcinfo << "was NOT away, but is now, channel " << channel->nickName() << endl;
adjustInternalOnlineStatusBits(channel, IRCProtocol::Away, AddBits);
}
- else if( (currenttqStatus.internalStatus() & IRCProtocol::Away) && newtqStatus == m_protocol->m_UserStatusOnline )
+ else if( (currentStatus.internalStatus() & IRCProtocol::Away) && newStatus == m_protocol->m_UserStatusOnline )
{
- setOnlineStatus( newtqStatus );
+ setOnlineStatus( newStatus );
//kdDebug(14120) << k_funcinfo << "was away, but not anymore, channel " << channel->nickName() << endl;
adjustInternalOnlineStatusBits(channel, IRCProtocol::Away, RemoveBits);
}
- else if( newtqStatus.internalStatus() < IRCProtocol::Away )
+ else if( newStatus.internalStatus() < IRCProtocol::Away )
{
//kdDebug(14120) << k_funcinfo << "offline or connecting?" << endl;
- channel->manager()->setContactOnlineStatus( this, newtqStatus );
+ channel->manager()->setContactOnlineStatus( this, newStatus );
}
}
}
@@ -137,7 +137,7 @@ void IRCUserContact::updatetqStatus()
if (!onlineStatusChanged) {
//kdDebug(14120) << k_funcinfo << "setting status at last" << endl;
- setOnlineStatus( newtqStatus );
+ setOnlineStatus( newStatus );
}
}
@@ -162,10 +162,10 @@ void IRCUserContact::slotUserOffline()
mInfo.online = false;
mInfo.away = false;
- updatetqStatus();
+ updateStatus();
if( !metaContact()->isTemporary() )
- kircEngine()->writeMessage( TQString::tqfromLatin1("WHOWAS %1").tqarg(m_nickName) );
+ kircEngine()->writeMessage( TQString::fromLatin1("WHOWAS %1").arg(m_nickName) );
removeProperty( m_protocol->propUserInfo );
removeProperty( m_protocol->propServer );
@@ -177,7 +177,7 @@ void IRCUserContact::setAway(bool isAway)
//kdDebug(14120) << k_funcinfo << isAway << endl;
mInfo.away = isAway;
- updatetqStatus();
+ updateStatus();
}
void IRCUserContact::incomingUserIsAway(const TQString &reason)
@@ -185,7 +185,7 @@ void IRCUserContact::incomingUserIsAway(const TQString &reason)
if( manager( Kopete::Contact::CannotCreate ) )
{
Kopete::Message msg( (Kopete::Contact*)ircAccount()->myServer(), mMyself,
- i18n("%1 is away (%2)").tqarg( m_nickName ).tqarg( reason ),
+ i18n("%1 is away (%2)").arg( m_nickName ).arg( reason ),
Kopete::Message::Internal, Kopete::Message::RichText, CHAT_VIEW );
manager(Kopete::Contact::CanCreate)->appendMessage(msg);
}
@@ -194,7 +194,7 @@ void IRCUserContact::incomingUserIsAway(const TQString &reason)
void IRCUserContact::userOnline()
{
mInfo.online = true;
- updatetqStatus();
+ updateStatus();
if (this != ircAccount()->mySelf() && !metaContact()->isTemporary() && ircAccount()->isConnected())
{
mOnlineTimer->start( 45000, true );
@@ -216,27 +216,27 @@ void IRCUserContact::slotUserInfo()
const TQString IRCUserContact::caption() const
{
- return i18n("%1 @ %2").tqarg(m_nickName).tqarg(kircEngine()->currentHost());
+ return i18n("%1 @ %2").arg(m_nickName).arg(kircEngine()->currentHost());
}
void IRCUserContact::slotOp()
{
- contactMode( TQString::tqfromLatin1("+o") );
+ contactMode( TQString::fromLatin1("+o") );
}
void IRCUserContact::slotDeop()
{
- contactMode( TQString::tqfromLatin1("-o") );
+ contactMode( TQString::fromLatin1("-o") );
}
void IRCUserContact::slotVoice()
{
- contactMode( TQString::tqfromLatin1("+v") );
+ contactMode( TQString::fromLatin1("+v") );
}
void IRCUserContact::slotDevoice()
{
- contactMode( TQString::tqfromLatin1("-v") );
+ contactMode( TQString::fromLatin1("-v") );
}
void IRCUserContact::slotBanHost()
@@ -260,7 +260,7 @@ void IRCUserContact::slotBanHostOnce()
Kopete::ContactPtrList members = mActiveManager->members();
TQString channelName = static_cast<IRCContact*>(members.first())->nickName();
- kircEngine()->mode(channelName, TQString::tqfromLatin1("+b *!*@%1").tqarg(mInfo.hostName));
+ kircEngine()->mode(channelName, TQString::fromLatin1("+b *!*@%1").arg(mInfo.hostName));
}
void IRCUserContact::slotBanUserHost()
@@ -284,7 +284,7 @@ void IRCUserContact::slotBanUserHostOnce()
Kopete::ContactPtrList members = mActiveManager->members();
TQString channelName = static_cast<IRCContact*>(members.first())->nickName();
- kircEngine()->mode(channelName, TQString::tqfromLatin1("+b *!*%1@%2").tqarg(mInfo.userName, mInfo.hostName));
+ kircEngine()->mode(channelName, TQString::fromLatin1("+b *!*%1@%2").arg(mInfo.userName, mInfo.hostName));
}
void IRCUserContact::slotBanDomain()
@@ -310,7 +310,7 @@ void IRCUserContact::slotBanDomainOnce()
TQString domain = mInfo.hostName.section('.', 1);
- kircEngine()->mode(channelName, TQString::tqfromLatin1("+b *!*@*.%1").tqarg(domain));
+ kircEngine()->mode(channelName, TQString::fromLatin1("+b *!*@*.%1").arg(domain));
}
void IRCUserContact::slotBanUserDomain()
@@ -336,7 +336,7 @@ void IRCUserContact::slotBanUserDomainOnce()
TQString domain = mInfo.hostName.section('.', 1);
- kircEngine()->mode(channelName, TQString::tqfromLatin1("+b *!*%1@*.%2").tqarg(mInfo.userName, domain));
+ kircEngine()->mode(channelName, TQString::fromLatin1("+b *!*%1@*.%2").arg(mInfo.userName, domain));
}
void IRCUserContact::slotKick()
@@ -350,7 +350,7 @@ void IRCUserContact::contactMode(const TQString &mode)
{
Kopete::ContactPtrList members = mActiveManager->members();
TQString channelName = static_cast<IRCContact*>(members.first())->nickName();
- kircEngine()->mode(channelName, TQString::tqfromLatin1("%1 %2").tqarg(mode).tqarg(m_nickName));
+ kircEngine()->mode(channelName, TQString::fromLatin1("%1 %2").arg(mode).arg(m_nickName));
}
void IRCUserContact::slotCtcpPing()
@@ -370,10 +370,10 @@ void IRCUserContact::newWhoIsUser(const TQString &username, const TQString &host
mInfo.hostName = hostname;
mInfo.realName = realname;
- if( onlinetqStatus().status() == Kopete::OnlineStatus::Offline )
+ if( onlineStatus().status() == Kopete::OnlineStatus::Offline )
{
- setProperty( m_protocol->propUserInfo, TQString::tqfromLatin1("%1@%2")
- .tqarg(mInfo.userName).tqarg(mInfo.hostName) );
+ setProperty( m_protocol->propUserInfo, TQString::fromLatin1("%1@%2")
+ .arg(mInfo.userName).arg(mInfo.hostName) );
setProperty( m_protocol->propServer, mInfo.serverName );
setProperty( m_protocol->propFullName, mInfo.realName );
}
@@ -382,8 +382,8 @@ void IRCUserContact::newWhoIsUser(const TQString &username, const TQString &host
void IRCUserContact::newWhoIsServer(const TQString &servername, const TQString &serverinfo)
{
mInfo.serverName = servername;
- if( metaContact()->isTemporary() || onlinetqStatus().status() == Kopete::OnlineStatus::Online
- || onlinetqStatus().status() == Kopete::OnlineStatus::Away )
+ if( metaContact()->isTemporary() || onlineStatus().status() == Kopete::OnlineStatus::Online
+ || onlineStatus().status() == Kopete::OnlineStatus::Away )
mInfo.serverInfo = serverinfo;
else
{
@@ -433,26 +433,26 @@ void IRCUserContact::whoIsComplete()
{
//User info
TQString msg = i18n("%1 is (%2@%3): %4<br/>")
- .tqarg(m_nickName)
- .tqarg(mInfo.userName)
- .tqarg(mInfo.hostName)
- .tqarg(mInfo.realName);
+ .arg(m_nickName)
+ .arg(mInfo.userName)
+ .arg(mInfo.hostName)
+ .arg(mInfo.realName);
if( mInfo.isIdentified )
- msg += i18n("%1 is authenticated with NICKSERV<br/>").tqarg(m_nickName);
+ msg += i18n("%1 is authenticated with NICKSERV<br/>").arg(m_nickName);
if( mInfo.isOperator )
- msg += i18n("%1 is an IRC operator<br/>").tqarg(m_nickName);
+ msg += i18n("%1 is an IRC operator<br/>").arg(m_nickName);
//Channels
- msg += i18n("on channels %1<br/>").tqarg(mInfo.channels.join(" ; "));
+ msg += i18n("on channels %1<br/>").arg(mInfo.channels.join(" ; "));
//Server
- msg += i18n("on IRC via server %1 ( %2 )<br/>").tqarg(mInfo.serverName).tqarg(mInfo.serverInfo);
+ msg += i18n("on IRC via server %1 ( %2 )<br/>").arg(mInfo.serverName).arg(mInfo.serverInfo);
//Idle
TQString idleTime = formattedIdleTime();
- msg += i18n("idle: %2<br/>").tqarg( idleTime.isEmpty() ? TQString::number(0) : idleTime );
+ msg += i18n("idle: %2<br/>").arg( idleTime.isEmpty() ? TQString::number(0) : idleTime );
//End
ircAccount()->appendMessage(msg, IRCAccount::InfoReply );
@@ -466,12 +466,12 @@ void IRCUserContact::whoWasComplete()
{
//User info
TQString msg = i18n("%1 was (%2@%3): %4\n")
- .tqarg(m_nickName)
- .tqarg(mInfo.userName)
- .tqarg(mInfo.hostName)
- .tqarg(mInfo.realName);
+ .arg(m_nickName)
+ .arg(mInfo.userName)
+ .arg(mInfo.hostName)
+ .arg(mInfo.realName);
- msg += i18n("Last Online: %1\n").tqarg(
+ msg += i18n("Last Online: %1\n").arg(
KGlobal::locale()->formatDateTime(
property( m_protocol->propLastSeen ).value().toDateTime()
)
@@ -489,8 +489,8 @@ TQString IRCUserContact::formattedName() const
void IRCUserContact::updateInfo()
{
- setProperty( m_protocol->propUserInfo, TQString::tqfromLatin1("%1@%2")
- .tqarg(mInfo.userName).tqarg(mInfo.hostName) );
+ setProperty( m_protocol->propUserInfo, TQString::fromLatin1("%1@%2")
+ .arg(mInfo.userName).arg(mInfo.hostName) );
setProperty( m_protocol->propServer, mInfo.serverName );
setProperty( m_protocol->propChannels, mInfo.channels.join(" ") );
setProperty( m_protocol->propHops, TQString::number(mInfo.hops) );
@@ -667,32 +667,32 @@ void IRCUserContact::slotIncomingModeChange( const TQString &channel, const TQSt
void IRCUserContact::adjustInternalOnlineStatusBits(IRCChannelContact *channel, unsigned statusAdjustment, bitAdjustment adj)
{
- Kopete::OnlineStatus currenttqStatus = channel->manager()->contactOnlineStatus(this);
- Kopete::OnlineStatus newtqStatus;
+ Kopete::OnlineStatus currentStatus = channel->manager()->contactOnlineStatus(this);
+ Kopete::OnlineStatus newStatus;
if (adj == RemoveBits) {
// If the bit is not set in the current internal status, stop here.
- if ((currenttqStatus.internalStatus() & ~statusAdjustment) == currenttqStatus.internalStatus())
+ if ((currentStatus.internalStatus() & ~statusAdjustment) == currentStatus.internalStatus())
return;
- newtqStatus = m_protocol->statusLookup(
- (IRCProtocol::IRCtqStatus)(currenttqStatus.internalStatus() & ~statusAdjustment)
+ newStatus = m_protocol->statusLookup(
+ (IRCProtocol::IRCStatus)(currentStatus.internalStatus() & ~statusAdjustment)
);
} else if (adj == AddBits) {
// If the bit is already set in the current internal status, stop here.
- if ((currenttqStatus.internalStatus() | statusAdjustment) == currenttqStatus.internalStatus())
+ if ((currentStatus.internalStatus() | statusAdjustment) == currentStatus.internalStatus())
return;
- newtqStatus = m_protocol->statusLookup(
- (IRCProtocol::IRCtqStatus)(currenttqStatus.internalStatus() | statusAdjustment)
+ newStatus = m_protocol->statusLookup(
+ (IRCProtocol::IRCStatus)(currentStatus.internalStatus() | statusAdjustment)
);
}
- channel->manager()->setContactOnlineStatus(this, newtqStatus);
+ channel->manager()->setContactOnlineStatus(this, newStatus);
}
void IRCUserContact::privateMessage(IRCContact *from, IRCContact *to, const TQString &message)
diff --git a/kopete/protocols/irc/ircusercontact.h b/kopete/protocols/irc/ircusercontact.h
index 269cd40c..dbf4b51c 100644
--- a/kopete/protocols/irc/ircusercontact.h
+++ b/kopete/protocols/irc/ircusercontact.h
@@ -94,7 +94,7 @@ public:
public slots:
/** \brief Updates online status for channels based on current internal status.
*/
- virtual void updatetqStatus();
+ virtual void updateStatus();
virtual void sendFile(const KURL &sourceURL, const TQString&, unsigned int);
diff --git a/kopete/protocols/irc/kcodecaction.cpp b/kopete/protocols/irc/kcodecaction.cpp
index 5dca8771..1560ea9b 100644
--- a/kopete/protocols/irc/kcodecaction.cpp
+++ b/kopete/protocols/irc/kcodecaction.cpp
@@ -15,7 +15,7 @@
*************************************************************************
*/
#include <tqstringlist.h>
-#include <tqtextcodec.h>
+#include <textcodec.h>
#include <kcharsets.h>
#include "kcodecaction.h"
diff --git a/kopete/protocols/irc/ksparser.cpp b/kopete/protocols/irc/ksparser.cpp
index 79ff605e..ab7f1127 100644
--- a/kopete/protocols/irc/ksparser.cpp
+++ b/kopete/protocols/irc/ksparser.cpp
@@ -25,7 +25,7 @@ Modified by Jason Keirstead <jason@keirstead.org>
#include <kdebug.h>
#include <tqbuffer.h>
#include <tqdatastream.h>
-#include <tqstylesheet.h>
+#include <stylesheet.h>
#include "ksparser.h"
#include <stdlib.h>
@@ -117,17 +117,17 @@ TQCString KSParser::_parse(const TQCString &message)
}
else
{
- toAppend = popTag(TQString::tqfromLatin1("span"));
+ toAppend = popTag(TQString::fromLatin1("span"));
}
break;
case 0x07: //System bell: ^G
- KNotifyClient::beep( TQString::tqfromLatin1("IRC beep event received in a message") );
+ KNotifyClient::beep( TQString::fromLatin1("IRC beep event received in a message") );
break;
case '\t': // 0x09
- toAppend = TQString::tqfromLatin1("&nbsp;&nbsp;&nbsp;&nbsp;");
+ toAppend = TQString::fromLatin1("&nbsp;&nbsp;&nbsp;&nbsp;");
break;
case '\n': // 0x0D
- toAppend= TQString::tqfromLatin1("<br/>");
+ toAppend= TQString::fromLatin1("<br/>");
break;
case 0x0D: // Italics: ^N
toAppend = toggleTag("i");
@@ -145,14 +145,14 @@ TQCString KSParser::_parse(const TQCString &message)
toAppend = toggleTag("u");
break;
case '<':
- toAppend = TQString::tqfromLatin1("&lt;");
+ toAppend = TQString::fromLatin1("&lt;");
break;
case '>':
- toAppend = TQString::tqfromLatin1("&gt;");
+ toAppend = TQString::fromLatin1("&gt;");
break;
default:
if (cur < TQChar(' ')) // search for control characters
- toAppend = TQString::tqfromLatin1("&lt;%1&gt;").tqarg(cur, 2, 16).upper();
+ toAppend = TQString::fromLatin1("&lt;%1&gt;").arg(cur, 2, 16).upper();
else
toAppend = TQStyleSheet::escape(cur);
}
@@ -193,14 +193,14 @@ TQString KSParser::pushColorTag(const TQColor &fgColor, const TQColor &bgColor)
TQString tagStyle;
if (fgColor.isValid())
- tagStyle += TQString::tqfromLatin1("color:%1;").tqarg(fgColor.name());
+ tagStyle += TQString::fromLatin1("color:%1;").arg(fgColor.name());
if (bgColor.isValid())
- tagStyle += TQString::tqfromLatin1("background-color:%1;").tqarg(bgColor.name());
+ tagStyle += TQString::fromLatin1("background-color:%1;").arg(bgColor.name());
if(!tagStyle.isEmpty())
- tagStyle = TQString::tqfromLatin1("style=\"%1\"").tqarg(tagStyle);
+ tagStyle = TQString::fromLatin1("style=\"%1\"").arg(tagStyle);
- return pushTag(TQString::tqfromLatin1("span"), tagStyle);;
+ return pushTag(TQString::fromLatin1("span"), tagStyle);;
}
TQString KSParser::popTag(const TQString &tag)
diff --git a/kopete/protocols/irc/libkirc/kircengine.cpp b/kopete/protocols/irc/libkirc/kircengine.cpp
index ac1fd698..8a81d848 100644
--- a/kopete/protocols/irc/libkirc/kircengine.cpp
+++ b/kopete/protocols/irc/libkirc/kircengine.cpp
@@ -30,7 +30,7 @@
#include <klocale.h>
#include <kstandarddirs.h>
-#include <tqtextcodec.h>
+#include <textcodec.h>
#include <tqtimer.h>
//Needed for getuid / getpwuid
@@ -51,10 +51,10 @@ using namespace KIRC;
/* Please note that the regular expression "[\\r\\n]*$" is used in a TQString::replace statement many times.
* This gets rid of trailing \r\n, \r, \n, and \n\r characters.
*/
-const TQRegExp Engine::m_RemoveLinefeeds( TQString::tqfromLatin1("[\\r\\n]*$") );
+const TQRegExp Engine::m_RemoveLinefeeds( TQString::fromLatin1("[\\r\\n]*$") );
Engine::Engine(TQObject *parent, const char *name)
- : TQObject(parent, TQString::tqfromLatin1("[KIRC::Engine]%1").tqarg(name).latin1()),
+ : TQObject(parent, TQString::fromLatin1("[KIRC::Engine]%1").arg(name).latin1()),
m_status(Idle),
m_FailedNickOnLogin(false),
m_useSSL(false),
@@ -74,9 +74,9 @@ Engine::Engine(TQObject *parent, const char *name)
bindNumericReplies();
bindCtcp();
- m_VersionString = TQString::tqfromLatin1("Anonymous client using the KIRC engine.");
- m_UserString = TQString::tqfromLatin1("Response not supplied by user.");
- m_SourceString = TQString::tqfromLatin1("Unknown client, known source.");
+ m_VersionString = TQString::fromLatin1("Anonymous client using the KIRC engine.");
+ m_UserString = TQString::fromLatin1("Response not supplied by user.");
+ m_SourceString = TQString::fromLatin1("Unknown client, known source.");
defaultCodec = TQTextCodec::codecForMib(106); // UTF8 mib is 106
kdDebug(14120) << "Setting default engine codec, " << defaultCodec->name() << endl;
@@ -133,14 +133,14 @@ void Engine::setUseSSL( bool useSSL )
}
}
-void Engine::settqStatus(Engine::tqStatus status)
+void Engine::setStatus(Engine::Status status)
{
kdDebug(14120) << k_funcinfo << status << endl;
if (m_status == status)
return;
-// Engine::tqStatus oldtqStatus = m_status;
+// Engine::Status oldStatus = m_status;
m_status = status;
emit statusChanged(status);
@@ -169,16 +169,16 @@ void Engine::settqStatus(Engine::tqStatus status)
case Closing:
m_sock->close();
m_sock->reset();
- settqStatus(Idle);
+ setStatus(Idle);
break;
case AuthentifyingFailed:
- settqStatus(Closing);
+ setStatus(Closing);
break;
case Timeout:
- settqStatus(Closing);
+ setStatus(Closing);
break;
case Disconnected:
- settqStatus(Closing);
+ setStatus(Closing);
break;
}
}
@@ -200,23 +200,23 @@ void Engine::connectToServer(const TQString &host, TQ_UINT16 port, const TQStrin
if( m_sock->startAsyncConnect() == 0 )
{
kdDebug(14120) << k_funcinfo << "Success!. Status: " << m_sock->socketStatus() << endl;
- settqStatus(Connecting);
+ setStatus(Connecting);
}
else
{
kdDebug(14120) << k_funcinfo << "Failed. Status: " << m_sock->socketStatus() << endl;
- settqStatus(Disconnected);
+ setStatus(Disconnected);
}
}
void Engine::slotConnected()
{
- settqStatus(Authentifying);
+ setStatus(Authentifying);
}
void Engine::slotConnectionClosed()
{
- settqStatus(Disconnected);
+ setStatus(Disconnected);
}
void Engine::error(int errCode)
@@ -225,7 +225,7 @@ void Engine::error(int errCode)
if (m_sock->socketStatus () != KExtendedSocket::connecting)
{
// Connection in progress.. This is a signal fired wrong
- settqStatus(Disconnected);
+ setStatus(Disconnected);
}
}
@@ -250,7 +250,7 @@ void Engine::setSourceString(const TQString &newString)
void Engine::setUserName(const TQString &newName)
{
if(newName.isEmpty())
- m_Username = TQString::tqfromLatin1(getpwuid(getuid())->pw_name);
+ m_Username = TQString::fromLatin1(getpwuid(getuid())->pw_name);
else
m_Username = newName;
m_Username.remove(m_RemoveLinefeeds);
@@ -259,7 +259,7 @@ void Engine::setUserName(const TQString &newName)
void Engine::setRealName(const TQString &newName)
{
if(newName.isEmpty())
- m_realName = TQString::tqfromLatin1(getpwuid(getuid())->pw_gecos);
+ m_realName = TQString::fromLatin1(getpwuid(getuid())->pw_gecos);
else
m_realName = newName;
m_realName.remove(m_RemoveLinefeeds);
@@ -443,7 +443,7 @@ bool Engine::invokeCtcpCommandOfMessage(const TQDict<MessageRedirector> &map, Me
kdDebug(14120) << "Method error for line:" << ctcpMsg.raw() << endl;
writeCtcpErrorMessage(msg.prefix(), msg.ctcpRaw(),
- TQString::tqfromLatin1("%1 internal error(s)").tqarg(errors.size()));
+ TQString::fromLatin1("%1 internal error(s)").arg(errors.size()));
}
else
{
diff --git a/kopete/protocols/irc/libkirc/kircengine.h b/kopete/protocols/irc/libkirc/kircengine.h
index 1be8651c..9f488d47 100644
--- a/kopete/protocols/irc/libkirc/kircengine.h
+++ b/kopete/protocols/irc/libkirc/kircengine.h
@@ -72,7 +72,7 @@ class Engine
// TQ_PROPERTY(TQString nick READ nick)
// TQ_PROPERTY(TQStringList portList)
- Q_ENUMS(tqStatus)
+ Q_ENUMS(Status)
public:
enum Error
@@ -84,7 +84,7 @@ public:
MethodFailed
};
- enum tqStatus
+ enum Status
{
Idle,
Connecting,
@@ -165,7 +165,7 @@ public:
KExtendedSocket *socket()
{ return m_sock; };
- inline KIRC::Engine::tqStatus status() const
+ inline KIRC::Engine::Status status() const
{ return m_status; }
inline bool isDisconnected() const
@@ -275,7 +275,7 @@ public slots:
void showInfoDialog();
signals:
- void statusChanged(KIRC::Engine::tqStatus newtqStatus);
+ void statusChanged(KIRC::Engine::Status newStatus);
void internalError(KIRC::Engine::Error, KIRC::Message &);
void receivedMessage(KIRC::Message &);
@@ -479,7 +479,7 @@ private:
void bindNumericReplies();
void bindCtcp();
- void settqStatus(KIRC::Engine::tqStatus status);
+ void setStatus(KIRC::Engine::Status status);
bool invokeCtcpCommandOfMessage(const TQDict<KIRC::MessageRedirector> &map, KIRC::Message &message);
/*
@@ -493,7 +493,7 @@ private:
//Static regexes
static const TQRegExp m_RemoveLinefeeds;
- KIRC::Engine::tqStatus m_status;
+ KIRC::Engine::Status m_status;
TQString m_Host;
TQ_UINT16 m_Port;
diff --git a/kopete/protocols/irc/libkirc/kircengine_commands.cpp b/kopete/protocols/irc/libkirc/kircengine_commands.cpp
index e0e63909..acea30e7 100644
--- a/kopete/protocols/irc/libkirc/kircengine_commands.cpp
+++ b/kopete/protocols/irc/libkirc/kircengine_commands.cpp
@@ -48,7 +48,7 @@ void Engine::away(bool isAway, const TQString &awayMessage)
if( !awayMessage.isEmpty() )
writeMessage("AWAY", TQString(), awayMessage);
else
- writeMessage("AWAY", TQString(), TQString::tqfromLatin1("I'm away."));
+ writeMessage("AWAY", TQString(), TQString::fromLatin1("I'm away."));
else
writeMessage("AWAY", TQString());
}
@@ -56,20 +56,20 @@ void Engine::away(bool isAway, const TQString &awayMessage)
// FIXME: Really handle this message
void Engine::error(Message &)
{
- settqStatus(Closing);
+ setStatus(Closing);
}
void Engine::ison(const TQStringList &nickList)
{
if (!nickList.isEmpty())
{
- TQString statement = TQString::tqfromLatin1("ISON");
+ TQString statement = TQString::fromLatin1("ISON");
for (TQStringList::ConstIterator it = nickList.begin(); it != nickList.end(); ++it)
{
if ((statement.length()+(*it).length())>509) // 512(max buf)-2("\r\n")-1(<space separator>)
{
writeMessage(statement);
- statement = TQString::tqfromLatin1("ISON ") + (*it);
+ statement = TQString::fromLatin1("ISON ") + (*it);
}
else
statement.append(TQChar(' ') + (*it));
@@ -201,7 +201,7 @@ void Engine::quit(const TQString &reason, bool /*now*/)
if (isConnected())
writeMessage("QUIT", TQString(), reason);
- settqStatus(Closing);
+ setStatus(Closing);
}
void Engine::quit(Message &msg)
diff --git a/kopete/protocols/irc/libkirc/kircengine_ctcp.cpp b/kopete/protocols/irc/libkirc/kircengine_ctcp.cpp
index 05477710..0159f790 100644
--- a/kopete/protocols/irc/libkirc/kircengine_ctcp.cpp
+++ b/kopete/protocols/irc/libkirc/kircengine_ctcp.cpp
@@ -109,10 +109,10 @@ bool Engine::CtcpReply_action(Message &msg)
// FIXME: the API can now answer to help commands.
void Engine::CtcpQuery_clientinfo(Message &msg)
{
- TQString clientinfo = customCtcpMap[ TQString::tqfromLatin1("clientinfo") ];
+ TQString clientinfo = customCtcpMap[ TQString::fromLatin1("clientinfo") ];
if (clientinfo.isNull())
- clientinfo = TQString::tqfromLatin1("The following commands are supported, but "
+ clientinfo = TQString::fromLatin1("The following commands are supported, but "
"without sub-command help: VERSION, CLIENTINFO, USERINFO, TIME, SOURCE, PING,"
"ACTION.");
@@ -132,8 +132,8 @@ void Engine::CtcpRequest_dcc(const TQString &nickname, const TQString &fileName,
case Transfer::Chat:
{
writeCtcpQueryMessage(nickname, TQString(),
- TQString::tqfromLatin1("DCC"),
- TQStringList(TQString::tqfromLatin1("CHAT")) << TQString::tqfromLatin1("chat") <<
+ TQString::fromLatin1("DCC"),
+ TQStringList(TQString::fromLatin1("CHAT")) << TQString::fromLatin1("chat") <<
m_sock->localAddress()->nodeName() << TQString::number(port)
);
break;
@@ -154,8 +154,8 @@ void Engine::CtcpRequest_dcc(const TQString &nickname, const TQString &fileName,
kdDebug(14120) << "Starting DCC file outgoing transfer." << endl;
writeCtcpQueryMessage(nickname, TQString(),
- TQString::tqfromLatin1("DCC"),
- TQStringList(TQString::tqfromLatin1("SEND")) << noWhiteSpace << ipNumber <<
+ TQString::fromLatin1("DCC"),
+ TQStringList(TQString::fromLatin1("SEND")) << noWhiteSpace << ipNumber <<
TQString::number(server->port()) << TQString::number(file.size())
);
break;
@@ -173,7 +173,7 @@ void Engine::CtcpQuery_dcc(Message &msg)
Message &ctcpMsg = msg.ctcpMessage();
TQString dccCommand = ctcpMsg.arg(0).upper();
- if (dccCommand == TQString::tqfromLatin1("CHAT"))
+ if (dccCommand == TQString::fromLatin1("CHAT"))
{
// if(ctcpMsg.argsSize()!=4) return false;
@@ -196,7 +196,7 @@ void Engine::CtcpQuery_dcc(Message &msg)
Transfer::Chat );
}
}
- else if (dccCommand == TQString::tqfromLatin1("SEND"))
+ else if (dccCommand == TQString::fromLatin1("SEND"))
{
// if(ctcpMsg.argsSize()!=5) return false;
@@ -253,7 +253,7 @@ void Engine::CtcpRequest_ping(const TQString &target)
TQString timeReply;
if( Entity::isChannel(target) )
- timeReply = TQString::tqfromLatin1("%1.%2").arg(time.tv_sec).arg(time.tv_usec);
+ timeReply = TQString::fromLatin1("%1.%2").arg(time.tv_sec).arg(time.tv_usec);
else
timeReply = TQString::number( time.tv_sec );
@@ -275,7 +275,7 @@ void Engine::CtcpReply_ping(Message &msg)
if (gettimeofday(&time, 0) == 0)
{
// FIXME: the time code is wrong for usec
- TQString timeReply = TQString::tqfromLatin1("%1.%2").arg(time.tv_sec).arg(time.tv_usec);
+ TQString timeReply = TQString::fromLatin1("%1.%2").arg(time.tv_sec).arg(time.tv_usec);
double newTime = timeReply.toDouble();
double oldTime = msg.suffix().section(' ',0, 0).toDouble();
double difference = newTime - oldTime;
@@ -295,10 +295,10 @@ void Engine::CtcpReply_ping(Message &msg)
TQString millSec = diffString.section('.', 1, 1);
millSec.remove(millSec.find('.'), 1);
millSec.truncate(3);
- diffString = TQString::tqfromLatin1("%1 seconds, %2 milliseconds").arg(seconds).arg(millSec);
+ diffString = TQString::fromLatin1("%1 seconds, %2 milliseconds").arg(seconds).arg(millSec);
}
- emit incomingCtcpReply(TQString::tqfromLatin1("PING"), msg.nickFromPrefix(), diffString);
+ emit incomingCtcpReply(TQString::fromLatin1("PING"), msg.nickFromPrefix(), diffString);
}
// else
// ((MessageRedirector *)sender())->error("failed to get current time");
@@ -313,13 +313,13 @@ void Engine::CtcpQuery_source(Message &msg)
void Engine::CtcpQuery_time(Message &msg)
{
writeCtcpReplyMessage(msg.nickFromPrefix(), TQString(),
- msg.ctcpMessage().command(), TQDateTime::tqcurrentDateTime().toString(),
+ msg.ctcpMessage().command(), TQDateTime::currentDateTime().toString(),
TQString(), false);
}
void Engine::CtcpQuery_userinfo(Message &msg)
{
- TQString userinfo = customCtcpMap[ TQString::tqfromLatin1("userinfo") ];
+ TQString userinfo = customCtcpMap[ TQString::fromLatin1("userinfo") ];
if (userinfo.isNull())
userinfo = m_UserString;
@@ -335,7 +335,7 @@ void Engine::CtcpRequest_version(const TQString &target)
void Engine::CtcpQuery_version(Message &msg)
{
- TQString response = customCtcpMap[ TQString::tqfromLatin1("version") ];
+ TQString response = customCtcpMap[ TQString::fromLatin1("version") ];
kdDebug(14120) << "Version check: " << response << endl;
if (response.isNull())
diff --git a/kopete/protocols/irc/libkirc/kircengine_numericreplies.cpp b/kopete/protocols/irc/libkirc/kircengine_numericreplies.cpp
index 3d7b896b..67d3a842 100644
--- a/kopete/protocols/irc/libkirc/kircengine_numericreplies.cpp
+++ b/kopete/protocols/irc/libkirc/kircengine_numericreplies.cpp
@@ -117,7 +117,7 @@ void Engine::numericReply_001(Message &msg)
*/
emitSuffix(msg);
- settqStatus(Connected);
+ setStatus(Connected);
}
/* 002: ":Your host is <servername>, running version <ver>"
diff --git a/kopete/protocols/irc/libkirc/kircentity.cpp b/kopete/protocols/irc/libkirc/kircentity.cpp
index 2086ab9d..74781e48 100644
--- a/kopete/protocols/irc/libkirc/kircentity.cpp
+++ b/kopete/protocols/irc/libkirc/kircentity.cpp
@@ -29,16 +29,16 @@ using namespace KNetwork;
* where user and host are optionnal.
* NOTE: If changes are done to the regexp string, update also the sm_userStrictRegExp regexp string.
*/
-const TQRegExp Entity::sm_userRegExp(TQString::tqfromLatin1("^([^\\s,:!@]+)(?:(?:!([^\\s,:!@]+))?(?:@([^\\s,!@]+)))?$"));
+const TQRegExp Entity::sm_userRegExp(TQString::fromLatin1("^([^\\s,:!@]+)(?:(?:!([^\\s,:!@]+))?(?:@([^\\s,!@]+)))?$"));
/**
* Regexp to match strictly the complete user definition:
* nick!user@host
* NOTE: If changes are done to the regexp string, update also the sm_userRegExp regexp string.
*/
-const TQRegExp Entity::sm_userStrictRegExp(TQString::tqfromLatin1("^([^\\s,:!@]+)!([^\\s,:!@]+)@([^\\s,:!@]+)$"));
+const TQRegExp Entity::sm_userStrictRegExp(TQString::fromLatin1("^([^\\s,:!@]+)!([^\\s,:!@]+)@([^\\s,:!@]+)$"));
-const TQRegExp Entity::sm_channelRegExp( TQString::tqfromLatin1("^[#!+&][^\\s,]+$") );
+const TQRegExp Entity::sm_channelRegExp( TQString::fromLatin1("^[#!+&][^\\s,]+$") );
Entity::Entity(const TQString &, const Type type)
: TQObject(0, "KIRC::Entity"),
diff --git a/kopete/protocols/irc/libkirc/kircmessage.cpp b/kopete/protocols/irc/libkirc/kircmessage.cpp
index 6f45b0c1..8a48ce52 100644
--- a/kopete/protocols/irc/libkirc/kircmessage.cpp
+++ b/kopete/protocols/irc/libkirc/kircmessage.cpp
@@ -99,14 +99,14 @@ void Message::writeRawMessage(Engine *engine, const TQTextCodec *codec, const TQ
return;
}
- TQString txt = str + TQString::tqfromLatin1("\r\n");
+ TQString txt = str + TQString::fromLatin1("\r\n");
TQCString s(codec->fromUnicode(txt));
kdDebug(14120) << "Message is " << s.length() << " chars" << endl;
// FIXME: Should check the amount of data really writen.
int wrote = engine->socket()->writeBlock(s.data(), s.length());
- kdDebug(14121) << TQString::tqfromLatin1("(%1 bytes) >> %2").tqarg(wrote).tqarg(str) << endl;
+ kdDebug(14121) << TQString::fromLatin1("(%1 bytes) >> %2").arg(wrote).arg(str) << endl;
}
void Message::writeMessage(Engine *engine, const TQTextCodec *codec, const TQString &message)
@@ -123,7 +123,7 @@ void Message::writeMessage(Engine *engine, const TQTextCodec *codec,
msg += TQChar(' ') + args.join(TQChar(' ')).stripWhiteSpace(); // some extra check should be done here
if (!suffix.isNull())
- msg = msg.stripWhiteSpace() + TQString::tqfromLatin1(" :") + suffix;
+ msg = msg.stripWhiteSpace() + TQString::fromLatin1(" :") + suffix;
writeMessage(engine, codec, msg);
}
@@ -145,7 +145,7 @@ void Message::writeCtcpMessage(Engine *engine, const TQTextCodec *codec,
ctcpMsg += TQChar(' ') + ctcpArgs.join(TQChar(' ')).stripWhiteSpace(); // some extra check should be done here
if (!ctcpSuffix.isNull())
- ctcpMsg += TQString::tqfromLatin1(" :") + ctcpSuffix;
+ ctcpMsg += TQString::fromLatin1(" :") + ctcpSuffix;
writeMessage(engine, codec, command, to, suffix + TQChar(0x01) + ctcpQuote(ctcpMsg) + TQChar(0x01));
}
@@ -169,10 +169,10 @@ Message Message::parse(Engine *engine, const TQTextCodec *codec, bool *parseSucc
// Some servers send '\n' instead of '\r\n' that the RFCs say they should be sending.
if (length > 1 && raw.at(length-2) == '\n') {
- raw.tqat(length-2) = '\0';
+ raw.at(length-2) = '\0';
}
if (length > 2 && raw.at(length-3) == '\r') {
- raw.tqat(length-3) = '\0';
+ raw.at(length-3) = '\0';
}
kdDebug(14121) << "<< " << raw << endl;
@@ -202,9 +202,9 @@ TQString Message::quote(const TQString &str)
TQString tmp = str;
TQChar q('\020');
tmp.replace(q, q+TQString(q));
- tmp.replace(TQChar('\r'), q+TQString::tqfromLatin1("r"));
- tmp.replace(TQChar('\n'), q+TQString::tqfromLatin1("n"));
- tmp.replace(TQChar('\0'), q+TQString::tqfromLatin1("0"));
+ tmp.replace(TQChar('\r'), q+TQString::fromLatin1("r"));
+ tmp.replace(TQChar('\n'), q+TQString::fromLatin1("n"));
+ tmp.replace(TQChar('\0'), q+TQString::fromLatin1("0"));
return tmp;
}
@@ -230,8 +230,8 @@ TQString Message::unquote(const TQString &str)
TQString Message::ctcpQuote(const TQString &str)
{
TQString tmp = str;
- tmp.replace( TQChar('\\'), TQString::tqfromLatin1("\\\\"));
- tmp.replace( (char)1, TQString::tqfromLatin1("\\1"));
+ tmp.replace( TQChar('\\'), TQString::fromLatin1("\\\\"));
+ tmp.replace( (char)1, TQString::fromLatin1("\\1"));
return tmp;
}
@@ -317,7 +317,7 @@ TQString Message::toString() const
for (TQStringList::ConstIterator it = m_args.begin(); it != m_args.end(); ++it)
msg += TQChar(' ') + *it;
if (!m_suffix.isNull())
- msg += TQString::tqfromLatin1(" :") + m_suffix;
+ msg += TQString::fromLatin1(" :") + m_suffix;
return msg;
}
diff --git a/kopete/protocols/irc/libkirc/kircmessage.h b/kopete/protocols/irc/libkirc/kircmessage.h
index fb38a476..cd409323 100644
--- a/kopete/protocols/irc/libkirc/kircmessage.h
+++ b/kopete/protocols/irc/libkirc/kircmessage.h
@@ -25,7 +25,7 @@
#include <tqdict.h>
#include <tqstring.h>
#include <tqstringlist.h>
-#include <tqtextcodec.h>
+#include <textcodec.h>
#include <tqregexp.h>
#include <kopetemessage.h>
diff --git a/kopete/protocols/irc/libkirc/kircmessageredirector.cpp b/kopete/protocols/irc/libkirc/kircmessageredirector.cpp
index ae9854f1..2e1d0b4c 100644
--- a/kopete/protocols/irc/libkirc/kircmessageredirector.cpp
+++ b/kopete/protocols/irc/libkirc/kircmessageredirector.cpp
@@ -80,9 +80,9 @@ bool MessageRedirector::checkValidity(const Message &msg)
/*
if ( msg.isNumeric() &&
( msg.argsSize() > 0 && (
- msg.tqarg(0) == m_Nickname ||
- msg.tqarg(0) == m_PendingNick ||
- msg.tqarg(0) == TQString::tqfromLatin1("*")
+ msg.arg(0) == m_Nickname ||
+ msg.arg(0) == m_PendingNick ||
+ msg.arg(0) == TQString::fromLatin1("*")
)
)
)
diff --git a/kopete/protocols/irc/libkirc/kirctransfer.cpp b/kopete/protocols/irc/libkirc/kirctransfer.cpp
index 3c6d1907..68e28f0c 100644
--- a/kopete/protocols/irc/libkirc/kirctransfer.cpp
+++ b/kopete/protocols/irc/libkirc/kirctransfer.cpp
@@ -94,11 +94,11 @@ Transfer::~Transfer()
// m_file is automatically closed on destroy.
}
-Transfer::tqStatus Transfer::status() const
+Transfer::Status Transfer::status() const
{
if(m_socket)
{
-// return (Transfer::tqStatus)m_socket->socketStatus();
+// return (Transfer::Status)m_socket->socketStatus();
return Connected;
}
return Error_NoSocket;
diff --git a/kopete/protocols/irc/libkirc/kirctransfer.h b/kopete/protocols/irc/libkirc/kirctransfer.h
index 950c0e96..a64a9ddb 100644
--- a/kopete/protocols/irc/libkirc/kirctransfer.h
+++ b/kopete/protocols/irc/libkirc/kirctransfer.h
@@ -22,7 +22,7 @@
#include <tqfile.h>
#include <tqhostaddress.h>
#include <tqobject.h>
-#include <tqtextstream.h>
+#include <textstream.h>
class KExtendedSocket;
@@ -47,7 +47,7 @@ public:
FileIncoming
};
- enum tqStatus {
+ enum Status {
Error_NoSocket = -2,
Error = -1,
Idle = 0,
@@ -101,7 +101,7 @@ public:
{ return m_nick; }
Type type() const
{ return m_type; }
- tqStatus status() const;
+ Status status() const;
/* Start the transfer.
* If not connected connect to client.
diff --git a/kopete/protocols/irc/libkirc/kirctransferhandler.cpp b/kopete/protocols/irc/libkirc/kirctransferhandler.cpp
index 3a5ef27c..00d893da 100644
--- a/kopete/protocols/irc/libkirc/kirctransferhandler.cpp
+++ b/kopete/protocols/irc/libkirc/kirctransferhandler.cpp
@@ -21,7 +21,7 @@
#include <tqfile.h>
#include <tqregexp.h>
-#include <tqtextcodec.h>
+#include <textcodec.h>
#include "kirctransferserver.h"
diff --git a/kopete/protocols/irc/libkirc/ksslsocket.cpp b/kopete/protocols/irc/libkirc/ksslsocket.cpp
index 2bf3910a..6d6c2ba2 100644
--- a/kopete/protocols/irc/libkirc/ksslsocket.cpp
+++ b/kopete/protocols/irc/libkirc/ksslsocket.cpp
@@ -372,7 +372,7 @@ int KSSLSocket::verifyCertificate()
"does not match the one the "
"certificate was issued to.");
result = messageBox( KIO::SlaveBase::WarningYesNoCancel,
- msg.tqarg(ourHost),
+ msg.arg(ourHost),
i18n("Server Authentication"),
i18n("&Details"),
i18n("Co&ntinue") );
@@ -382,7 +382,7 @@ int KSSLSocket::verifyCertificate()
TQString msg = i18n("The server certificate failed the "
"authenticity test (%1).");
result = messageBox( KIO::SlaveBase::WarningYesNoCancel,
- msg.tqarg(ourHost),
+ msg.arg(ourHost),
i18n("Server Authentication"),
i18n("&Details"),
i18n("Co&ntinue") );
diff --git a/kopete/protocols/irc/ui/channellist.cpp b/kopete/protocols/irc/ui/channellist.cpp
index 6426224a..ea2c5d19 100644
--- a/kopete/protocols/irc/ui/channellist.cpp
+++ b/kopete/protocols/irc/ui/channellist.cpp
@@ -32,7 +32,7 @@
#include <tqpushbutton.h>
#include <tqheader.h>
#include <klistview.h>
-#include <tqlayout.h>
+#include <layout.h>
#include <tqtooltip.h>
#include <tqtimer.h>
#include <tqspinbox.h>
@@ -106,7 +106,7 @@ void ChannelListItem::paintCell( TQPainter *p, const TQColorGroup &cg, int colum
const BackgroundMode bgmode = lv->viewport()->backgroundMode();
const TQColorGroup::ColorRole crole = TQPalette::backgroundRoleFromMode( bgmode );
- if ( _cg.brush( crole ) != lv->tqcolorGroup().brush( crole ) )
+ if ( _cg.brush( crole ) != lv->colorGroup().brush( crole ) )
p->fillRect( 0, 0, width, height(), _cg.brush( crole ) );
else
{
@@ -118,8 +118,8 @@ void ChannelListItem::paintCell( TQPainter *p, const TQColorGroup &cg, int colum
if ( lv->isEnabled() )
how |= TQStyle::Style_Enabled;
- lv->tqstyle().tqdrawComplexControl( TQStyle::CC_ListView,
- p, lv, TQRect( 0, 0, width, height() ), lv->tqcolorGroup(),
+ lv->tqstyle().drawComplexControl( TQStyle::CC_ListView,
+ p, lv, TQRect( 0, 0, width, height() ), lv->colorGroup(),
how, TQStyle::SC_ListView, TQStyle::SC_None,
opt );
}
@@ -143,7 +143,7 @@ void ChannelListItem::paintCell( TQPainter *p, const TQColorGroup &cg, int colum
textheight++;
if ( textheight < height() ) {
int w = lv->treeStepSize() / 2;
- lv->tqstyle().tqdrawComplexControl( TQStyle::CC_ListView, p, lv,
+ lv->tqstyle().drawComplexControl( TQStyle::CC_ListView, p, lv,
TQRect( 0, textheight, w + 1, height() - textheight + 1 ), _cg,
lv->isEnabled() ? TQStyle::Style_Enabled : TQStyle::Style_Default,
TQStyle::SC_ListViewExpand,
@@ -170,21 +170,21 @@ ChannelList::ChannelList( TQWidget* parent, KIRC::Engine *engine )
{
ChannelListLayout = new TQVBoxLayout( this, 11, 6, "ChannelListLayout");
- tqlayout72_2 = new TQHBoxLayout( 0, 0, 6, "tqlayout72_2");
+ layout72_2 = new TQHBoxLayout( 0, 0, 6, "layout72_2");
textLabel1_2 = new TQLabel( this, "textLabel1_2" );
- tqlayout72_2->addWidget( textLabel1_2 );
+ layout72_2->addWidget( textLabel1_2 );
channelSearch = new TQLineEdit( this, "channelSearch" );
- tqlayout72_2->addWidget( channelSearch );
+ layout72_2->addWidget( channelSearch );
numUsers = new TQSpinBox( 0, 32767, 1, this, "num_users" );
numUsers->setSuffix( i18n(" members") );
- tqlayout72_2->addWidget( numUsers );
+ layout72_2->addWidget( numUsers );
mSearchButton = new TQPushButton( this, "mSearchButton" );
- tqlayout72_2->addWidget( mSearchButton );
- ChannelListLayout->addLayout( tqlayout72_2 );
+ layout72_2->addWidget( mSearchButton );
+ ChannelListLayout->addLayout( layout72_2 );
mChannelList = new KListView( this, "mChannelList" );
mChannelList->addColumn( i18n( "Channel" ) );
@@ -226,8 +226,8 @@ ChannelList::ChannelList( TQWidget* parent, KIRC::Engine *engine )
connect( m_engine, TQT_SIGNAL( incomingEndOfList() ), this, TQT_SLOT( slotListEnd() ) );
- connect( m_engine, TQT_SIGNAL( statusChanged(KIRC::Engine::tqStatus) ),
- this, TQT_SLOT( slotStatusChanged(KIRC::Engine::tqStatus) ) );
+ connect( m_engine, TQT_SIGNAL( statusChanged(KIRC::Engine::Status) ),
+ this, TQT_SLOT( slotStatusChanged(KIRC::Engine::Status) ) );
show();
}
@@ -242,9 +242,9 @@ void ChannelList::slotItemSelected( TQListViewItem *i )
emit channelSelected( i->text(0) );
}
-void ChannelList::slotStatusChanged(KIRC::Engine::tqStatus newtqStatus)
+void ChannelList::slotStatusChanged(KIRC::Engine::Status newStatus)
{
- switch(newtqStatus) {
+ switch(newStatus) {
case KIRC::Engine::Connected:
this->reset();
break;
diff --git a/kopete/protocols/irc/ui/channellist.h b/kopete/protocols/irc/ui/channellist.h
index a5963b6b..1a528bb9 100644
--- a/kopete/protocols/irc/ui/channellist.h
+++ b/kopete/protocols/irc/ui/channellist.h
@@ -58,7 +58,7 @@ class ChannelList
void slotChannelListed( const TQString & channel, uint users, const TQString & topic );
void slotListEnd();
void slotSearchCache();
- void slotStatusChanged( KIRC::Engine::tqStatus );
+ void slotStatusChanged( KIRC::Engine::Status );
private:
void checkSearchResult( const TQString & channel, uint users, const TQString & topic );
@@ -69,7 +69,7 @@ class ChannelList
TQPushButton* mSearchButton;
KListView* mChannelList;
TQVBoxLayout* ChannelListLayout;
- TQHBoxLayout* tqlayout72_2;
+ TQHBoxLayout* layout72_2;
KIRC::Engine *m_engine;
bool mSearching;
TQString mSearch;
diff --git a/kopete/protocols/irc/ui/channellistdialog.cpp b/kopete/protocols/irc/ui/channellistdialog.cpp
index e344d227..f68f3d10 100644
--- a/kopete/protocols/irc/ui/channellistdialog.cpp
+++ b/kopete/protocols/irc/ui/channellistdialog.cpp
@@ -22,7 +22,7 @@
#include "kopeteuiglobal.h"
-#include "tqlayout.h"
+#include "layout.h"
ChannelListDialog::ChannelListDialog(KIRC::Engine *engine, const TQString &caption, TQObject *target, const char* slotJoinChan)
: KDialogBase(Kopete::UI::Global::mainWidget(), "channel_list_widget", false, caption, Close)
diff --git a/kopete/protocols/irc/ui/ircadd.ui b/kopete/protocols/irc/ui/ircadd.ui
index c899eca8..a85681cd 100644
--- a/kopete/protocols/irc/ui/ircadd.ui
+++ b/kopete/protocols/irc/ui/ircadd.ui
@@ -45,7 +45,7 @@
</property>
<widget class="TQLayoutWidget">
<property name="name">
- <cstring>tqlayout70</cstring>
+ <cstring>layout70</cstring>
</property>
<hbox>
<property name="name">
@@ -88,7 +88,7 @@
<property name="text">
<string>&lt;i&gt;(for example: joe_bob or #somechannel)&lt;/i&gt;</string>
</property>
- <property name="tqalignment">
+ <property name="alignment">
<set>AlignVCenter|AlignRight</set>
</property>
</widget>
@@ -102,7 +102,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="tqsizeHint">
+ <property name="sizeHint">
<size>
<width>20</width>
<height>110</height>
diff --git a/kopete/protocols/irc/ui/irceditaccount.ui b/kopete/protocols/irc/ui/irceditaccount.ui
index e2e33f69..c184b92e 100644
--- a/kopete/protocols/irc/ui/irceditaccount.ui
+++ b/kopete/protocols/irc/ui/irceditaccount.ui
@@ -63,7 +63,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="tqsizeHint">
+ <property name="sizeHint">
<size>
<width>20</width>
<height>150</height>
@@ -82,7 +82,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="tqmaximumSize">
+ <property name="maximumSize">
<size>
<width>32767</width>
<height>32767</height>
@@ -91,7 +91,7 @@
<property name="text">
<string>&lt;p&gt;&lt;b&gt;Note:&lt;/b&gt; Most IRC servers do not require a password, and only a nickname is required to connect&lt;/p&gt;</string>
</property>
- <property name="tqalignment">
+ <property name="alignment">
<set>WordBreak|AlignTop</set>
</property>
</widget>
@@ -261,7 +261,7 @@
</property>
<widget class="TQLayoutWidget">
<property name="name">
- <cstring>tqlayout21</cstring>
+ <cstring>layout21</cstring>
</property>
<grid>
<property name="name">
@@ -269,7 +269,7 @@
</property>
<widget class="TQLayoutWidget" row="1" column="1">
<property name="name">
- <cstring>tqlayout19</cstring>
+ <cstring>layout19</cstring>
</property>
<hbox>
<property name="name">
@@ -293,7 +293,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="tqsizeHint">
+ <property name="sizeHint">
<size>
<width>161</width>
<height>20</height>
@@ -304,7 +304,7 @@
</widget>
<widget class="TQLayoutWidget" row="0" column="1">
<property name="name">
- <cstring>tqlayout20</cstring>
+ <cstring>layout20</cstring>
</property>
<hbox>
<property name="name">
@@ -333,7 +333,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="tqsizeHint">
+ <property name="sizeHint">
<size>
<width>392</width>
<height>20</height>
@@ -395,7 +395,7 @@
</widget>
<widget class="TQLayoutWidget">
<property name="name">
- <cstring>tqlayout25</cstring>
+ <cstring>layout25</cstring>
</property>
<hbox>
<property name="name">
@@ -427,7 +427,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="tqsizeHint">
+ <property name="sizeHint">
<size>
<width>141</width>
<height>20</height>
@@ -505,7 +505,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="tqsizeHint">
+ <property name="sizeHint">
<size>
<width>20</width>
<height>150</height>
@@ -554,7 +554,7 @@
</widget>
<widget class="TQLayoutWidget" row="0" column="0">
<property name="name">
- <cstring>tqlayout19</cstring>
+ <cstring>layout19</cstring>
</property>
<grid>
<property name="name">
@@ -646,7 +646,7 @@
</widget>
<widget class="TQLayoutWidget" row="0" column="1">
<property name="name">
- <cstring>tqlayout23</cstring>
+ <cstring>layout23</cstring>
</property>
<grid>
<property name="name">
@@ -744,7 +744,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="tqminimumSize">
+ <property name="minimumSize">
<size>
<width>0</width>
<height>130</height>
@@ -809,7 +809,7 @@
</widget>
<widget class="TQLayoutWidget">
<property name="name">
- <cstring>tqlayout153</cstring>
+ <cstring>layout153</cstring>
</property>
<hbox>
<property name="name">
@@ -871,7 +871,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="tqminimumSize">
+ <property name="minimumSize">
<size>
<width>0</width>
<height>130</height>
@@ -886,7 +886,7 @@
</property>
<widget class="TQLayoutWidget" row="1" column="0">
<property name="name">
- <cstring>tqlayout29</cstring>
+ <cstring>layout29</cstring>
</property>
<hbox>
<property name="name">
diff --git a/kopete/protocols/irc/ui/irceditaccountwidget.cpp b/kopete/protocols/irc/ui/irceditaccountwidget.cpp
index 8a7cdcfb..c0d5a87a 100644
--- a/kopete/protocols/irc/ui/irceditaccountwidget.cpp
+++ b/kopete/protocols/irc/ui/irceditaccountwidget.cpp
@@ -91,9 +91,9 @@ IRCEditAccountWidget::IRCEditAccountWidget(IRCProtocol *proto, IRCAccount *ident
new TQListViewItem( ctcpList, it.key(), it.data() );
}
- mUserName->setValidator( new TQRegExpValidator( TQString::tqfromLatin1("^[^\\s]*$"), TQT_TQOBJECT(mUserName) ) );
- mNickName->setValidator( new TQRegExpValidator( TQString::tqfromLatin1("^[^#+&][^\\s]*$"), TQT_TQOBJECT(mNickName) ) );
- mAltNickname->setValidator( new TQRegExpValidator( TQString::tqfromLatin1("^[^#+&][^\\s]*$"), TQT_TQOBJECT(mAltNickname) ) );
+ mUserName->setValidator( new TQRegExpValidator( TQString::fromLatin1("^[^\\s]*$"), TQT_TQOBJECT(mUserName) ) );
+ mNickName->setValidator( new TQRegExpValidator( TQString::fromLatin1("^[^#+&][^\\s]*$"), TQT_TQOBJECT(mNickName) ) );
+ mAltNickname->setValidator( new TQRegExpValidator( TQString::fromLatin1("^[^#+&][^\\s]*$"), TQT_TQOBJECT(mAltNickname) ) );
charset->insertStringList( KCodecAction::supportedEncodings() );
@@ -212,9 +212,9 @@ TQString IRCEditAccountWidget::generateAccountId( const TQString &network )
TQString nextId = network;
uint accountNumber = 1;
- while( config->hasGroup( TQString("Account_%1_%2").tqarg( m_protocol->pluginId() ).tqarg( nextId ) ) )
+ while( config->hasGroup( TQString("Account_%1_%2").arg( m_protocol->pluginId() ).arg( nextId ) ) )
{
- nextId = TQString::tqfromLatin1("%1_%2").tqarg( network ).tqarg( ++accountNumber );
+ nextId = TQString::fromLatin1("%1_%2").arg( network ).arg( ++accountNumber );
}
kdDebug( 14120 ) << k_funcinfo << " ID IS: " << nextId << endl;
return nextId;
diff --git a/kopete/protocols/irc/ui/networkconfig.ui b/kopete/protocols/irc/ui/networkconfig.ui
index 0f15dee5..09121e54 100644
--- a/kopete/protocols/irc/ui/networkconfig.ui
+++ b/kopete/protocols/irc/ui/networkconfig.ui
@@ -206,7 +206,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="tqsizeHint">
+ <property name="sizeHint">
<size>
<width>210</width>
<height>20</height>
@@ -240,7 +240,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="tqsizeHint">
+ <property name="sizeHint">
<size>
<width>20</width>
<height>151</height>
@@ -313,7 +313,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="tqsizeHint">
+ <property name="sizeHint">
<size>
<width>260</width>
<height>20</height>