summaryrefslogtreecommitdiffstats
path: root/ksirc/toplevel.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'ksirc/toplevel.cpp')
-rw-r--r--ksirc/toplevel.cpp76
1 files changed, 38 insertions, 38 deletions
diff --git a/ksirc/toplevel.cpp b/ksirc/toplevel.cpp
index f68a9cc5..fa53cded 100644
--- a/ksirc/toplevel.cpp
+++ b/ksirc/toplevel.cpp
@@ -50,12 +50,12 @@
#include <stdlib.h>
#include <tqaccel.h>
-#include <clipboard.h>
+#include <tqclipboard.h>
#include <tqregexp.h>
#include <tqcursor.h>
#include <tqtimer.h>
-#include <layout.h>
-#include <textcodec.h>
+#include <tqlayout.h>
+#include <tqtextcodec.h>
#include <tqvbox.h>
#include <tqlabel.h>
@@ -85,7 +85,7 @@ TQStringList KSircTopLevel::cmd_menu;
void
KSircTopLevel::initColors()
{
- TQColorGroup cg_mainw = kapp->palette().active();
+ TQColorGroup cg_mainw = kapp->tqpalette().active();
cg_mainw.setColor(TQColorGroup::Base, ksopts->backgroundColor);
cg_mainw.setColor(TQColorGroup::Text, ksopts->textColor);
cg_mainw.setColor(TQColorGroup::Link, ksopts->linkColor);
@@ -216,7 +216,7 @@ KSircTopLevel::KSircTopLevel(KSircProcess *_proc, const KSircChannel &channelInf
kmenu->setAccel(Key_F, KST_CHANNEL_ID);
/*
- * Ok, let's look at the basic widget "layout"
+ * Ok, let's look at the basic widget "tqlayout"
* Everything belongs to q TQFrame F, this is use so we
* can give the KApplication a single main client widget, which is needs.
*
@@ -258,7 +258,7 @@ KSircTopLevel::KSircTopLevel(KSircProcess *_proc, const KSircChannel &channelInf
lag = new TQLabel(nicks_box);
lag->setFrameStyle(TQFrame::Panel|TQFrame::Sunken);
- lag->setAlignment(TQt::AlignCenter | TQt::SingleLine);
+ lag->tqsetAlignment(TQt::AlignCenter | TQt::SingleLine);
lag->setText(i18n("Lag: Wait"));
@@ -587,9 +587,9 @@ void KSircTopLevel::setMode(TQString mode, int mode_type, TQString currentNick)
{
TQString command;
if (mode_type == 0)
- command = TQString::fromLatin1("/mode %1 %2\n").arg(m_channelInfo.channel()).arg(mode);
+ command = TQString::tqfromLatin1("/mode %1 %2\n").tqarg(m_channelInfo.channel()).tqarg(mode);
else
- command = TQString::fromLatin1("/mode %1 %2\n").arg(currentNick).arg(mode);
+ command = TQString::tqfromLatin1("/mode %1 %2\n").tqarg(currentNick).tqarg(mode);
sirc_write(command);
linee->setFocus();
}
@@ -829,7 +829,7 @@ void KSircTopLevel::sirc_receive(TQString str, bool broadcast)
// that we enter a local event loop (think of the ssfeprompt dialog!)
// which might trigger a socketnotifier activation which in turn
// might result in the execution of code that modifies the LineBuffer,
- // which would invalidate iterators (Simon)
+ // which would tqinvalidate iterators (Simon)
while ( LineBuffer.begin() != LineBuffer.end() )
{
TQString plainText("");
@@ -877,7 +877,7 @@ void KSircTopLevel::sirc_receive(TQString str, bool broadcast)
list = pan->sizes();
it = list.begin();
while( it != list.end()){
- values += TQString("%1 ").arg(*it);
+ values += TQString("%1 ").tqarg(*it);
++it;
}
}
@@ -974,7 +974,7 @@ void KSircTopLevel::sirc_write(const TQString &str)
return;
}
else if ( plain.startsWith( "/away" ) ) {
- TQString awayEvalCommand = TQString::fromLatin1( "/eval $publicAway = %1\n" ).arg( ksopts->publicAway ? '1' : '0' );
+ TQString awayEvalCommand = TQString::tqfromLatin1( "/eval $publicAway = %1\n" ).tqarg( ksopts->publicAway ? '1' : '0' );
emit outputUnicodeLine( awayEvalCommand );
}
@@ -985,7 +985,7 @@ void KSircTopLevel::sirc_write(const TQString &str)
if(!isSpecialWindow()) { // channel or private chat
if(plain[0].latin1() != '/'){
- command.prepend(TQString::fromLatin1("/msg %1 ").arg(m_channelInfo.channel()));
+ command.prepend(TQString::tqfromLatin1("/msg %1 ").tqarg(m_channelInfo.channel()));
}
else if(plain.startsWith("/me ")) {
command.remove(0, 3);
@@ -1104,7 +1104,7 @@ void KSircTopLevel::returnPressed()
uint i;
TQChar c;
for(i = 0; (c = s[i]); i++){
- switch(c.unicode()){
+ switch(c.tqunicode()){
case 0336:
s[i] = 002;
break;
@@ -1147,15 +1147,15 @@ void KSircTopLevel::UserParseMenu(int id)
return;
TQString s;
- s = TQString("/eval $dest_nick='%1';\n").arg(nicks->text(nicks->currentItem()));
+ s = TQString("/eval $dest_nick='%1';\n").tqarg(nicks->text(nicks->currentItem()));
sirc_write(s);
// set $$dest_chan variable
- s = TQString("/eval $dest_chan='%1';\n").arg(m_channelInfo.channel());
+ s = TQString("/eval $dest_chan='%1';\n").tqarg(m_channelInfo.channel());
sirc_write(s);
TQString action = user_menu->at(id)->action;
if (action.length() && action[0] == '/')
action.remove(0, 1);
- s = TQString("/eval &docommand(eval{\"%1\"});\n").arg(action);
+ s = TQString("/eval &docommand(eval{\"%1\"});\n").tqarg(action);
s.replace(TQRegExp("\\$\\$"), "$");
sirc_write(s);
}
@@ -1233,7 +1233,7 @@ void KSircTopLevel::gotFocus()
if(isVisible() == TRUE){
if(have_focus == 0){
if(m_channelInfo.channel()[0] != '!' ){
- TQString str = TQString("/join %1").arg(m_channelInfo.channel());
+ TQString str = TQString("/join %1").tqarg(m_channelInfo.channel());
if(m_channelInfo.key().length() > 0){
str.append(" " + m_channelInfo.key());
}
@@ -1247,7 +1247,7 @@ void KSircTopLevel::gotFocus()
}
if(m_gotMsgWithoutFocus == true){
m_gotMsgWithoutFocus = false;
- servercontroller::self()->decreaseNotificationCount(TQString("%1 -> %2 got message").arg(ksircProcess()->serverID()).arg(m_channelInfo.channel()));
+ servercontroller::self()->decreaseNotificationCount(TQString("%1 -> %2 got message").tqarg(ksircProcess()->serverID()).tqarg(m_channelInfo.channel()));
}
}
@@ -1293,14 +1293,14 @@ void KSircTopLevel::control_message(int command, TQString str)
emit currentWindow(this);
if(m_channelInfo.channel()[0] == '#' || m_channelInfo.channel()[0] == '&'){
- TQString str = TQString("/join %1 %2\n").arg(m_channelInfo.channel()).arg(m_channelInfo.key());
+ TQString str = TQString("/join %1 %2\n").tqarg(m_channelInfo.channel()).tqarg(m_channelInfo.key());
kdDebug(5008) << "Doing /join " << m_channelInfo.channel() << " :" << str << endl;
emit outputUnicodeLine(str);
emit outputLine("/eval $query=''\n");
}
else if (m_channelInfo.channel()[0] != '!')
{
- emit outputUnicodeLine(TQString("/eval $query='%1'\n").arg(m_channelInfo.channel()));
+ emit outputUnicodeLine(TQString("/eval $query='%1'\n").tqarg(m_channelInfo.channel()));
}
bool isPrivate = isPrivateChat();
@@ -1327,13 +1327,13 @@ void KSircTopLevel::control_message(int command, TQString str)
// nicks->show();
// lag->show();
}
- if(layout()) {
- //kdDebug(5008) << "Redoeing layout" << endl;
- layout()->invalidate();
- layout()->activate();
+ if(tqlayout()) {
+ //kdDebug(5008) << "Redoeing tqlayout" << endl;
+ tqlayout()->tqinvalidate();
+ tqlayout()->activate();
}
else {
- //kdDebug(5008) << "No layout" << endl;
+ //kdDebug(5008) << "No tqlayout" << endl;
}
pan->refresh();
@@ -1497,8 +1497,8 @@ void KSircTopLevel::openQueryFromNick(const TQString &nick)
void KSircTopLevel::pasteToWindow()
{
// Ctrl-V
- //kdDebug(5008) << "Going to paste: " << KApplication::clipboard()->text( TQClipboard::Clipboard ) << endl;
- slotTextDropped(KApplication::clipboard()->text( TQClipboard::Clipboard ) );
+ //kdDebug(5008) << "Going to paste: " << KApplication::tqclipboard()->text( TQClipboard::Clipboard ) << endl;
+ slotTextDropped(KApplication::tqclipboard()->text( TQClipboard::Clipboard ) );
}
void KSircTopLevel::pasteToNickList(int button,
@@ -1510,7 +1510,7 @@ void KSircTopLevel::pasteToNickList(int button,
emit open_toplevel(ci);
TQStringList lines = TQStringList::split( '\n',
- KApplication::clipboard()->text( TQClipboard::Selection ),
+ KApplication::tqclipboard()->text( TQClipboard::Selection ),
true );
TQStringList::ConstIterator it = lines.begin();
TQStringList::ConstIterator end = lines.end();
@@ -1574,7 +1574,7 @@ void KSircTopLevel::slotTextDropped( const TQString& _text )
approx_lines = lines;
if (lines > 4) {
int result = KMessageBox::warningContinueCancel(this,
- i18n("You are about to send %1 lines of text.\nDo you really want to send that much?").arg(approx_lines),
+ i18n("You are about to send %1 lines of text.\nDo you really want to send that much?").tqarg(approx_lines),
TQString(), i18n("Send"));
if (result != KMessageBox::Continue)
{
@@ -1700,7 +1700,7 @@ void KSircTopLevel::slotDccURLs( const TQStringList& urls, const TQString& nick
TQString file( *it );
kdDebug(5008) << "........ " << file << endl;
if ( !file.isEmpty() )
- sirc_write(s.arg( file ));
+ sirc_write(s.tqarg( file ));
}
}
@@ -1727,7 +1727,7 @@ void KSircTopLevel::outputUnicodeLine( const TQString &message )
void KSircTopLevel::setTopicIntern( const TQString &topic )
{
- TQString command = TQString::fromLatin1( "/topic %1 %2\n" ).arg( m_channelInfo.channel() ).arg( topic );
+ TQString command = TQString::tqfromLatin1( "/topic %1 %2\n" ).tqarg( m_channelInfo.channel() ).tqarg( topic );
sirc_write( command );
linee->setFocus();
}
@@ -1739,15 +1739,15 @@ void KSircTopLevel::doChange(bool pers, TQString text)
// beep only every 2 seconds otherwise it'll get very noisy in the room ;)
if ( TQABS( lastBeep.secsTo( ctime ) ) > 1 ) {
if ( pers ) {
- int winId = !ticker ? topLevelWidget()->winId() : ticker->winId();
+ int winId = !ticker ? tqtopLevelWidget()->winId() : ticker->winId();
KNotifyClient::event(winId,
- TQString::fromLatin1("ChannelPersonal"),
- i18n("Your nick appeared on channel %1").arg(m_channelInfo.channel()));
+ TQString::tqfromLatin1("ChannelPersonal"),
+ i18n("Your nick appeared on channel %1").tqarg(m_channelInfo.channel()));
} else {
- int winId = !ticker ? topLevelWidget()->winId() : ticker->winId();
+ int winId = !ticker ? tqtopLevelWidget()->winId() : ticker->winId();
KNotifyClient::event(winId,
- TQString::fromLatin1("ChannelChanged"),
- i18n("Channel %1 changed").arg(m_channelInfo.channel()));
+ TQString::tqfromLatin1("ChannelChanged"),
+ i18n("Channel %1 changed").tqarg(m_channelInfo.channel()));
}
lastBeep = ctime;
}
@@ -1755,7 +1755,7 @@ void KSircTopLevel::doChange(bool pers, TQString text)
if(have_focus == 0 && pers == true && m_gotMsgWithoutFocus == false){
m_gotMsgWithoutFocus = true;
- servercontroller::self()->increaseNotificationCount(TQString("%1 -> %2").arg(ksircProcess()->serverID()).arg(m_channelInfo.channel()), text);
+ servercontroller::self()->increaseNotificationCount(TQString("%1 -> %2").tqarg(ksircProcess()->serverID()).tqarg(m_channelInfo.channel()), text);
}
}