summaryrefslogtreecommitdiffstats
path: root/kopete/libkopete/kopeteaway.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kopete/libkopete/kopeteaway.cpp')
-rw-r--r--kopete/libkopete/kopeteaway.cpp48
1 files changed, 24 insertions, 24 deletions
diff --git a/kopete/libkopete/kopeteaway.cpp b/kopete/libkopete/kopeteaway.cpp
index 1c920f31..04ac9a03 100644
--- a/kopete/libkopete/kopeteaway.cpp
+++ b/kopete/libkopete/kopeteaway.cpp
@@ -39,7 +39,7 @@
#include <kdebug.h>
#include <ksettings/dispatcher.h>
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#include <X11/Xlib.h>
#include <X11/Xatom.h>
#include <X11/Xresource.h>
@@ -50,7 +50,7 @@
#define HasScreenSaver
#include <X11/extensions/scrnsaver.h>
#endif
-#endif // Q_WS_X11
+#endif // TQ_WS_X11
// As this is an untested X extension we better leave it off
#undef HAVE_XIDLE
@@ -74,8 +74,8 @@ struct KopeteAwayPrivate
int mouse_x;
int mouse_y;
- unsigned int mouse_mask;
-#ifdef Q_WS_X11
+ unsigned int mouse_tqmask;
+#ifdef TQ_WS_X11
Window root; /* root window the pointer is on */
Screen* screen; /* screen the pointer is on */
@@ -95,8 +95,8 @@ Kopete::Away::Away() : TQObject( kapp , "Kopete::Away")
d = new KopeteAwayPrivate;
// Set up the away messages
- d->awayMessage = TQString::null;
- d->autoAwayMessage = TQString::null;
+ d->awayMessage = TQString();
+ d->autoAwayMessage = TQString();
d->useAutoAwayMessage = false;
d->globalAway = false;
d->autoaway = false;
@@ -106,12 +106,12 @@ Kopete::Away::Away() : TQObject( kapp , "Kopete::Away")
d->awayMessageList.clear();
// set the XAutoLock info
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
Display *dsp = qt_xdisplay();
#endif
d->mouse_x = d->mouse_y=0;
- d->mouse_mask = 0;
-#ifdef Q_WS_X11
+ d->mouse_tqmask = 0;
+#ifdef TQ_WS_X11
d->root = DefaultRootWindow (dsp);
d->screen = ScreenOfDisplay (dsp, DefaultScreen (dsp));
#endif
@@ -124,12 +124,12 @@ Kopete::Away::Away() : TQObject( kapp , "Kopete::Away")
if(!d->useXidle)
d->useMit = XScreenSaverQueryExtension(qt_xdisplay(), &dummy, &dummy);
#endif
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
d->xIdleTime = 0;
#endif
kdDebug(14010) << k_funcinfo << "Idle detection methods:" << endl;
kdDebug(14010) << k_funcinfo << "\tKScreensaverIface::isBlanked()" << endl;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdDebug(14010) << k_funcinfo << "\tX11 XQueryPointer()" << endl;
#endif
if (d->useXidle)
@@ -293,7 +293,7 @@ TQString Kopete::Away::getMessage( uint messageNumber )
}
else
{
- return TQString::null;
+ return TQString();
}
}
@@ -368,11 +368,11 @@ bool Kopete::Away::isActivity()
bool activity = false;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
Display *dsp = qt_xdisplay();
Window dummy_w;
int dummy_c;
- unsigned int mask; /* modifier mask */
+ unsigned int tqmask; /* modifier tqmask */
int root_x;
int root_y;
@@ -388,7 +388,7 @@ bool Kopete::Away::isActivity()
* we now call that periodically anyway?
*/
if (!XQueryPointer (dsp, d->root, &(d->root), &dummy_w, &root_x, &root_y,
- &dummy_c, &dummy_c, &mask))
+ &dummy_c, &dummy_c, &tqmask))
{
/*
* Pointer has moved to another screen, so let's find out which one.
@@ -432,10 +432,10 @@ bool Kopete::Away::isActivity()
// Only check idle time if we have some way of measuring it, otherwise if
// we've neither Mit nor Xidle it'll still be zero and we'll always appear active.
// FIXME: what problem does the 2000ms fudge solve?
- if (root_x != d->mouse_x || root_y != d->mouse_y || mask != d->mouse_mask
+ if (root_x != d->mouse_x || root_y != d->mouse_y || tqmask != d->mouse_tqmask
|| ((d->useXidle || d->useMit) && xIdleTime < d->xIdleTime + 2000))
{
- // -1 => just gone autoaway, ignore apparent activity this time round
+ // -1 => just gone autoaway, ignore aptqparent activity this time round
// anything else => genuine activity
// See setAutoAway().
if (d->mouse_x != -1)
@@ -444,10 +444,10 @@ bool Kopete::Away::isActivity()
}
d->mouse_x = root_x;
d->mouse_y = root_y;
- d->mouse_mask = mask;
+ d->mouse_tqmask = tqmask;
d->xIdleTime = xIdleTime;
}
-#endif // Q_WS_X11
+#endif // TQ_WS_X11
// =================================================================================
return activity;
@@ -469,7 +469,7 @@ void Kopete::Away::setActive()
{
if(i->isConnected() && i->isAway())
{
- i->setOnlineStatus( Kopete::OnlineStatusManager::self()->onlineStatus( i->protocol() ,
+ i->setOnlineStatus( Kopete::OnlineStatusManager::self()->onlinetqStatus( i->protocol() ,
Kopete::OnlineStatusManager::Online ) );
}
@@ -484,7 +484,7 @@ void Kopete::Away::setActive()
void Kopete::Away::setAutoAway()
{
// A value of -1 in mouse_x indicates to checkActivity() that next time it
- // fires it should ignore any apparent idle/mouse/keyboard changes.
+ // fires it should ignore any aptqparent idle/mouse/keyboard changes.
// I think the point of this is that if you manually start the screensaver
// then there'll unavoidably be some residual mouse/keyboard activity
// that should be ignored.
@@ -499,21 +499,21 @@ void Kopete::Away::setAutoAway()
TQPtrList<Kopete::Account> accounts = Kopete::AccountManager::self()->accounts();
for(Kopete::Account *i=accounts.first() ; i; i=accounts.next() )
{
- if(i->myself()->onlineStatus().status() == Kopete::OnlineStatus::Online)
+ if(i->myself()->onlinetqStatus().status() == Kopete::OnlineStatus::Online)
{
d->autoAwayAccounts.append(i);
if(d->useAutoAwayMessage)
{
// Display a specific away message
- i->setOnlineStatus( Kopete::OnlineStatusManager::self()->onlineStatus( i->protocol() ,
+ i->setOnlineStatus( Kopete::OnlineStatusManager::self()->onlinetqStatus( i->protocol() ,
Kopete::OnlineStatusManager::Idle ) ,
getInstance()->d->autoAwayMessage);
}
else
{
// Display the last away message used
- i->setOnlineStatus( Kopete::OnlineStatusManager::self()->onlineStatus( i->protocol() ,
+ i->setOnlineStatus( Kopete::OnlineStatusManager::self()->onlinetqStatus( i->protocol() ,
Kopete::OnlineStatusManager::Idle ) ,
getInstance()->d->awayMessage);
}