summaryrefslogtreecommitdiffstats
path: root/ksirc/ksopts.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-22 00:30:31 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-22 00:30:31 +0000
commit69cac65817d949cda2672ec4f0aa73d5e66a0ba1 (patch)
tree073fde0496ea90eb5bf5cffe66a8da43a9f55fbc /ksirc/ksopts.cpp
parent3467e6464beac3a162839bf7078e22e3a74d73e7 (diff)
downloadtdenetwork-69cac65817d949cda2672ec4f0aa73d5e66a0ba1.tar.gz
tdenetwork-69cac65817d949cda2672ec4f0aa73d5e66a0ba1.zip
TQt4 port kdenetwork
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdenetwork@1237912 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'ksirc/ksopts.cpp')
-rw-r--r--ksirc/ksopts.cpp70
1 files changed, 35 insertions, 35 deletions
diff --git a/ksirc/ksopts.cpp b/ksirc/ksopts.cpp
index b1df2f40..38bf27fa 100644
--- a/ksirc/ksopts.cpp
+++ b/ksirc/ksopts.cpp
@@ -73,11 +73,11 @@ KSOServer::KSOServer()
KSOColors::KSOColors()
{
- textColor = Qt::black;
- linkColor = Qt::blue;
- infoColor = Qt::blue;
- channelColor = Qt::green;
- errorColor = Qt::red;
+ textColor = TQt::black;
+ linkColor = TQt::blue;
+ infoColor = TQt::blue;
+ channelColor = TQt::green;
+ errorColor = TQt::red;
ksircColors = true;
mircColors = false;
@@ -93,22 +93,22 @@ KSOColors::KSOColors()
selBackgroundColor = kapp->palette().color( TQPalette::Active, TQColorGroup::Highlight );
selForegroundColor = kapp->palette().color( TQPalette::Active, TQColorGroup::HighlightedText );
- ircColors[0] = Qt::white;
- ircColors[1] = Qt::black;
- ircColors[2] = Qt::darkBlue;
- ircColors[3] = Qt::darkGreen;
- ircColors[4] = Qt::red;
+ ircColors[0] = TQt::white;
+ ircColors[1] = TQt::black;
+ ircColors[2] = TQt::darkBlue;
+ ircColors[3] = TQt::darkGreen;
+ ircColors[4] = TQt::red;
ircColors[5] = TQColor ( 165, 42, 42 );
- ircColors[6] = Qt::darkMagenta;
+ ircColors[6] = TQt::darkMagenta;
ircColors[7] = TQColor( 255, 0x7b, 00 );
- ircColors[8] = Qt::yellow;
- ircColors[9] = Qt::green;
- ircColors[10] = Qt::darkCyan;
- ircColors[11] = Qt::cyan;
- ircColors[12] = Qt::blue;
+ ircColors[8] = TQt::yellow;
+ ircColors[9] = TQt::green;
+ ircColors[10] = TQt::darkCyan;
+ ircColors[11] = TQt::cyan;
+ ircColors[12] = TQt::blue;
ircColors[13] = TQColor( 255, 0, 255 );
- ircColors[14] = Qt::gray;
- ircColors[15] = Qt::lightGray;
+ ircColors[14] = TQt::gray;
+ ircColors[15] = TQt::lightGray;
uint i;
for(i = 0; i < numColors; i++){
@@ -142,7 +142,7 @@ void KSOptions::load( int sections )
{
KConfig *conf = kapp->config();
conf->setGroup( "ServerController" );
- geometry = conf->readRectEntry( "Size" );
+ tqgeometry = conf->readRectEntry( "Size" );
// Using the fields itself as default values as they are already
// set to the defaults.
@@ -232,17 +232,17 @@ void KSOptions::load( int sections )
colourTheme = conf->readEntry("ColourTheme", colourTheme );
for ( int i = 0; i < 16; ++i ) {
ircColors[i] =
- conf->readColorEntry(TQString::fromLatin1( "IRC-%1" ).arg( i ),
+ conf->readColorEntry(TQString::tqfromLatin1( "IRC-%1" ).tqarg( i ),
&ircColors[i] );
nickHighlight[i] =
- conf->readBoolEntry(TQString::fromLatin1( "nickHighlight-%1" ).arg( i ),
+ conf->readBoolEntry(TQString::tqfromLatin1( "nickHighlight-%1" ).tqarg( i ),
&nickHighlight[i] );
}
}
conf->setGroup( "GlobalOptions" );
- TQFont df = kapp->font(0);
+ TQFont df = kapp->font((TQWidget*)0);
defaultFont = conf->readFontEntry( "MainFont", &df);
- TQApplication::setFont( defaultFont, true, "KSirc::TextView" );
+ TQApplication::tqsetFont( defaultFont, true, "KSirc::TextView" );
}
if ( sections & Channels )
{
@@ -251,7 +251,7 @@ void KSOptions::load( int sections )
/*
* do global first
*/
- if(channel.contains("global") == FALSE){
+ if(channel.tqcontains("global") == FALSE){
KSOChannel global;
ChannelOpMap coMap;
channel.insert(TQString("global"), coMap);
@@ -268,7 +268,7 @@ void KSOptions::load( int sections )
channel["global"]["global"].encoding = conf->readEntry("globalglobalEncoding", "Default");
}
- TQDateTime now(TQDateTime::currentDateTime());
+ TQDateTime now(TQDateTime::tqcurrentDateTime());
TQStringList servers = conf->readListEntry("Servers");
TQStringList::ConstIterator ser = servers.begin();
for( ; ser != servers.end(); ser++){
@@ -315,7 +315,7 @@ void KSOptions::load( int sections )
/*
* do global first
*/
- if(server.contains("global") == FALSE){
+ if(server.tqcontains("global") == FALSE){
KSOServer global;
server.insert(TQString("global"), global);
server["global"].server = "global";
@@ -422,8 +422,8 @@ void KSOptions::save( int sections )
conf->writeEntry( "nickColourization", nickColourization );
conf->writeEntry( "ColourTheme", colourTheme );
for ( int i = 0; i < 16; ++i ) {
- conf->writeEntry( TQString::fromLatin1( "IRC-%1" ).arg( i ), ircColors[i] );
- conf->writeEntry( TQString::fromLatin1( "nickHighlight-%1" ).arg( i ), nickHighlight[i] );
+ conf->writeEntry( TQString::tqfromLatin1( "IRC-%1" ).tqarg( i ), ircColors[i] );
+ conf->writeEntry( TQString::tqfromLatin1( "nickHighlight-%1" ).tqarg( i ), nickHighlight[i] );
}
/* Store the font setting */
conf->setGroup( "GlobalOptions" );
@@ -490,20 +490,20 @@ void KSOptions::save( int sections )
void KSOptions::channelSetup(TQString serv, TQString chan)
{
- if(channel.contains(serv) == FALSE){
+ if(channel.tqcontains(serv) == FALSE){
ChannelOpMap coMap;
channel.insert(serv, coMap);
}
- if(channel[serv].contains(chan) == FALSE){
+ if(channel[serv].tqcontains(chan) == FALSE){
KSOChannel ksoc;
ksoc = channel["global"]["global"];
channel[serv].insert(chan, ksoc);
channel[serv][chan].server = serv;
channel[serv][chan].channel = chan;
- channel[serv][chan].lastUsed = TQDateTime::currentDateTime();
+ channel[serv][chan].lastUsed = TQDateTime::tqcurrentDateTime();
}
else {
- channel[serv][chan].lastUsed = TQDateTime::currentDateTime();
+ channel[serv][chan].lastUsed = TQDateTime::tqcurrentDateTime();
}
}
@@ -524,16 +524,16 @@ void KSOptions::applyChannelGlobal(void)
void KSOptions::serverSetup(TQString serv)
{
- if(server.contains(serv) == FALSE){
+ if(server.tqcontains(serv) == FALSE){
KSOServer ksos;
ksos = server["global"];
server.insert(serv, ksos);
server[serv].server = serv;
server[serv].globalCopy = true;
- server[serv].lastUsed = TQDateTime::currentDateTime();
+ server[serv].lastUsed = TQDateTime::tqcurrentDateTime();
}
else {
- server[serv].lastUsed = TQDateTime::currentDateTime();
+ server[serv].lastUsed = TQDateTime::tqcurrentDateTime();
}
}