summaryrefslogtreecommitdiffstats
path: root/tdecore
diff options
context:
space:
mode:
Diffstat (limited to 'tdecore')
-rw-r--r--tdecore/kcrash.cpp10
-rw-r--r--tdecore/kdemacros.h.cmake2
-rw-r--r--tdecore/kdemacros.h.in2
-rw-r--r--tdecore/kglobalaccel.cpp6
-rw-r--r--tdecore/kglobalaccel_win.cpp6
-rw-r--r--tdecore/kglobalaccel_x11.cpp10
-rw-r--r--tdecore/kiconeffect.cpp2
-rw-r--r--tdecore/kidna.cpp8
-rw-r--r--tdecore/kipc.cpp8
-rw-r--r--tdecore/kkeynative.h8
-rw-r--r--tdecore/kkeynative_x11.cpp18
-rw-r--r--tdecore/kkeyserver_x11.cpp56
-rw-r--r--tdecore/kmanagerselection.cpp2
-rw-r--r--tdecore/kmanagerselection.h2
-rw-r--r--tdecore/kmountpoint.cpp2
-rw-r--r--tdecore/knotifyclient.cpp4
-rw-r--r--tdecore/krootprop.cpp2
-rw-r--r--tdecore/ksimpledirwatch.cpp2
-rw-r--r--tdecore/kstandarddirs.cpp20
-rw-r--r--tdecore/kuniqueapplication.cpp24
-rw-r--r--tdecore/kuniqueapplication.h2
-rw-r--r--tdecore/kurl.cpp10
-rw-r--r--tdecore/kurldrag.cpp2
-rw-r--r--tdecore/kurldrag.h2
-rw-r--r--tdecore/kxerrorhandler.cpp2
-rw-r--r--tdecore/kxmessages.cpp2
-rw-r--r--tdecore/kxmessages.h2
-rw-r--r--tdecore/netwm.cpp2
-rw-r--r--tdecore/netwm.h2
-rw-r--r--tdecore/tdeaccel.cpp20
-rw-r--r--tdecore/tdeaccelbase.cpp12
-rw-r--r--tdecore/tdeaccelprivate.h2
-rw-r--r--tdecore/tdeapplication.cpp164
-rw-r--r--tdecore/tdeapplication.h10
-rw-r--r--tdecore/tdecmdlineargs.cpp10
-rw-r--r--tdecore/tdeconfigbackend.cpp2
-rw-r--r--tdecore/tdeconfigbase.cpp2
-rw-r--r--tdecore/tdeglobalsettings.cpp24
-rw-r--r--tdecore/tdelibs_export.h2
-rw-r--r--tdecore/tdelocale.cpp6
-rw-r--r--tdecore/tdestartupinfo.cpp26
-rw-r--r--tdecore/tdestartupinfo.h4
-rw-r--r--tdecore/twin.cpp144
-rw-r--r--tdecore/twinmodule.cpp2
44 files changed, 325 insertions, 325 deletions
diff --git a/tdecore/kcrash.cpp b/tdecore/kcrash.cpp
index 6fb5e8ff7..163b10d36 100644
--- a/tdecore/kcrash.cpp
+++ b/tdecore/kcrash.cpp
@@ -53,7 +53,7 @@
#include <../tdeinit/tdelauncher_cmds.h>
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
#include <X11/Xlib.h>
#endif
@@ -160,14 +160,14 @@ TDECrash::defaultCrashHandler (int sig)
// argument 0 has to be drkonqi
argv[i++] = "drkonqi";
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
// start up on the correct display
argv[i++] = "-display";
if ( tqt_xdisplay() )
argv[i++] = XDisplayString(tqt_xdisplay());
else
argv[i++] = getenv("DISPLAY");
-#elif defined(Q_WS_QWS)
+#elif defined(TQ_WS_QWS)
// start up on the correct display
argv[i++] = "-display";
argv[i++] = getenv("QWS_DISPLAY");
@@ -351,9 +351,9 @@ static char *getDisplay()
/*
don't test for a value from tqglobal.h but instead distinguish
Qt/X11 from Qt/Embedded by the fact that Qt/E apps have -DQWS
- on the commandline (which in tqglobal.h however triggers Q_WS_QWS,
+ on the commandline (which in tqglobal.h however triggers TQ_WS_QWS,
but we don't want to include that here) (Simon)
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
*/
#if !defined(QWS)
display = getenv("DISPLAY");
diff --git a/tdecore/kdemacros.h.cmake b/tdecore/kdemacros.h.cmake
index 3750db1e4..683538f9d 100644
--- a/tdecore/kdemacros.h.cmake
+++ b/tdecore/kdemacros.h.cmake
@@ -41,7 +41,7 @@
#ifdef __KDE_HAVE_GCC_VISIBILITY
#define KDE_NO_EXPORT __attribute__ ((visibility("hidden")))
#define KDE_EXPORT __attribute__ ((visibility("default")))
-#elif defined(Q_WS_WIN)
+#elif defined(TQ_WS_WIN)
#define KDE_NO_EXPORT
#define KDE_EXPORT __declspec(dllexport)
#else
diff --git a/tdecore/kdemacros.h.in b/tdecore/kdemacros.h.in
index 41cb0d68f..d72efe36c 100644
--- a/tdecore/kdemacros.h.in
+++ b/tdecore/kdemacros.h.in
@@ -40,7 +40,7 @@
#ifdef __KDE_HAVE_GCC_VISIBILITY
#define KDE_NO_EXPORT __attribute__ ((visibility("hidden")))
#define KDE_EXPORT __attribute__ ((visibility("default")))
-#elif defined(Q_WS_WIN)
+#elif defined(TQ_WS_WIN)
#define KDE_NO_EXPORT
#define KDE_EXPORT __declspec(dllexport)
#else
diff --git a/tdecore/kglobalaccel.cpp b/tdecore/kglobalaccel.cpp
index 746721e40..5da0093a2 100644
--- a/tdecore/kglobalaccel.cpp
+++ b/tdecore/kglobalaccel.cpp
@@ -18,11 +18,11 @@
*/
#include "kglobalaccel.h"
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#include "kglobalaccel_x11.h"
-#elif defined(Q_WS_WIN)
+#elif defined(TQ_WS_WIN)
#include "kglobalaccel_win.h"
-#elif defined(Q_WS_MACX)
+#elif defined(TQ_WS_MACX)
#include "kglobalaccel_mac.h"
#else
#include "kglobalaccel_emb.h"
diff --git a/tdecore/kglobalaccel_win.cpp b/tdecore/kglobalaccel_win.cpp
index 8b9d0f0a3..7b49ecfe4 100644
--- a/tdecore/kglobalaccel_win.cpp
+++ b/tdecore/kglobalaccel_win.cpp
@@ -20,7 +20,7 @@
#include "config.h"
#include <tqwindowdefs.h>
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
#include "kglobalaccel_win.h"
#include "kglobalaccel.h"
@@ -161,7 +161,7 @@ bool TDEGlobalAccelPrivate::grabKey( const KKeyServer::Key& key, bool bGrab, TDE
bool failed = false;
if( bGrab ) {
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
failed = handler.error( true ); // sync now
#endif
// If grab failed, then ungrab any grabs that could possibly succeed
@@ -342,4 +342,4 @@ void TDEGlobalAccelPrivate::slotActivated( int iAction )
#include "kglobalaccel_win.moc"
-#endif // !Q_WS_WIN
+#endif // !TQ_WS_WIN
diff --git a/tdecore/kglobalaccel_x11.cpp b/tdecore/kglobalaccel_x11.cpp
index da77403ca..d76b8cdac 100644
--- a/tdecore/kglobalaccel_x11.cpp
+++ b/tdecore/kglobalaccel_x11.cpp
@@ -20,7 +20,7 @@
#include "config.h"
#include <tqwindowdefs.h>
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#include "kglobalaccel_x11.h"
#include "kglobalaccel.h"
@@ -35,7 +35,7 @@
#include <kdebug.h>
#include <kkeynative.h>
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#include <kxerrorhandler.h>
#endif
@@ -197,7 +197,7 @@ bool TDEGlobalAccelPrivate::grabKey( const KKeyServer::Key& key, bool bGrab, TDE
return false;
}
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
KXErrorHandler handler( XGrabErrorHandler );
#endif
// We'll have to grab 8 key modifier combinations in order to cover all
@@ -227,7 +227,7 @@ bool TDEGlobalAccelPrivate::grabKey( const KKeyServer::Key& key, bool bGrab, TDE
bool failed = false;
if( bGrab ) {
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
failed = handler.error( true ); // sync now
#endif
// If grab failed, then ungrab any grabs that could possibly succeed
@@ -451,4 +451,4 @@ void TDEGlobalAccelPrivate::slotActivated( int iAction )
#include "kglobalaccel_x11.moc"
-#endif // !Q_WS_X11
+#endif // !TQ_WS_X11
diff --git a/tdecore/kiconeffect.cpp b/tdecore/kiconeffect.cpp
index d8f3184c1..a5cb4bcae 100644
--- a/tdecore/kiconeffect.cpp
+++ b/tdecore/kiconeffect.cpp
@@ -35,7 +35,7 @@
#include <kicontheme.h>
#include "kiconeffect.h"
-#if defined(Q_WS_WIN) || defined(Q_WS_MACX)
+#if defined(TQ_WS_WIN) || defined(TQ_WS_MACX)
static bool tqt_use_xrender=true;
static bool tqt_has_xft=true;
#else
diff --git a/tdecore/kidna.cpp b/tdecore/kidna.cpp
index 23d0554d1..e8df061ec 100644
--- a/tdecore/kidna.cpp
+++ b/tdecore/kidna.cpp
@@ -21,18 +21,18 @@
#include "kidna.h"
-#ifndef Q_WS_WIN //TODO kresolver not ported
+#ifndef TQ_WS_WIN //TODO kresolver not ported
#include "kresolver.h"
#endif
#include <kdebug.h>
-#ifndef Q_WS_WIN //TODO knetwork not ported
+#ifndef TQ_WS_WIN //TODO knetwork not ported
using namespace KNetwork;
#endif
TQCString KIDNA::toAsciiCString(const TQString &idna)
{
-#ifndef Q_WS_WIN //TODO kresolver not ported
+#ifndef TQ_WS_WIN //TODO kresolver not ported
return KResolver::domainToAscii(idna);
#else
return TQCString();
@@ -53,7 +53,7 @@ TQString KIDNA::toAscii(const TQString &idna)
TQString KIDNA::toUnicode(const TQString &idna)
{
-#ifndef Q_WS_WIN //TODO kresolver not ported
+#ifndef TQ_WS_WIN //TODO kresolver not ported
if (idna.length() && (idna[0] == (TQChar)'.'))
return idna[0] + KResolver::domainToUnicode(idna.mid(1));
return KResolver::domainToUnicode(idna);
diff --git a/tdecore/kipc.cpp b/tdecore/kipc.cpp
index e6ec7cc4e..8e6da23e2 100644
--- a/tdecore/kipc.cpp
+++ b/tdecore/kipc.cpp
@@ -30,7 +30,7 @@
#include <tqevent.h>
#include <tqwindowdefs.h>
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
#include <X11/X.h>
#include <X11/Xlib.h>
#include <kxerrorhandler.h>
@@ -39,7 +39,7 @@
#include <kipc.h>
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
static long getSimpleProperty(Window w, Atom a)
{
Atom real_type;
@@ -59,7 +59,7 @@ static long getSimpleProperty(Window w, Atom a)
void KIPC::sendMessage(Message msg, WId w, int data)
{
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
static Atom a = 0;
if (a == 0)
a = XInternAtom(tqt_xdisplay(), "KIPC_COMM_ATOM", False);
@@ -88,7 +88,7 @@ void KIPC::sendMessage(Message msg, WId w, int data)
void KIPC::sendMessageAll(Message msg, int data)
{
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
unsigned int i, nrootwins;
Window dw1, dw2, *rootwins = 0;
Display *dpy = tqt_xdisplay();
diff --git a/tdecore/kkeynative.h b/tdecore/kkeynative.h
index ffcc13a69..5ff83ccbc 100644
--- a/tdecore/kkeynative.h
+++ b/tdecore/kkeynative.h
@@ -25,7 +25,7 @@
#include <tdeshortcut.h>
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
typedef union _XEvent XEvent;
#endif
@@ -45,7 +45,7 @@ class TDECORE_EXPORT KKeyNative
*/
KKeyNative();
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
/**
* Extracts a new native key from the given xevent.
* @param xevent the XEvent that contains the key
@@ -76,7 +76,7 @@ class TDECORE_EXPORT KKeyNative
*/
void clear();
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
/**
* Initializes the native key by extracting the information
* from the given xevent.
@@ -205,7 +205,7 @@ class TDECORE_EXPORT KKeyNative
*/
static bool keyboardHasWinKey();
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
/**
* Returns the equivalent X modifier mask of the given modifier flag.
* @param modFlag the mod flags to test
diff --git a/tdecore/kkeynative_x11.cpp b/tdecore/kkeynative_x11.cpp
index d5ecb24da..8ab457a26 100644
--- a/tdecore/kkeynative_x11.cpp
+++ b/tdecore/kkeynative_x11.cpp
@@ -23,7 +23,7 @@
#include <tqnamespace.h>
#include <tqwindowdefs.h>
-#if defined(Q_WS_X11) || defined(Q_WS_WIN) || defined(Q_WS_MACX) // Only compile this module if we're compiling for X11, mac or win32
+#if defined(TQ_WS_X11) || defined(TQ_WS_WIN) || defined(TQ_WS_MACX) // Only compile this module if we're compiling for X11, mac or win32
#include "kkeynative.h"
#include "kkeyserver_x11.h"
@@ -34,7 +34,7 @@
#include <kdebug.h>
#include <tdelocale.h>
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#define XK_MISCELLANY
#define XK_XKB_KEYS
#include <X11/X.h>
@@ -56,7 +56,7 @@ static KKeyNative* gx_pkey = 0;
KKeyNative::KKeyNative() { clear(); }
KKeyNative::KKeyNative( const KKey& key ) { init( key ); }
KKeyNative::KKeyNative( const KKeyNative& key ) { init( key ); }
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
KKeyNative::KKeyNative( const XEvent* pEvent ) { init( pEvent ); }
#endif
@@ -77,7 +77,7 @@ void KKeyNative::clear()
m_sym = 0;
}
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
bool KKeyNative::init( const XEvent* pEvent )
{
KeySym keySym;
@@ -91,11 +91,11 @@ bool KKeyNative::init( const XEvent* pEvent )
bool KKeyNative::init( const KKey& key )
{
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
m_sym = key.sym();
m_code = m_sym; //key.keyCodeQt();
m_mod = key.m_mod;
-#elif !defined(Q_WS_WIN) && !defined(Q_WS_MACX)
+#elif !defined(TQ_WS_WIN) && !defined(TQ_WS_MACX)
// Get any extra mods required by the sym.
// E.g., XK_Plus requires SHIFT on the en layout.
m_sym = key.sym();
@@ -167,7 +167,7 @@ KKeyNative& KKeyNative::null()
KKey KKeyNative::key() const
{
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
return KKey( m_sym, m_mod );
#else
uint modSpec;
@@ -192,7 +192,7 @@ int KKeyNative::keyCodeQt() const
bool KKeyNative::keyboardHasWinKey() { return KKeyServer::keyboardHasWinKey(); }
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
uint KKeyNative::modX( KKey::ModFlag modFlag ) { return KKeyServer::modX( modFlag ); }
uint KKeyNative::accelModMaskX() { return KKeyServer::accelModMaskX(); }
uint KKeyNative::modXNumLock() { return KKeyServer::modXNumLock(); }
@@ -201,4 +201,4 @@ uint KKeyNative::modXScrollLock() { return KKeyServer::modXScrollLo
uint KKeyNative::modXModeSwitch() { return KKeyServer::modXModeSwitch(); }
#endif
-#endif // Q_WS_X11
+#endif // TQ_WS_X11
diff --git a/tdecore/kkeyserver_x11.cpp b/tdecore/kkeyserver_x11.cpp
index ebe06de97..77ca61763 100644
--- a/tdecore/kkeyserver_x11.cpp
+++ b/tdecore/kkeyserver_x11.cpp
@@ -25,7 +25,7 @@
#include <tqnamespace.h>
#include <tqwindowdefs.h>
-#if defined(Q_WS_X11) || defined(Q_WS_WIN) || defined(Q_WS_MACX) // Only compile this module if we're compiling for X11, mac or win32
+#if defined(TQ_WS_X11) || defined(TQ_WS_WIN) || defined(TQ_WS_MACX) // Only compile this module if we're compiling for X11, mac or win32
#include "kkeyserver_x11.h"
#include "kkeynative.h"
@@ -36,7 +36,7 @@
#include <tdeglobal.h>
#include <tdelocale.h>
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
# define XK_MISCELLANY
# define XK_XKB_KEYS
# include <X11/X.h>
@@ -78,7 +78,7 @@ struct ModInfo
{
KKey::ModFlag mod;
int modQt;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
uint modX;
#endif
const char* psName;
@@ -140,7 +140,7 @@ static const SymName g_rgSymNames[] = {
{ 0, 0 }
};
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
static SymVariation g_rgSymVariation[] =
{
{ '/', XK_KP_Divide, false },
@@ -327,14 +327,14 @@ static const TransKey g_rgQtToSymX[] =
{ TQt::Key_KeyboardBrightnessDown, XF86XK_KbdBrightnessDown },
#endif
};
-#endif //Q_WS_X11
+#endif //TQ_WS_X11
//---------------------------------------------------------------------
// Initialization
//---------------------------------------------------------------------
static bool g_bInitializedMods, g_bInitializedVariations, g_bInitializedKKeyLabels;
static bool g_bMacLabels;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
static uint g_modXNumLock, g_modXScrollLock, g_modXModeSwitch;
bool initializeMods()
@@ -386,7 +386,7 @@ static void initializeVariations()
g_rgSymVariation[i].bActive = (XKeysymToKeycode( tqt_xdisplay(), g_rgSymVariation[i].symVariation ) != 0);
g_bInitializedVariations = true;
}
-#endif //Q_WS_X11
+#endif //TQ_WS_X11
static void intializeKKeyLabels()
{
@@ -421,10 +421,10 @@ bool Sym::initQt( int keyQt )
return true;
}
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
m_sym = symQt;
return true;
-#elif defined(Q_WS_X11)
+#elif defined(TQ_WS_X11)
for( uint i = 0; i < sizeof(g_rgQtToSymX)/sizeof(TransKey); i++ ) {
if( g_rgQtToSymX[i].keySymQt == symQt ) {
m_sym = g_rgQtToSymX[i].keySymX;
@@ -437,7 +437,7 @@ bool Sym::initQt( int keyQt )
symQt != TQt::Key_Meta && symQt != TQt::Key_Direction_L && symQt != TQt::Key_Direction_R )
kdDebug(125) << "Sym::initQt( " << TQString::number(keyQt,16) << " ): failed to convert key." << endl;
return false;
-#elif defined(Q_WS_MACX)
+#elif defined(TQ_WS_MACX)
m_sym = symQt;
return true;
#endif
@@ -459,7 +459,7 @@ bool Sym::init( const TQString& s )
}
}
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
// search for name in KKeys array
for ( KKeys const *pKey = kde_KKEYS; pKey->code != 0xffff; pKey++) {
if( tqstricmp( s.latin1(), pKey->name ) == 0 ) {
@@ -468,7 +468,7 @@ bool Sym::init( const TQString& s )
}
}
m_sym = 0;
-#elif defined(Q_WS_X11)
+#elif defined(TQ_WS_X11)
// search X list: 's' as is, all lower, first letter in caps
m_sym = XStringToKeysym( s.latin1() );
if( !m_sym ) {
@@ -490,10 +490,10 @@ int Sym::qt() const
return TQChar(m_sym).upper();
return m_sym;
}
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
if( m_sym < 0x3000 )
return m_sym;
-#elif defined(Q_WS_X11)
+#elif defined(TQ_WS_X11)
if( m_sym < 0x3000 )
return m_sym | TQt::UNICODE_ACCEL;
@@ -511,7 +511,7 @@ TQString Sym::toString( bool bUserSpace ) const
}
// If it's a unicode character,
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
else if( m_sym < 0x1000 ) {
#else
else if( m_sym < 0x3000 ) {
@@ -533,9 +533,9 @@ TQString Sym::toString( bool bUserSpace ) const
}
TQString s;
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
s = TQKeySequence( m_sym );
-#elif defined(Q_WS_X11)
+#elif defined(TQ_WS_X11)
// Get X-name
s = XKeysymToString( m_sym );
#endif
@@ -549,7 +549,7 @@ TQString Sym::toString() const { return toString( true ); }
uint Sym::getModsRequired() const
{
uint mod = 0;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
// FIXME: This might not be true on all keyboard layouts!
if( m_sym == XK_Sys_Req ) return KKey::ALT;
if( m_sym == XK_Break ) return KKey::CTRL;
@@ -580,7 +580,7 @@ uint Sym::getModsRequired() const
uint Sym::getSymVariation() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if( !g_bInitializedVariations )
initializeVariations();
for( int i = 0; g_rgSymVariation[i].sym != 0; i++ )
@@ -603,7 +603,7 @@ void Sym::capitalizeKeyname( TQString& s )
// Public functions
//---------------------------------------------------------------------
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
uint modX( KKey::ModFlag mod )
{
if( mod == KKey::WIN && !g_bInitializedMods )
@@ -632,7 +632,7 @@ uint accelModMaskX()
initializeMods();
return ShiftMask | ControlMask | Mod1Mask | g_rgModInfo[3].modX;
}
-#endif //Q_WS_X11
+#endif //TQ_WS_X11
bool keyQtToSym( int keyQt, uint& keySym )
{
@@ -678,7 +678,7 @@ bool modToModQt( uint mod, int& modQt )
return true;
}
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
//wrapped
bool modXToModQt( uint modX, int& modQt )
{
@@ -699,7 +699,7 @@ bool keyboardHasWinKey() {
return true;
}
-#elif defined(Q_WS_MACX)
+#elif defined(TQ_WS_MACX)
bool modXToModQt(uint modX, int& modQt)
{
@@ -715,7 +715,7 @@ bool modXToMod( uint , uint& )
{
return false;
}
-#elif defined(Q_WS_X11)
+#elif defined(TQ_WS_X11)
bool modToModX( uint mod, uint& modX )
{
@@ -785,7 +785,7 @@ bool codeXToSym( uchar codeX, uint modX, uint& sym )
sym = (uint) keySym;
return true;
}
-#endif //!Q_WS_WIN
+#endif //!TQ_WS_WIN
static TQString modToString( uint mod, bool bUserSpace )
{
@@ -954,7 +954,7 @@ KKey Key::key() const
if( m_code == CODE_FOR_QT )
return KKey( keyCodeQt() );
else {
-#if defined(Q_WS_WIN) || defined(Q_WS_MACX)
+#if defined(TQ_WS_WIN) || defined(TQ_WS_MACX)
return KKey();
#else
uint mod;
@@ -1043,7 +1043,7 @@ void Variations::init( const KKey& key, bool bQt )
// Ctrl+Pause => Ctrl+Break
void KKey::simplify()
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if( m_sym == XK_Sys_Req ) {
m_sym = XK_Print;
m_mod |= ALT;
@@ -1066,5 +1066,5 @@ void KKey::simplify()
#endif
}
-#endif //Q_WS_X11 || Q_WS_WIN
+#endif //TQ_WS_X11 || TQ_WS_WIN
diff --git a/tdecore/kmanagerselection.cpp b/tdecore/kmanagerselection.cpp
index 5bda6d6ed..bfae6406a 100644
--- a/tdecore/kmanagerselection.cpp
+++ b/tdecore/kmanagerselection.cpp
@@ -41,7 +41,7 @@ DEALINGS IN THE SOFTWARE.
#endif
#include <tqobject.h>
-#ifdef Q_WS_X11 // FIXME(E)
+#ifdef TQ_WS_X11 // FIXME(E)
#include "kmanagerselection.h"
diff --git a/tdecore/kmanagerselection.h b/tdecore/kmanagerselection.h
index b31a4efe0..59cc35c56 100644
--- a/tdecore/kmanagerselection.h
+++ b/tdecore/kmanagerselection.h
@@ -28,7 +28,7 @@ DEALINGS IN THE SOFTWARE.
#include <tqobject.h>
#include <tdelibs_export.h>
-#ifdef Q_WS_X11 // FIXME(E)
+#ifdef TQ_WS_X11 // FIXME(E)
#include <X11/Xlib.h>
diff --git a/tdecore/kmountpoint.cpp b/tdecore/kmountpoint.cpp
index ae698c2af..e78fc7335 100644
--- a/tdecore/kmountpoint.cpp
+++ b/tdecore/kmountpoint.cpp
@@ -334,7 +334,7 @@ KMountPoint::List KMountPoint::currentMountPoints(int infoNeeded)
}
free( mntctl_buffer );
-#elif defined(Q_WS_WIN)
+#elif defined(TQ_WS_WIN)
//TODO?
#else
STRUCT_SETMNTENT mnttab;
diff --git a/tdecore/knotifyclient.cpp b/tdecore/knotifyclient.cpp
index a1fad6a36..1eb4b42fb 100644
--- a/tdecore/knotifyclient.cpp
+++ b/tdecore/knotifyclient.cpp
@@ -31,7 +31,7 @@
#include <kdebug.h>
#include <kstaticdeleter.h>
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#include <X11/X.h>
#include <X11/Xlib.h>
#include <X11/XKBlib.h>
@@ -77,7 +77,7 @@ static int sendNotifyEvent(const TQString &message, const TQString &text,
if (!kapp) return 0;
// ensure tray icon is shown and positioned before sending event to notification daemon
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
XFlush(tqt_xdisplay());
#endif
diff --git a/tdecore/krootprop.cpp b/tdecore/krootprop.cpp
index c717a1823..72fd5ae78 100644
--- a/tdecore/krootprop.cpp
+++ b/tdecore/krootprop.cpp
@@ -20,7 +20,7 @@
#include <tqwidget.h>
#include "config.h"
-#ifdef Q_WS_X11 // not needed anyway :-)
+#ifdef TQ_WS_X11 // not needed anyway :-)
#include "krootprop.h"
#include "tdeglobal.h"
diff --git a/tdecore/ksimpledirwatch.cpp b/tdecore/ksimpledirwatch.cpp
index 205af6baf..7d9cfa70c 100644
--- a/tdecore/ksimpledirwatch.cpp
+++ b/tdecore/ksimpledirwatch.cpp
@@ -1218,7 +1218,7 @@ void KSimpleDirWatchPrivate::emitEvent(Entry* e, int event, const TQString &file
else
#ifdef Q_OS_UNIX
path += "/" + fileName;
-#elif defined(Q_WS_WIN)
+#elif defined(TQ_WS_WIN)
//current drive is passed instead of /
path += TQDir::currentDirPath().left(2) + "/" + fileName;
#endif
diff --git a/tdecore/kstandarddirs.cpp b/tdecore/kstandarddirs.cpp
index 8f189e6d1..b7d41d136 100644
--- a/tdecore/kstandarddirs.cpp
+++ b/tdecore/kstandarddirs.cpp
@@ -427,14 +427,14 @@ TQString TDEStandardDirs::findResourceDir( const char *type,
for (TQStringList::ConstIterator it = candidates.begin();
it != candidates.end(); ++it) {
if (exists(*it + filename)) {
-#ifdef Q_WS_WIN //this ensures we're using installed .la files
+#ifdef TQ_WS_WIN //this ensures we're using installed .la files
if ((*it).isEmpty() && filename.right(3)==".la") {
#ifndef NDEBUG
fprintf(stderr, "TDEStandardDirs::findResourceDir() found .la in cwd: skipping. (fname=%s)\n", filename.ascii());
#endif
continue;
}
-#endif //Q_WS_WIN
+#endif //TQ_WS_WIN
return *it;
}
}
@@ -480,7 +480,7 @@ static void lookupDirectory(const TQString& path, const TQString &relPart,
if (!dp)
return;
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
assert(path.at(path.length() - 1) == TQChar('/') || path.at(path.length() - 1) == TQChar('\\'));
#else
assert(path.at(path.length() - 1) == TQChar('/'));
@@ -571,7 +571,7 @@ static void lookupPrefix(const TQString& prefix, const TQString& relpath,
if (prefix.isEmpty()) //for sanity
return;
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
assert(prefix.at(prefix.length() - 1) == TQChar('/') || prefix.at(prefix.length() - 1) == TQChar('\\'));
#else
assert(prefix.at(prefix.length() - 1) == TQChar('/'));
@@ -754,7 +754,7 @@ void TDEStandardDirs::createSpecialResource(const char *type)
}
}
}
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
if (relink)
{
if (!makeDir(dir, 0700))
@@ -932,7 +932,7 @@ TQStringList TDEStandardDirs::systemPaths( const TQString& pstr )
TQString TDEStandardDirs::findExe( const TQString& appname,
const TQString& pstr, bool ignore)
{
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
TQString real_appname = appname + ".exe";
#else
TQString real_appname = appname;
@@ -981,7 +981,7 @@ TQString TDEStandardDirs::findExe( const TQString& appname,
int TDEStandardDirs::findAllExe( TQStringList& list, const TQString& appname,
const TQString& pstr, bool ignore )
{
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
TQString real_appname = appname + ".exe";
#else
TQString real_appname = appname;
@@ -1259,7 +1259,7 @@ TQString TDEStandardDirs::kfsstnd_defaultprefix()
TDEStandardDirsSingleton* s = TDEStandardDirsSingleton::self();
if (!s->defaultprefix.isEmpty())
return s->defaultprefix;
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
s->defaultprefix = readEnvPath("TDEDIR");
if (s->defaultprefix.isEmpty()) {
s->defaultprefix = TQFile::decodeName("c:\\kde");
@@ -1279,7 +1279,7 @@ TQString TDEStandardDirs::kfsstnd_defaultbindir()
TDEStandardDirsSingleton* s = TDEStandardDirsSingleton::self();
if (!s->defaultbindir.isEmpty())
return s->defaultbindir;
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
s->defaultbindir = kfsstnd_defaultprefix() + TQString::fromLatin1("/bin");
#else //UNIX
s->defaultbindir = __TDE_BINDIR;
@@ -1374,7 +1374,7 @@ void TDEStandardDirs::addKDEDefaults()
{
xdgdirList.clear();
xdgdirList.append("/etc/xdg");
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
xdgdirList.append(kfsstnd_defaultprefix() + "/etc/xdg");
#else
xdgdirList.append(KDESYSCONFDIR "/xdg");
diff --git a/tdecore/kuniqueapplication.cpp b/tdecore/kuniqueapplication.cpp
index 5e0b1cdff..8966063d1 100644
--- a/tdecore/kuniqueapplication.cpp
+++ b/tdecore/kuniqueapplication.cpp
@@ -38,7 +38,7 @@
#include <kstandarddirs.h>
#include <tdeaboutdata.h>
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
#include <twin.h>
#include <tdestartupinfo.h>
#endif
@@ -47,12 +47,12 @@
#include "kdebug.h"
#include "kuniqueapplication.h"
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
#include <netwm.h>
#include <X11/Xlib.h>
#define DISPLAY "DISPLAY"
#else
-# ifdef Q_WS_QWS
+# ifdef TQ_WS_QWS
# define DISPLAY "QWS_DISPLAY"
# else
# define DISPLAY "DISPLAY"
@@ -96,7 +96,7 @@ KUniqueApplication::start()
return true;
s_uniqueTestDone = true;
addCmdLineOptions(); // Make sure to add cmd line options
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
s_nofork = true;
#else
TDECmdLineArgs *args = TDECmdLineArgs::parsedArgs("kuniqueapp");
@@ -118,7 +118,7 @@ KUniqueApplication::start()
// Check to make sure that we're actually able to register with the DCOP
// server.
-#ifndef Q_WS_WIN //TODO
+#ifndef TQ_WS_WIN //TODO
if(dcopClient()->registerAs(appName, false).isEmpty()) {
startKdeinit();
if(dcopClient()->registerAs(appName, false).isEmpty()) {
@@ -184,7 +184,7 @@ KUniqueApplication::start()
::write(fd[1], &result, 1);
::close(fd[1]);
#if 0
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
// say we're up and running ( probably no new window will appear )
TDEStartupInfoId id;
if( kapp != NULL ) // TDEApplication constructor unsets the env. variable
@@ -209,7 +209,7 @@ KUniqueApplication::start()
}
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
TDEStartupInfoId id;
if( kapp != NULL ) // TDEApplication constructor unsets the env. variable
id.initId( kapp->startupId());
@@ -272,7 +272,7 @@ KUniqueApplication::start()
}
TQCString new_asn_id;
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
TDEStartupInfoId id;
if( kapp != NULL ) // TDEApplication constructor unsets the env. variable
id.initId( kapp->startupId());
@@ -333,7 +333,7 @@ KUniqueApplication::KUniqueApplication(bool allowStyles, bool GUIenabled, bool c
}
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
KUniqueApplication::KUniqueApplication(Display *display, TQt::HANDLE visual,
TQt::HANDLE colormap, bool allowStyles, bool configUnique)
: TDEApplication( display, visual, colormap, allowStyles, initHack( configUnique )),
@@ -387,7 +387,7 @@ void KUniqueApplication::newInstanceNoFork()
s_handleAutoStarted = false;
newInstance();
d->firstInstance = false;
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
// KDE4 remove
// A hack to make startup notification stop for apps which override newInstance()
// and reuse an already existing window there, but use KWin::activateWindow()
@@ -453,7 +453,7 @@ KUniqueApplication::processDelayed()
s_handleAutoStarted = false;
int exitCode = newInstance();
d->firstInstance = false;
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
if( s_handleAutoStarted )
TDEStartupInfo::handleAutoAppStartedSending(); // KDE4 remove?
#endif
@@ -481,7 +481,7 @@ int KUniqueApplication::newInstance()
if ( mainWidget() )
{
mainWidget()->show();
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
// This is the line that handles window activation if necessary,
// and what's important, it does it properly. If you reimplement newInstance(),
// and don't call the inherited one, use this (but NOT when newInstance()
diff --git a/tdecore/kuniqueapplication.h b/tdecore/kuniqueapplication.h
index 500cb3f26..6368b53ac 100644
--- a/tdecore/kuniqueapplication.h
+++ b/tdecore/kuniqueapplication.h
@@ -68,7 +68,7 @@ public:
bool GUIenabled=true,
bool configUnique=false);
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
/**
* Constructor. Takes command line arguments from TDECmdLineArgs
*
diff --git a/tdecore/kurl.cpp b/tdecore/kurl.cpp
index c1adf1bec..8122bb4bf 100644
--- a/tdecore/kurl.cpp
+++ b/tdecore/kurl.cpp
@@ -47,7 +47,7 @@
#include <tqtextcodec.h>
#include <tqmutex.h>
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
# define KURL_ROOTDIR_PATH "C:/"
#else
# define KURL_ROOTDIR_PATH "/"
@@ -386,7 +386,7 @@ static TQString cleanpath(const TQString &_path, bool cleanDirSeparator, bool de
orig_pos = pos;
}
-#ifdef Q_WS_WIN // prepend drive letter if exists (js)
+#ifdef TQ_WS_WIN // prepend drive letter if exists (js)
if (orig_pos >= 2 && isalpha(path[0].latin1()) && path[1]==':') {
result.prepend(TQString(path[0])+":");
}
@@ -670,7 +670,7 @@ void KURL::parse( const TQString& _url, int encoding_hint )
// Node 1: Accept alpha or slash
TQChar x = buf[pos++];
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
/* win32: accept <letter>: or <letter>:/ or <letter>:\ */
const bool alpha = isalpha((int)x);
if (alpha && len<2)
@@ -791,7 +791,7 @@ void KURL::parseURL( const TQString& _url, int encoding_hint )
// Node 1: Accept alpha or slash
TQChar x = buf[pos++];
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
/* win32: accept <letter>: or <letter>:/ or <letter>:\ */
const bool alpha = isalpha((int)x);
if (alpha && len<2)
@@ -1628,7 +1628,7 @@ TQString KURL::prettyURL( int _trailing, AdjustementFlags _flags) const
TQString u = prettyURL(_trailing);
if (_flags & StripFileProtocol && u.startsWith("file://")) {
u.remove(0, 7);
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
return TQDir::convertSeparators(u);
#endif
}
diff --git a/tdecore/kurldrag.cpp b/tdecore/kurldrag.cpp
index 07e669dfd..51346cf66 100644
--- a/tdecore/kurldrag.cpp
+++ b/tdecore/kurldrag.cpp
@@ -150,7 +150,7 @@ bool KURLDrag::decode( const TQMimeSource *e, KURL::List &uris, TQMap<TQString,T
return false; // Couldn't decode the URLs
}
-#ifdef Q_WS_QWS
+#ifdef TQ_WS_QWS
bool KURLDrag::decode( TQStringList const &e, KURL::List &uris )
{
TQStringList::ConstIterator end(e.end());
diff --git a/tdecore/kurldrag.h b/tdecore/kurldrag.h
index ba2c77e1f..2c2cd911a 100644
--- a/tdecore/kurldrag.h
+++ b/tdecore/kurldrag.h
@@ -133,7 +133,7 @@ public:
*/
static KURL stringToUrl(const TQCString &s);
-#ifdef Q_WS_QWS
+#ifdef TQ_WS_QWS
/**
* Convenience method that decodes the contents of @p e
* into a list of KURLs for Qt versions without a MIME clipboard.
diff --git a/tdecore/kxerrorhandler.cpp b/tdecore/kxerrorhandler.cpp
index 3a8524bed..ce9197bf6 100644
--- a/tdecore/kxerrorhandler.cpp
+++ b/tdecore/kxerrorhandler.cpp
@@ -23,7 +23,7 @@
*/
#include <tqwidget.h>
-#ifdef Q_WS_X11 //FIXME
+#ifdef TQ_WS_X11 //FIXME
#include "kxerrorhandler.h"
#include <assert.h>
diff --git a/tdecore/kxmessages.cpp b/tdecore/kxmessages.cpp
index 116c74d1c..b5f18ab04 100644
--- a/tdecore/kxmessages.cpp
+++ b/tdecore/kxmessages.cpp
@@ -28,7 +28,7 @@ DEALINGS IN THE SOFTWARE.
#include <tdeapplication.h>
-#ifdef Q_WS_X11 // FIXME(E): Figure out what parts we can/should emulate in QT/E
+#ifdef TQ_WS_X11 // FIXME(E): Figure out what parts we can/should emulate in QT/E
#include <X11/Xlib.h>
#include <kdebug.h>
diff --git a/tdecore/kxmessages.h b/tdecore/kxmessages.h
index 469c99663..d3787f6bb 100644
--- a/tdecore/kxmessages.h
+++ b/tdecore/kxmessages.h
@@ -30,7 +30,7 @@ DEALINGS IN THE SOFTWARE.
#include <tqmap.h>
#include <tdelibs_export.h>
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#include <X11/X.h>
class TQString;
diff --git a/tdecore/netwm.cpp b/tdecore/netwm.cpp
index 37190bf51..1e0670333 100644
--- a/tdecore/netwm.cpp
+++ b/tdecore/netwm.cpp
@@ -27,7 +27,7 @@
#include <tqwidget.h>
#include <tqapplication.h>
-#ifdef Q_WS_X11 //FIXME
+#ifdef TQ_WS_X11 //FIXME
#include "netwm.h"
diff --git a/tdecore/netwm.h b/tdecore/netwm.h
index ca8ed5139..8baef6ea3 100644
--- a/tdecore/netwm.h
+++ b/tdecore/netwm.h
@@ -29,7 +29,7 @@
#include "tdelibs_export.h"
#include <tqwidget.h>
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#include <X11/Xlib.h>
#include <X11/Xutil.h>
#include <X11/Xatom.h>
diff --git a/tdecore/tdeaccel.cpp b/tdecore/tdeaccel.cpp
index fa8cccc56..5d098e4d4 100644
--- a/tdecore/tdeaccel.cpp
+++ b/tdecore/tdeaccel.cpp
@@ -34,7 +34,7 @@
#include "tdeaccelprivate.h"
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
# include <X11/Xlib.h>
# ifdef KeyPress // needed for --enable-final
// defined by X11 headers
@@ -95,7 +95,7 @@ class TDEAccelEventHandler : public TQWidget
private:
TDEAccelEventHandler();
-# ifdef Q_WS_X11
+# ifdef TQ_WS_X11
bool x11Event( XEvent* pEvent );
# endif
@@ -109,13 +109,13 @@ bool TDEAccelEventHandler::g_bAccelActivated = false;
TDEAccelEventHandler::TDEAccelEventHandler()
: TQWidget( 0, "TDEAccelEventHandler" )
{
-# ifdef Q_WS_X11
+# ifdef TQ_WS_X11
if ( kapp )
kapp->installX11EventFilter( this );
# endif
}
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
bool tqt_try_modal( TQWidget *, XEvent * );
bool TDEAccelEventHandler::x11Event( XEvent* pEvent )
@@ -157,7 +157,7 @@ bool TDEAccelEventHandler::x11Event( XEvent* pEvent )
return false;
}
-#endif // Q_WS_X11
+#endif // TQ_WS_X11
//---------------------------------------------------------------------
// TDEAccelPrivate
@@ -172,7 +172,7 @@ TDEAccelPrivate::TDEAccelPrivate( TDEAccel* pParent, TQWidget* pWatch )
m_bAutoUpdate = true;
connect( (TQAccel*)m_pAccel, TQ_SIGNAL(activated(int)), this, TQ_SLOT(slotKeyPressed(int)) );
-#ifdef Q_WS_X11 //only makes sense if TDEAccelEventHandler is working
+#ifdef TQ_WS_X11 //only makes sense if TDEAccelEventHandler is working
if( m_pWatch )
m_pWatch->installEventFilter( this );
#endif
@@ -237,7 +237,7 @@ bool TDEAccelPrivate::connectKey( TDEAccelAction& action, const KKeyServer::Key&
m_mapIDToKey[nID] = keyQt;
if( action.objSlotPtr() && action.methodSlotPtr() ) {
-#ifdef Q_WS_WIN /** @todo TEMP: new implementation (commit #424926) didn't work */
+#ifdef TQ_WS_WIN /** @todo TEMP: new implementation (commit #424926) didn't work */
((TQAccel*)m_pAccel)->connectItem( nID, action.objSlotPtr(), action.methodSlotPtr() );
#else
((TQAccel*)m_pAccel)->connectItem( nID, this, TQ_SLOT(slotKeyPressed(int)));
@@ -334,7 +334,7 @@ void TDEAccelPrivate::slotMenuActivated( int iAction )
{
kdDebug(125) << "TDEAccelPrivate::slotMenuActivated( " << iAction << " )" << endl;
TDEAccelAction* pAction = actions().actionPtr( iAction );
-#ifdef Q_WS_WIN /** @todo TEMP: new implementation (commit #424926) didn't work */
+#ifdef TQ_WS_WIN /** @todo TEMP: new implementation (commit #424926) didn't work */
if( pAction ) {
connect( this, TQ_SIGNAL(menuItemActivated()), pAction->objSlotPtr(), pAction->methodSlotPtr() );
emit menuItemActivated();
@@ -362,7 +362,7 @@ bool TDEAccelPrivate::eventFilter( TQObject* /*pWatched*/, TQEvent* pEvent )
TDEAccelAction* pAction = m_mapIDToAction[nID];
if( !pAction->isEnabled() )
continue;
-#ifdef Q_WS_WIN /** @todo TEMP: new implementation (commit #424926) didn't work */
+#ifdef TQ_WS_WIN /** @todo TEMP: new implementation (commit #424926) didn't work */
TQGuardedPtr<TDEAccelPrivate> me = this;
connect( this, TQ_SIGNAL(menuItemActivated()), pAction->objSlotPtr(), pAction->methodSlotPtr() );
emit menuItemActivated();
@@ -384,7 +384,7 @@ bool TDEAccelPrivate::eventFilter( TQObject* /*pWatched*/, TQEvent* pEvent )
return false;
}
-#ifndef Q_WS_WIN /** @todo TEMP: new implementation (commit #424926) didn't work */
+#ifndef TQ_WS_WIN /** @todo TEMP: new implementation (commit #424926) didn't work */
void TDEAccelPrivate::emitActivatedSignal( TDEAccelAction* pAction )
{
if( pAction ) {
diff --git a/tdecore/tdeaccelbase.cpp b/tdecore/tdeaccelbase.cpp
index 41864d47c..a3fc23e3e 100644
--- a/tdecore/tdeaccelbase.cpp
+++ b/tdecore/tdeaccelbase.cpp
@@ -246,7 +246,7 @@ connect new key sequences
}
*/
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
struct TDEAccelBase::X
{
uint iAction, iSeq, iVari;
@@ -269,7 +269,7 @@ struct TDEAccelBase::X
bool operator >( const X& x ) { return compare( x ) > 0; }
bool operator <=( const X& x ) { return compare( x ) <= 0; }
};
-#endif //Q_WS_X11
+#endif //TQ_WS_X11
/*
#1 Ctrl+A
@@ -315,7 +315,7 @@ struct TDEAccelBase::X
bool TDEAccelBase::updateConnections()
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdDebug(125) << "TDEAccelBase::updateConnections() this = " << this << endl;
// Retrieve the list of keys to be connected, sorted by priority.
// (key, variation, seq)
@@ -414,11 +414,11 @@ bool TDEAccelBase::updateConnections()
<< (((*it).pAction) ? (*it).pAction->name() : TQString::null) << "'" << endl;
}
#endif
-#endif //Q_WS_X11
+#endif //TQ_WS_X11
return true;
}
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
// Construct a list of keys to be connected, sorted highest priority first.
void TDEAccelBase::createKeyList( TQValueVector<struct X>& rgKeys )
{
@@ -455,7 +455,7 @@ void TDEAccelBase::createKeyList( TQValueVector<struct X>& rgKeys )
// sort by priority: iVariation[of first key], iSequence, iAction
qHeapSort( rgKeys.begin(), rgKeys.end() );
}
-#endif //Q_WS_X11
+#endif //TQ_WS_X11
bool TDEAccelBase::insertConnection( TDEAccelAction* pAction )
{
diff --git a/tdecore/tdeaccelprivate.h b/tdecore/tdeaccelprivate.h
index d8b4b1793..8e6672615 100644
--- a/tdecore/tdeaccelprivate.h
+++ b/tdecore/tdeaccelprivate.h
@@ -38,7 +38,7 @@ class TDECORE_EXPORT TDEAccelPrivate : public TQObject, public TDEAccelBase
void menuItemActivated(TDEAccelAction*);
private:
-#ifndef Q_WS_WIN /** @todo TEMP: new implementation (commit #424926) didn't work */
+#ifndef TQ_WS_WIN /** @todo TEMP: new implementation (commit #424926) didn't work */
void emitActivatedSignal(TDEAccelAction*);
#endif
diff --git a/tdecore/tdeapplication.cpp b/tdecore/tdeapplication.cpp
index fd1cffc9f..326388614 100644
--- a/tdecore/tdeapplication.cpp
+++ b/tdecore/tdeapplication.cpp
@@ -95,7 +95,7 @@
#include <kmdcodec.h>
#include <kglobalaccel.h>
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
#include <tdestartupinfo.h>
#endif
@@ -110,7 +110,7 @@
#include <grp.h>
#include <sys/types.h>
-#ifndef Q_WS_WIN
+#ifndef TQ_WS_WIN
#include "twin.h"
#endif
@@ -123,8 +123,8 @@
#include <errno.h>
#include <string.h>
#include <netdb.h>
-#if defined Q_WS_X11
-//#ifndef Q_WS_QWS //FIXME(E): NetWM should talk to QWS...
+#if defined TQ_WS_X11
+//#ifndef TQ_WS_QWS //FIXME(E): NetWM should talk to QWS...
#include <netwm.h>
#endif
@@ -134,7 +134,7 @@
#include <paths.h>
#endif
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#include <X11/Xlib.h>
#ifdef COMPOSITE
#include <X11/extensions/Xrender.h>
@@ -149,7 +149,7 @@
#include <pwd.h>
-#ifndef Q_WS_WIN
+#ifndef TQ_WS_WIN
#include <KDE-ICE/ICElib.h>
#else
typedef void* IceIOErrorHandler;
@@ -160,22 +160,22 @@ typedef void* IceIOErrorHandler;
#define Button3Mask (1<<10)
#endif
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#define DISPLAY "DISPLAY"
-#elif defined(Q_WS_QWS)
+#elif defined(TQ_WS_QWS)
#define DISPLAY "QWS_DISPLAY"
#endif
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
#include <kipc.h>
#endif
-#ifdef Q_WS_MACX
+#ifdef TQ_WS_MACX
#include <Carbon/Carbon.h>
#include <tqimage.h>
#endif
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
#include <sys/ioctl.h>
#ifdef __linux__
#include <linux/vt.h>
@@ -197,12 +197,12 @@ bool TDEApplication::loadedByKdeinit = false;
DCOPClient *TDEApplication::s_DCOPClient = 0L;
bool TDEApplication::s_dcopClientNeedsPostInit = false;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
static Atom atom_DesktopWindow;
static Atom atom_NetSupported;
#endif
-#if defined(Q_WS_X11) && defined(COMPOSITE)
+#if defined(TQ_WS_X11) && defined(COMPOSITE)
static int composite_event, composite_error, composite_opcode;
static bool x11_composite_error_generated;
static int x11_error(Display *dpy, XErrorEvent *ev) {
@@ -221,7 +221,7 @@ TDECORE_EXPORT bool tqt_qclipboard_bailout_hack = false;
template class TQPtrList<KSessionManaged>;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
extern "C" {
static int kde_xio_errhandler( Display * dpy )
{
@@ -245,13 +245,13 @@ static void kde_ice_ioerrorhandler( IceConn conn )
}
#endif
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
void TDEApplication_init_windows(bool GUIenabled);
class QAssistantClient;
#endif
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
// --------------------------------------------------------------------------------------
// Get the VT number X is running on
// (code taken from GDM, daemon/getvt.c, GPLv2+)
@@ -310,7 +310,7 @@ int get_x_vtnum(Display *dpy)
return num;
}
// --------------------------------------------------------------------------------------
-#endif // Q_WS_X11
+#endif // TQ_WS_X11
/*
Private data to make keeping binary compatibility easier
@@ -328,10 +328,10 @@ public:
app_started_timer( NULL ),
m_KAppDCOPInterface( 0L ),
session_save( false )
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
,oldXErrorHandler( NULL )
,oldXIOErrorHandler( NULL )
-#elif defined Q_WS_WIN
+#elif defined TQ_WS_WIN
,qassistantclient( 0 )
#endif
{
@@ -339,7 +339,7 @@ public:
~TDEApplicationPrivate()
{
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
delete qassistantclient;
#endif
}
@@ -362,10 +362,10 @@ public:
TQTimer* app_started_timer;
KAppDCOPInterface *m_KAppDCOPInterface;
bool session_save;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
int (*oldXErrorHandler)(Display*,XErrorEvent*);
int (*oldXIOErrorHandler)(Display*);
-#elif defined Q_WS_WIN
+#elif defined TQ_WS_WIN
QAssistantClient* qassistantclient;
#endif
@@ -627,7 +627,7 @@ bool TDEApplication::notify(TQObject *receiver, TQEvent *event)
if( t == TQEvent::Show && receiver->isWidgetType())
{
TQWidget* w = static_cast<TQWidget*>( receiver );
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
if( w->isTopLevel() && !startupId().isEmpty() && !static_cast<TQShowEvent*>(event)->spontaneous()) // TODO better done using window group leader?
TDEStartupInfo::setWindowStartupId( w->winId(), startupId());
#endif
@@ -651,7 +651,7 @@ bool TDEApplication::notify(TQObject *receiver, TQEvent *event)
if( !ic->isNull())
{
w->setIcon( *ic );
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
KWin::setIcons( w->winId(), *ic, miniIcon());
#endif
}
@@ -662,7 +662,7 @@ bool TDEApplication::notify(TQObject *receiver, TQEvent *event)
void TDEApplication::checkAppStartedSlot()
{
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
TDEStartupInfo::handleAutoAppStartedSending();
#endif
}
@@ -689,7 +689,7 @@ TQString TDEApplication::sessionConfigName() const
return TQString("session/%1_%2_%3").arg(name()).arg(sessionId()).arg(sessKey);
}
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
static SmcConn mySmcConnection = 0;
static SmcConn tmpSmcConnection = 0;
#else
@@ -701,7 +701,7 @@ static TQTime* smModificationTime = 0;
TDEApplication::TDEApplication( int& argc, char** argv, const TQCString& rAppName,
bool allowStyles, bool GUIenabled, bool SMenabled ) :
TQApplication( argc, argv, GUIenabled, SMenabled ), TDEInstance(rAppName),
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
display(0L),
argb_visual(false),
#endif
@@ -729,7 +729,7 @@ TDEApplication::TDEApplication( int& argc, char** argv, const TQCString& rAppNam
TDEApplication::TDEApplication( int& argc, char** argv, const TQCString& rAppName,
bool allowStyles, bool GUIenabled ) :
TQApplication( argc, argv, GUIenabled ), TDEInstance(rAppName),
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
display(0L),
argb_visual(false),
#endif
@@ -754,7 +754,7 @@ TDEApplication::TDEApplication( int& argc, char** argv, const TQCString& rAppNam
TDEApplication::TDEApplication( bool allowStyles, bool GUIenabled, bool SMenabled ) :
TQApplication( *TDECmdLineArgs::tqt_argc(), *TDECmdLineArgs::tqt_argv(), GUIenabled, SMenabled ), // We need to be able to run command line apps
TDEInstance( TDECmdLineArgs::about),
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
display(0L),
argb_visual(false),
#endif
@@ -780,7 +780,7 @@ TDEApplication::TDEApplication( bool allowStyles, bool GUIenabled, bool SMenable
TDEApplication::TDEApplication( bool allowStyles, bool GUIenabled ) :
TQApplication( *TDECmdLineArgs::tqt_argc(), *TDECmdLineArgs::tqt_argv(), GUIenabled ), // We need to be able to run command line apps
TDEInstance( TDECmdLineArgs::about),
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
display(0L),
argb_visual(false),
#endif
@@ -800,7 +800,7 @@ TDEApplication::TDEApplication( bool allowStyles, bool GUIenabled ) :
d->m_KAppDCOPInterface = new KAppDCOPInterface(this);
}
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
TDEApplication::TDEApplication( Display *dpy, bool allowStyles ) :
TQApplication( dpy, *TDECmdLineArgs::tqt_argc(), *TDECmdLineArgs::tqt_argv(),
getX11RGBAVisual(dpy), getX11RGBAColormap(dpy) ),
@@ -877,7 +877,7 @@ TDEApplication::TDEApplication( bool allowStyles, bool GUIenabled, TDEInstance*
TQApplication( *TDECmdLineArgs::tqt_argc(), *TDECmdLineArgs::tqt_argv(),
GUIenabled ),
TDEInstance( _instance ),
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
display(0L),
#endif
argb_visual(false),
@@ -897,7 +897,7 @@ TDEApplication::TDEApplication( bool allowStyles, bool GUIenabled, TDEInstance*
d->m_KAppDCOPInterface = new KAppDCOPInterface(this);
}
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
TDEApplication::TDEApplication(Display *display, int& argc, char** argv, const TQCString& rAppName,
bool allowStyles, bool GUIenabled ) :
TQApplication( display ), TDEInstance(rAppName),
@@ -928,7 +928,7 @@ int TDEApplication::xioErrhandler( Display* dpy )
if(kapp)
{
emit shutDown();
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
d->oldXIOErrorHandler( dpy );
#else
Q_UNUSED(dpy);
@@ -940,7 +940,7 @@ int TDEApplication::xioErrhandler( Display* dpy )
int TDEApplication::xErrhandler( Display* dpy, void* err_ )
{ // no idea how to make forward decl. for XErrorEvent
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
XErrorEvent* err = static_cast< XErrorEvent* >( err_ );
if(kapp)
{
@@ -955,7 +955,7 @@ void TDEApplication::iceIOErrorHandler( _IceConn *conn )
{
emit shutDown();
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if ( d->oldIceIOErrorHandler != NULL )
(*d->oldIceIOErrorHandler)( conn );
#endif
@@ -1000,7 +1000,7 @@ void TDEApplication::init(bool GUIenabled)
KApp = this;
-#ifdef Q_WS_X11 //FIXME(E)
+#ifdef TQ_WS_X11 //FIXME(E)
// create all required atoms in _one_ roundtrip to the X server
if ( GUIenabled ) {
const int max = 20;
@@ -1031,7 +1031,7 @@ void TDEApplication::init(bool GUIenabled)
smw = 0;
// Initial KIPC event mask.
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
kipcEventMask = (1 << KIPC::StyleChanged) | (1 << KIPC::PaletteChanged) |
(1 << KIPC::FontChanged) | (1 << KIPC::BackgroundChanged) |
(1 << KIPC::ToolbarStyleChanged) | (1 << KIPC::SettingsChanged) |
@@ -1057,7 +1057,7 @@ void TDEApplication::init(bool GUIenabled)
if (GUIenabled)
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
// this is important since we fork() to launch the help (Matthias)
fcntl(ConnectionNumber(tqt_xdisplay()), F_SETFD, FD_CLOEXEC);
// set up the fancy (=robust and error ignoring ) KDE xio error handlers (Matthias)
@@ -1067,7 +1067,7 @@ void TDEApplication::init(bool GUIenabled)
connect( this, TQ_SIGNAL( aboutToQuit() ), this, TQ_SIGNAL( shutDown() ) );
-#ifdef Q_WS_X11 //FIXME(E)
+#ifdef TQ_WS_X11 //FIXME(E)
display = desktop()->x11Display();
#endif
@@ -1102,7 +1102,7 @@ void TDEApplication::init(bool GUIenabled)
d->checkAccelerators = new KCheckAccelerators( this );
}
-#ifdef Q_WS_MACX
+#ifdef TQ_WS_MACX
if (GUIenabled) {
TQPixmap pixmap = TDEGlobal::iconLoader()->loadIcon( TDECmdLineArgs::appName(),
TDEIcon::NoGroup, TDEIcon::SizeLarge, TDEIcon::DefaultState, 0L, false );
@@ -1145,7 +1145,7 @@ void TDEApplication::init(bool GUIenabled)
pSessionConfig = 0L;
bSessionManagement = true;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
// register a communication window for desktop changes (Matthias)
if (GUIenabled && kde_have_kipc )
{
@@ -1156,7 +1156,7 @@ void TDEApplication::init(bool GUIenabled)
32, PropModeReplace, (unsigned char *)&data, 1);
}
d->oldIceIOErrorHandler = IceSetIOErrorHandler( kde_ice_ioerrorhandler );
-#elif defined(Q_WS_WIN)
+#elif defined(TQ_WS_WIN)
TDEApplication_init_windows(GUIenabled);
#else
// FIXME(E): Implement for Qt Embedded
@@ -1286,7 +1286,7 @@ void TDEApplication::disableSessionManagement() {
void TDEApplication::enableSessionManagement() {
bSessionManagement = true;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
// Session management support in Qt/TDE is awfully broken.
// If konqueror disables session management right after its startup,
// and enables it later (preloading stuff), it won't be properly
@@ -1311,7 +1311,7 @@ void TDEApplication::enableSessionManagement() {
bool TDEApplication::requestShutDown(
ShutdownConfirm confirm, ShutdownType sdtype, ShutdownMode sdmode )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
TQApplication::syncX();
/* use ksmserver's dcop interface if necessary */
if ( confirm == ShutdownConfirmYes ||
@@ -1373,7 +1373,7 @@ bool TDEApplication::requestShutDown(
void TDEApplication::propagateSessionManager()
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
TQCString fName = TQFile::encodeName(locateLocal("socket", "KSMserver"));
TQCString display = ::getenv(DISPLAY);
// strip the screen number from the display
@@ -1482,7 +1482,7 @@ static void checkRestartVersion( TQSessionManager& sm )
void TDEApplication::saveState( TQSessionManager& sm )
{
d->session_save = true;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
static bool firstTime = true;
mySmcConnection = (SmcConn) sm.handle();
@@ -1568,7 +1568,7 @@ bool TDEApplication::sessionSaving() const
void TDEApplication::startKdeinit()
{
-#ifndef Q_WS_WIN //TODO
+#ifndef TQ_WS_WIN //TODO
TDEInstance inst( "starttdeinitlock" );
TDELockFile lock( locateLocal( "tmp", "starttdeinitlock", &inst ));
if( lock.lock( TDELockFile::LockNoBlock ) != TDELockFile::LockOK ) {
@@ -1602,7 +1602,7 @@ void TDEApplication::dcopFailure(const TQString &msg)
}
if (failureCount == 2)
{
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
TDEGlobal::config()->setGroup("General");
if (TDEGlobal::config()->readBoolEntry("ignoreDCOPFailures", false))
return;
@@ -1635,7 +1635,7 @@ void TDEApplication::dcopFailure(const TQString &msg)
static const TDECmdLineOptions qt_options[] =
{
//FIXME: Check if other options are specific to Qt/X11
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
{ "display <displayname>", I18N_NOOP("Use the X-server display 'displayname'"), 0},
#else
{ "display <displayname>", I18N_NOOP("Use the QWS display 'displayname'"), 0},
@@ -1656,13 +1656,13 @@ static const TDECmdLineOptions qt_options[] =
{ "button <color>", I18N_NOOP("sets the default button color"), 0},
{ "name <name>", I18N_NOOP("sets the application name"), 0},
{ "title <title>", I18N_NOOP("sets the application title (caption)"), 0},
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
{ "visual TrueColor", I18N_NOOP("forces the application to use a TrueColor visual on\nan 8-bit display"), 0},
{ "inputstyle <inputstyle>", I18N_NOOP("sets XIM (X Input Method) input style. Possible\nvalues are onthespot, overthespot, offthespot and\nroot"), 0 },
{ "im <XIM server>", I18N_NOOP("set XIM server"),0},
{ "noxim", I18N_NOOP("disable XIM"), 0 },
#endif
-#ifdef Q_WS_QWS
+#ifdef TQ_WS_QWS
{ "qws", I18N_NOOP("forces the application to run as QWS Server"), 0},
#endif
{ "reverse", I18N_NOOP("mirrors the whole layout of widgets"), 0},
@@ -1779,7 +1779,7 @@ void TDEApplication::parseCommandLine( )
TDECrash::setApplicationName(TQString(args->appName()));
}
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if ( args->isSet( "waitforwm" ) ) {
Atom type;
(void) desktop(); // trigger desktop creation, we need PropertyNotify events for the root window
@@ -1874,7 +1874,7 @@ TDEApplication::~TDEApplication()
TDEProcessController::deref();
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if ( d->oldXErrorHandler != NULL )
XSetErrorHandler( d->oldXErrorHandler );
if ( d->oldXIOErrorHandler != NULL )
@@ -1886,7 +1886,7 @@ TDEApplication::~TDEApplication()
delete d;
KApp = 0;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
mySmcConnection = 0;
delete smModificationTime;
smModificationTime = 0;
@@ -1902,7 +1902,7 @@ TDEApplication::~TDEApplication()
}
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
class KAppX11HackWidget: public TQWidget
{
public:
@@ -1910,7 +1910,7 @@ public:
};
#endif
-#if defined(Q_WS_X11) && defined(COMPOSITE)
+#if defined(TQ_WS_X11) && defined(COMPOSITE)
bool TDEApplication::isCompositionManagerAvailable() {
bool have_manager = false;
@@ -2164,7 +2164,7 @@ void TDEApplication::dcopBlockUserInput( bool b )
kapp_block_user_input = b;
}
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
bool TDEApplication::x11EventFilter( XEvent *_event )
{
if ( kapp_block_user_input ) {
@@ -2261,11 +2261,11 @@ bool TDEApplication::x11EventFilter( XEvent *_event )
}
return false;
}
-#endif // Q_WS_X11
+#endif // TQ_WS_X11
void TDEApplication::updateUserTimestamp( unsigned long time )
{
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
Display *display = tqt_xdisplay();
if (!display) {
return;
@@ -2289,7 +2289,7 @@ void TDEApplication::updateUserTimestamp( unsigned long time )
unsigned long TDEApplication::userTimestamp() const
{
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
return get_tqt_x_user_time();
#else
return 0;
@@ -2298,7 +2298,7 @@ unsigned long TDEApplication::userTimestamp() const
void TDEApplication::updateRemoteUserTimestamp( const TQCString& dcopId, unsigned long time )
{
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
if( time == 0 )
time = get_tqt_x_user_time();
DCOPRef( dcopId, "MainApplication-Interface" ).call( "updateUserTimestamp", time );
@@ -2519,7 +2519,7 @@ TQPalette TDEApplication::createApplicationPalette( TDEConfig *config, int contr
void TDEApplication::tdedisplaySetPalette()
{
-#ifdef Q_WS_MACX
+#ifdef TQ_WS_MACX
//Can I have this on other platforms, please!? --Sam
{
TDEConfig *config = TDEGlobal::config();
@@ -2654,7 +2654,7 @@ void TDEApplication::invokeHelp( const TQString& anchor,
return invokeHelp( anchor, _appname, "" );
}
-#ifndef Q_WS_WIN
+#ifndef TQ_WS_WIN
// for win32 we're using simple help tools like Qt Assistant,
// see kapplication_win.cpp
void TDEApplication::invokeHelp( const TQString& anchor,
@@ -2787,7 +2787,7 @@ void TDEApplication::invokeMailer(const TQString &to, const TQString &cc, const
return invokeMailer(to,cc,bcc,subject,body,messageFile,attachURLs,"");
}
-#ifndef Q_WS_WIN
+#ifndef TQ_WS_WIN
// on win32, for invoking browser we're using win32 API
// see kapplication_win.cpp
@@ -3000,7 +3000,7 @@ void TDEApplication::invokeBrowser( const TQString &url )
return invokeBrowser( url, "" );
}
-#ifndef Q_WS_WIN
+#ifndef TQ_WS_WIN
// on win32, for invoking browser we're using win32 API
// see kapplication_win.cpp
void TDEApplication::invokeBrowser( const TQString &url, const TQCString& startup_id )
@@ -3094,7 +3094,7 @@ startServiceInternal( const TQCString &function,
TQByteArray replyData;
TQCString _launcher = TDEApplication::launcher();
TQValueList<TQCString> envs;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if (tqt_xdisplay()) {
TQCString dpystring(XDisplayString(tqt_xdisplay()));
envs.append( TQCString("DISPLAY=") + dpystring );
@@ -3104,7 +3104,7 @@ startServiceInternal( const TQCString &function,
}
#endif
stream << envs;
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
// make sure there is id, so that user timestamp exists
stream << ( startup_id.isEmpty() ? TDEStartupInfo::createNewStartupId() : startup_id );
#endif
@@ -3343,8 +3343,8 @@ void TDEApplication::setTopWidget( TQWidget *topWidget )
// set the specified icons
topWidget->setIcon( icon() ); //standard X11
-#if defined Q_WS_X11
-//#ifdef Q_WS_X11 // FIXME(E): Implement for Qt/Embedded
+#if defined TQ_WS_X11
+//#ifdef TQ_WS_X11 // FIXME(E): Implement for Qt/Embedded
KWin::setIcons(topWidget->winId(), icon(), miniIcon() ); // NET_WM hints for KWin
// set the app startup notification window property
@@ -3361,7 +3361,7 @@ void TDEApplication::setStartupId( const TQCString& startup_id )
{
if( startup_id == d->startup_id )
return;
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
TDEStartupInfo::handleAutoAppStartedSending(); // finish old startup notification if needed
#endif
if( startup_id.isEmpty())
@@ -3369,7 +3369,7 @@ void TDEApplication::setStartupId( const TQCString& startup_id )
else
{
d->startup_id = startup_id;
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
TDEStartupInfoId id;
id.initId( startup_id );
long timestamp = id.timestamp();
@@ -3383,7 +3383,7 @@ void TDEApplication::setStartupId( const TQCString& startup_id )
// not to propagate it to processes started from this app
void TDEApplication::read_app_startup_id()
{
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
TDEStartupInfoId id = TDEStartupInfo::currentStartupIdEnv();
TDEStartupInfo::resetStartupEnv();
d->startup_id = id.id();
@@ -3591,7 +3591,7 @@ bool TDEApplication::authorizeURLAction(const TQString &action, const KURL &_bas
uint TDEApplication::keyboardModifiers()
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
Window root;
Window child;
int root_x, root_y, win_x, win_y;
@@ -3610,13 +3610,13 @@ uint TDEApplication::keyboardModifiers()
uint TDEApplication::mouseState()
{
uint mousestate;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
Window root;
Window child;
int root_x, root_y, win_x, win_y;
XQueryPointer( tqt_xdisplay(), tqt_xrootwin(), &root, &child,
&root_x, &root_y, &win_x, &win_y, &mousestate );
-#elif defined(Q_WS_WIN)
+#elif defined(TQ_WS_WIN)
const bool mousebtn_swapped = GetSystemMetrics(SM_SWAPBUTTON);
if (GetAsyncKeyState(VK_LBUTTON))
mousestate |= (mousebtn_swapped ? Button3Mask : Button1Mask);
@@ -3624,7 +3624,7 @@ uint TDEApplication::mouseState()
mousestate |= Button2Mask;
if (GetAsyncKeyState(VK_RBUTTON))
mousestate |= (mousebtn_swapped ? Button1Mask : Button3Mask);
-#elif defined(Q_WS_MACX)
+#elif defined(TQ_WS_MACX)
mousestate = GetCurrentEventButtonState();
#else
//TODO: other platforms
@@ -3635,7 +3635,7 @@ uint TDEApplication::mouseState()
TQt::ButtonState TDEApplication::keyboardMouseState()
{
int ret = 0;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
Window root;
Window child;
int root_x, root_y, win_x, win_y;
@@ -3657,7 +3657,7 @@ TQt::ButtonState TDEApplication::keyboardMouseState()
ret |= AltButton;
if( state & KKeyNative::modX( KKey::WIN ))
ret |= MetaButton;
-#elif defined(Q_WS_WIN)
+#elif defined(TQ_WS_WIN)
const bool mousebtn_swapped = GetSystemMetrics(SM_SWAPBUTTON);
if (GetAsyncKeyState(VK_LBUTTON))
ret |= (mousebtn_swapped ? RightButton : LeftButton);
@@ -3679,17 +3679,17 @@ TQt::ButtonState TDEApplication::keyboardMouseState()
return static_cast< ButtonState >( ret );
}
-#if defined Q_WS_X11
+#if defined TQ_WS_X11
int TDEApplication::currentX11VT()
{
return get_x_vtnum(TQPaintDevice::x11AppDisplay());
}
-#else // Q_WS_X11
+#else // TQ_WS_X11
int TDEApplication::currentX11VT()
{
return -1;
}
-#endif // Q_WS_X11
+#endif // TQ_WS_X11
void TDEApplication::installSigpipeHandler()
{
diff --git a/tdecore/tdeapplication.h b/tdecore/tdeapplication.h
index 8e5e53ec8..1c1563026 100644
--- a/tdecore/tdeapplication.h
+++ b/tdecore/tdeapplication.h
@@ -33,7 +33,7 @@ class DCOPObject;
#include <tqtglobaldefines.h>
typedef unsigned long Atom;
-#if !defined(Q_WS_X11)
+#if !defined(TQ_WS_X11)
typedef void Display;
#endif
@@ -140,7 +140,7 @@ public:
#endif // TDEAPPLICATION_BINARY_COMPAT_HACK
#endif // Q_QDOC
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
/**
* Constructor. Parses command-line arguments. Use this constructor when you
* you want ARGB support to be automatically detected and enabled.
@@ -935,7 +935,7 @@ public:
*/
TQString checkRecoverFile( const TQString& pFilename, bool& bRecover ) const;
-#if defined(Q_WS_X11)
+#if defined(TQ_WS_X11)
/**
* @internal
* Get the X11 display
@@ -1262,7 +1262,7 @@ protected:
*/
TDEApplication( bool allowStyles, bool GUIenabled, TDEInstance* _instance );
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
/**
* @internal Used by KUniqueApplication
*/
@@ -1352,7 +1352,7 @@ private:
void initUrlActionRestrictions();
bool argb_visual;
-#if defined(Q_WS_X11)
+#if defined(TQ_WS_X11)
TQt::HANDLE argb_x11_visual;
TQt::HANDLE argb_x11_colormap;
#endif
diff --git a/tdecore/tdecmdlineargs.cpp b/tdecore/tdecmdlineargs.cpp
index 68d76f7ff..548fee4dc 100644
--- a/tdecore/tdecmdlineargs.cpp
+++ b/tdecore/tdecmdlineargs.cpp
@@ -43,13 +43,13 @@
#include <kstringhandler.h>
#include <kstaticdeleter.h>
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#define DISPLAY "DISPLAY"
-#elif defined(Q_WS_QWS)
+#elif defined(TQ_WS_QWS)
#define DISPLAY "QWS_DISPLAY"
#endif
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
#include <win32_utils.h>
#endif
@@ -184,7 +184,7 @@ TDECmdLineArgs::init(int _argc, char **_argv, const TDEAboutData *_about, bool n
parsed = false;
mCwd = mCwdd.setObject(mCwd, new char [PATH_MAX+1], true);
(void) getcwd(mCwd, PATH_MAX);
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
win32_slashify(mCwd, PATH_MAX);
#endif
if (!noKApp)
@@ -1099,7 +1099,7 @@ TDECmdLineArgs::setOption(const TQCString &opt, const char *value)
addArgument(arg);
addArgument(value);
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
// Hack coming up!
if (arg == "-display")
{
diff --git a/tdecore/tdeconfigbackend.cpp b/tdecore/tdeconfigbackend.cpp
index 3dd450061..a3e8e2c8f 100644
--- a/tdecore/tdeconfigbackend.cpp
+++ b/tdecore/tdeconfigbackend.cpp
@@ -353,7 +353,7 @@ bool TDEConfigINIBackEnd::parseConfigFiles()
TQStringList tdercs = TDEGlobal::dirs()->
findAllResources("config", TQString::fromLatin1("kdeglobals"));
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
TQString etc_tderc = TQFile::decodeName( TQCString(getenv("WINDIR")) + "\\tderc" );
#else
TQString etc_tderc = TQString::fromLatin1("/etc/tderc");
diff --git a/tdecore/tdeconfigbase.cpp b/tdecore/tdeconfigbase.cpp
index 5d4b7450c..39e491279 100644
--- a/tdecore/tdeconfigbase.cpp
+++ b/tdecore/tdeconfigbase.cpp
@@ -1100,7 +1100,7 @@ void TDEConfigBase::writePathEntry( const TQString& pKey, const TQString & path,
static bool cleanHomeDirPath( TQString &path, const TQString &homeDir )
{
-#ifdef Q_WS_WIN //safer
+#ifdef TQ_WS_WIN //safer
if (!TQDir::convertSeparators(path).startsWith(TQDir::convertSeparators(homeDir)))
return false;
#else
diff --git a/tdecore/tdeglobalsettings.cpp b/tdecore/tdeglobalsettings.cpp
index 82d0cf896..97ef4394c 100644
--- a/tdecore/tdeglobalsettings.cpp
+++ b/tdecore/tdeglobalsettings.cpp
@@ -29,7 +29,7 @@
#include <kipc.h>
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
#include <windows.h>
#include "qt_windows.h"
#include <win32_utils.h>
@@ -54,7 +54,7 @@ static TQRgb qt_colorref2qrgb(COLORREF col)
#include <tqtextstream.h>
#include <tqfile.h>
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#include <X11/Xlib.h>
#endif
@@ -315,7 +315,7 @@ TQColor TDEGlobalSettings::toolBarHighlightColor()
TQColor TDEGlobalSettings::inactiveTitleColor()
{
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
return qt_colorref2qrgb(GetSysColor(COLOR_INACTIVECAPTION));
#else
if (!_inactiveBackground)
@@ -327,7 +327,7 @@ TQColor TDEGlobalSettings::inactiveTitleColor()
TQColor TDEGlobalSettings::inactiveTextColor()
{
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
return qt_colorref2qrgb(GetSysColor(COLOR_INACTIVECAPTIONTEXT));
#else
if (!_inactiveForeground)
@@ -339,7 +339,7 @@ TQColor TDEGlobalSettings::inactiveTextColor()
TQColor TDEGlobalSettings::activeTitleColor()
{
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
return qt_colorref2qrgb(GetSysColor(COLOR_ACTIVECAPTION));
#else
initColors();
@@ -352,7 +352,7 @@ TQColor TDEGlobalSettings::activeTitleColor()
TQColor TDEGlobalSettings::activeTextColor()
{
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
return qt_colorref2qrgb(GetSysColor(COLOR_CAPTIONTEXT));
#else
TDEConfigGroup g( TDEGlobal::config(), "WM" );
@@ -788,7 +788,7 @@ TDEGlobalSettings::KMouseSettings & TDEGlobalSettings::mouseSettings()
s_mouseSettings = new KMouseSettings;
KMouseSettings & s = *s_mouseSettings; // for convenience
-#ifndef Q_WS_WIN
+#ifndef TQ_WS_WIN
TDEConfigGroup g( TDEGlobal::config(), "Mouse" );
TQString setting = g.readEntry("MouseButtonMapping");
if (setting == "RightHanded")
@@ -797,7 +797,7 @@ TDEGlobalSettings::KMouseSettings & TDEGlobalSettings::mouseSettings()
s.handed = KMouseSettings::LeftHanded;
else
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
// get settings from X server
// This is a simplified version of the code in input/mouse.cpp
// Keep in sync !
@@ -822,9 +822,9 @@ TDEGlobalSettings::KMouseSettings & TDEGlobalSettings::mouseSettings()
// FIXME(E): Implement in Qt Embedded
#endif
}
-#endif //Q_WS_WIN
+#endif //TQ_WS_WIN
}
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
//not cached
s_mouseSettings->handed = (GetSystemMetrics(SM_SWAPBUTTON) ? KMouseSettings::LeftHanded : KMouseSettings::RightHanded);
#endif
@@ -833,7 +833,7 @@ TDEGlobalSettings::KMouseSettings & TDEGlobalSettings::mouseSettings()
void TDEGlobalSettings::rereadMouseSettings()
{
-#ifndef Q_WS_WIN
+#ifndef TQ_WS_WIN
delete s_mouseSettings;
s_mouseSettings = 0L;
#endif
@@ -841,7 +841,7 @@ void TDEGlobalSettings::rereadMouseSettings()
bool TDEGlobalSettings::isMultiHead()
{
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
return GetSystemMetrics(SM_CMONITORS) > 1;
#else
TQCString multiHead = getenv("TDE_MULTIHEAD");
diff --git a/tdecore/tdelibs_export.h b/tdecore/tdelibs_export.h
index 7d2ab7db2..9697c6bb4 100644
--- a/tdecore/tdelibs_export.h
+++ b/tdecore/tdelibs_export.h
@@ -26,7 +26,7 @@
/* needed, because e.g. Q_OS_UNIX is so frequently used */
#include <tqglobal.h>
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
#include <tdelibs_export_win.h>
#else /* Q_OS_UNIX */
diff --git a/tdecore/tdelocale.cpp b/tdecore/tdelocale.cpp
index 4565a2efc..3c6dc0cc8 100644
--- a/tdecore/tdelocale.cpp
+++ b/tdecore/tdelocale.cpp
@@ -42,7 +42,7 @@
#include "kcalendarsystemfactory.h"
#include "tdelocale.h"
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
#include <windows.h>
#endif
@@ -72,7 +72,7 @@ public:
KCalendarSystem * calendar;
bool utf8FileEncoding;
TQString appName;
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
char win32SystemEncoding[3+7]; //"cp " + lang ID
#endif
bool useMainCatalogue;
@@ -2264,7 +2264,7 @@ TQString TDELocale::defaultCountry()
const char * TDELocale::encoding() const
{
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
if (0==qstrcmp("System", codecForEncoding()->name()))
{
//win32 returns "System" codec name here but KDE apps expect a real name:
diff --git a/tdecore/tdestartupinfo.cpp b/tdecore/tdestartupinfo.cpp
index edcb27831..22f2b0bc6 100644
--- a/tdecore/tdestartupinfo.cpp
+++ b/tdecore/tdestartupinfo.cpp
@@ -33,8 +33,8 @@ DEALINGS IN THE SOFTWARE.
#include <tqwidget.h>
#include "config.h"
-#ifdef Q_WS_X11
-//#ifdef Q_WS_X11 // FIXME(E): Re-implement in a less X11 specific way
+#ifdef TQ_WS_X11
+//#ifdef TQ_WS_X11 // FIXME(E): Re-implement in a less X11 specific way
#include <tqglobal.h>
#ifdef HAVE_CONFIG_H
#include <config.h>
@@ -46,13 +46,13 @@ DEALINGS IN THE SOFTWARE.
#include <sys/time.h>
#include <stdlib.h>
#include <tqtimer.h>
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#include <netwm.h>
#endif
#include <kdebug.h>
#include <tdeapplication.h>
#include <signal.h>
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#include <twinmodule.h>
#include <kxmessages.h>
#include <twin.h>
@@ -93,7 +93,7 @@ struct TDEStartupInfoPrivate
TQMap< TDEStartupInfoId, TDEStartupInfo::Data > silent_startups;
// contains ASN's that had change: but no new: yet
TQMap< TDEStartupInfoId, TDEStartupInfo::Data > uninited_startups;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
KWinModule* wm_module;
KXMessages msgs;
#endif
@@ -101,7 +101,7 @@ struct TDEStartupInfoPrivate
int flags;
TDEStartupInfoPrivate( int flags_P )
:
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
msgs( NET_STARTUP_MSG, NULL, false ),
#endif
flags( flags_P ) {}
@@ -130,7 +130,7 @@ void TDEStartupInfo::init( int flags_P )
return;
d = new TDEStartupInfoPrivate( flags_P );
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if( !( d->flags & DisableKWinModule ))
{
d->wm_module = new KWinModule( this );
@@ -505,7 +505,7 @@ void TDEStartupInfo::appStarted( const TQCString& startup_id )
TDEStartupInfo::sendFinish( id );
else if( getenv( "DISPLAY" ) != NULL ) // don't rely on tqt_xdisplay()
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
Display* disp = XOpenDisplay( NULL );
if( disp != NULL )
{
@@ -612,7 +612,7 @@ TDEStartupInfo::startup_t TDEStartupInfo::check_startup_internal( WId w_P, TDESt
}
return find_id( id, id_O, data_O ) ? Match : NoMatch;
}
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETWinInfo info( tqt_xdisplay(), w_P, tqt_xrootwin(),
NET::WMWindowType | NET::WMPid | NET::WMState );
pid_t pid = info.pid();
@@ -729,7 +729,7 @@ bool TDEStartupInfo::find_wclass( TQCString res_name, TQCString res_class,
return false;
}
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
static Atom net_startup_atom = None;
static TQCString read_startup_id_property( WId w_P )
@@ -755,7 +755,7 @@ static TQCString read_startup_id_property( WId w_P )
TQCString TDEStartupInfo::windowStartupId( WId w_P )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if( net_startup_atom == None )
net_startup_atom = XInternAtom( tqt_xdisplay(), NET_STARTUP_WINDOW, False );
if( utf8_string_atom == None )
@@ -777,7 +777,7 @@ TQCString TDEStartupInfo::windowStartupId( WId w_P )
void TDEStartupInfo::setWindowStartupId( WId w_P, const TQCString& id_P )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if( id_P.isNull())
return;
if( net_startup_atom == None )
@@ -791,7 +791,7 @@ void TDEStartupInfo::setWindowStartupId( WId w_P, const TQCString& id_P )
TQCString TDEStartupInfo::get_window_hostname( WId w_P )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
XTextProperty tp;
char** hh;
int cnt;
diff --git a/tdecore/tdestartupinfo.h b/tdecore/tdestartupinfo.h
index 248b4810b..dcbe599d1 100644
--- a/tdecore/tdestartupinfo.h
+++ b/tdecore/tdestartupinfo.h
@@ -28,7 +28,7 @@ DEALINGS IN THE SOFTWARE.
#include <sys/types.h>
#include <tqobject.h>
-#ifdef Q_WS_X11 // FIXME(E): Redo in a less X11-specific way
+#ifdef TQ_WS_X11 // FIXME(E): Redo in a less X11-specific way
#include <tqcstring.h>
#include <tqstring.h>
@@ -688,6 +688,6 @@ class TDECORE_EXPORT TDEStartupInfoData
TDEStartupInfoDataPrivate* d;
};
-#endif //Q_WS_X11
+#endif //TQ_WS_X11
#endif
diff --git a/tdecore/twin.cpp b/tdecore/twin.cpp
index fc6358351..5486a2828 100644
--- a/tdecore/twin.cpp
+++ b/tdecore/twin.cpp
@@ -45,7 +45,7 @@
#include <tdelocale.h>
#include <dcopclient.h>
#include <dcopref.h>
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#include <tdestartupinfo.h>
#include <kxerrorhandler.h>
@@ -103,7 +103,7 @@ static void twin_net_create_atoms() {
/*
Sends a client message to the ROOT window.
*/
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
static void sendClientMessageToRoot(Window w, Atom a, long x, long y = 0, long z = 0 ){
XEvent ev;
long mask;
@@ -124,7 +124,7 @@ static void sendClientMessageToRoot(Window w, Atom a, long x, long y = 0, long z
/*
Send a client message to window w
*/
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
static void sendClientMessage(Window w, Atom a, long x){
XEvent ev;
long mask;
@@ -145,7 +145,7 @@ static void sendClientMessage(Window w, Atom a, long x){
bool KWin::compositingActive()
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
twin_net_create_atoms();
return XGetSelectionOwner( tqt_xdisplay(), net_wm_cm ) != None;
#else
@@ -153,7 +153,7 @@ bool KWin::compositingActive()
#endif
}
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
namespace
{
class ContextWidget : public TQWidget
@@ -213,14 +213,14 @@ bool ContextWidget::x11Event( XEvent * ev)
void KWin::invokeContextHelp()
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
ContextWidget w;
#endif
}
void KWin::setSystemTrayWindowFor( WId trayWin, WId forWin )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETWinInfo info( tqt_xdisplay(), trayWin, tqt_xrootwin(), 0 );
if ( !forWin )
forWin = tqt_xrootwin();
@@ -236,30 +236,30 @@ void KWin::setSystemTrayWindowFor( WId trayWin, WId forWin )
void KWin::activateWindow( WId win, long time )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETRootInfo info( tqt_xdisplay(), 0 );
if( time == 0 )
time = get_tqt_x_user_time();
info.setActiveWindow( win, NET::FromApplication, time,
kapp->activeWindow() ? kapp->activeWindow()->winId() : 0 );
-#endif // Q_WS_X11 ...
+#endif // TQ_WS_X11 ...
KUniqueApplication::setHandleAutoStarted();
}
void KWin::forceActiveWindow( WId win, long time )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETRootInfo info( tqt_xdisplay(), 0 );
if( time == 0 )
time = get_tqt_x_time();
info.setActiveWindow( win, NET::FromTool, time, 0 );
-#endif // Q_WS_X11
+#endif // TQ_WS_X11
KUniqueApplication::setHandleAutoStarted();
}
void KWin::setActiveWindow( WId win )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETRootInfo info( tqt_xdisplay(), 0 );
info.setActiveWindow( win, NET::FromUnknown, 0, 0 );
#endif
@@ -268,7 +268,7 @@ void KWin::setActiveWindow( WId win )
void KWin::demandAttention( WId win, bool set )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETWinInfo info( tqt_xdisplay(), win, tqt_xrootwin(), 0 );
info.setState( set ? NET::DemandsAttention : 0, NET::DemandsAttention );
#endif
@@ -276,7 +276,7 @@ void KWin::demandAttention( WId win, bool set )
void KWin::setUserTime( WId win, long time )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETWinInfo info( tqt_xdisplay(), win, tqt_xrootwin(), 0 );
info.setUserTime( time );
#endif
@@ -290,7 +290,7 @@ KWin::WindowInfo KWin::windowInfo( WId win, unsigned long properties, unsigned l
WId KWin::transientFor( WId win )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
KXErrorHandler handler; // ignore badwindow
Window transient_for = None;
if( XGetTransientForHint( tqt_xdisplay(), win, &transient_for ))
@@ -304,7 +304,7 @@ WId KWin::transientFor( WId win )
void KWin::setMainWindow( TQWidget* subwindow, WId mainwindow )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if( mainwindow != 0 )
{
/*
@@ -326,7 +326,7 @@ void KWin::setMainWindow( TQWidget* subwindow, WId mainwindow )
WId KWin::groupLeader( WId win )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
KXErrorHandler handler; // ignore badwindow
XWMHints *hints = XGetWMHints( tqt_xdisplay(), win );
Window window_group = None;
@@ -347,7 +347,7 @@ WId KWin::groupLeader( WId win )
KWin::Info KWin::info( WId win )
{
Info w;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETWinInfo inf( tqt_xdisplay(), win, tqt_xrootwin(),
NET::WMState |
NET::WMStrut |
@@ -398,11 +398,11 @@ TQPixmap KWin::icon( WId win, int width, int height, bool scale )
TQPixmap KWin::icon( WId win, int width, int height, bool scale, int flags )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
KXErrorHandler handler; // ignore badwindow
#endif
TQPixmap result;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if( flags & NETWM ) {
NETWinInfo info( tqt_xdisplay(), win, tqt_xrootwin(), NET::WMIcon );
NETIcon ni = info.icon( width, height );
@@ -514,7 +514,7 @@ TQPixmap KWin::icon( WId win, int width, int height, bool scale, int flags )
void KWin::setIcons( WId win, const TQPixmap& icon, const TQPixmap& miniIcon )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if ( icon.isNull() )
return;
NETWinInfo info( tqt_xdisplay(), win, tqt_xrootwin(), 0 );
@@ -536,7 +536,7 @@ void KWin::setIcons( WId win, const TQPixmap& icon, const TQPixmap& miniIcon )
void KWin::setType( WId win, NET::WindowType windowType )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETWinInfo info( tqt_xdisplay(), win, tqt_xrootwin(), 0 );
info.setWindowType( windowType );
#endif
@@ -544,7 +544,7 @@ void KWin::setType( WId win, NET::WindowType windowType )
void KWin::setState( WId win, unsigned long state )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETWinInfo info( tqt_xdisplay(), win, tqt_xrootwin(), NET::WMState );
info.setState( state, state );
#endif
@@ -552,7 +552,7 @@ void KWin::setState( WId win, unsigned long state )
void KWin::clearState( WId win, unsigned long state )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETWinInfo info( tqt_xdisplay(), win, tqt_xrootwin(), NET::WMState );
info.setState( 0, state );
#endif
@@ -560,7 +560,7 @@ void KWin::clearState( WId win, unsigned long state )
void KWin::setOpacity( WId win, uint percent )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
twin_net_create_atoms();
if (percent > 99)
XDeleteProperty (tqt_xdisplay(), win, kde_wm_window_opacity);
@@ -574,7 +574,7 @@ void KWin::setOpacity( WId win, uint percent )
void KWin::setShadowSize( WId win, uint percent )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
twin_net_create_atoms();
long shadowSize = long(0xFFFFFFFF/100.0*percent);
XChangeProperty(tqt_xdisplay(), win, kde_wm_window_shadow, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &shadowSize, 1L);
@@ -583,7 +583,7 @@ void KWin::setShadowSize( WId win, uint percent )
void KWin::setOnAllDesktops( WId win, bool b )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETWinInfo info( tqt_xdisplay(), win, tqt_xrootwin(), NET::WMDesktop );
if ( b )
info.setDesktop( NETWinInfo::OnAllDesktops );
@@ -596,7 +596,7 @@ void KWin::setOnAllDesktops( WId win, bool b )
void KWin::setOnDesktop( WId win, int desktop )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETWinInfo info( tqt_xdisplay(), win, tqt_xrootwin(), NET::WMDesktop );
info.setDesktop( desktop );
#endif
@@ -606,7 +606,7 @@ void KWin::setExtendedStrut( WId win, int left_width, int left_start, int left_e
int right_width, int right_start, int right_end, int top_width, int top_start, int top_end,
int bottom_width, int bottom_start, int bottom_end )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETWinInfo info( tqt_xdisplay(), win, tqt_xrootwin(), 0 );
NETExtendedStrut strut;
strut.left_width = left_width;
@@ -627,7 +627,7 @@ void KWin::setExtendedStrut( WId win, int left_width, int left_start, int left_e
void KWin::setStrut( WId win, int left, int right, int top, int bottom )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETWinInfo info( tqt_xdisplay(), win, tqt_xrootwin(), 0 );
NETStrut strut;
strut.left = left;
@@ -640,11 +640,11 @@ void KWin::setStrut( WId win, int left, int right, int top, int bottom )
int KWin::currentDesktop()
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if (!tqt_xdisplay())
#endif
return 1;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETRootInfo info( tqt_xdisplay(), NET::CurrentDesktop );
return info.currentDesktop();
#endif
@@ -652,11 +652,11 @@ int KWin::currentDesktop()
int KWin::numberOfDesktops()
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if (!tqt_xdisplay())
#endif
return 0;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETRootInfo info( tqt_xdisplay(), NET::NumberOfDesktops );
return info.numberOfDesktops();
#endif
@@ -664,7 +664,7 @@ int KWin::numberOfDesktops()
void KWin::setCurrentDesktop( int desktop )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETRootInfo info( tqt_xdisplay(), NET::CurrentDesktop );
info.setCurrentDesktop( desktop );
#endif
@@ -672,7 +672,7 @@ void KWin::setCurrentDesktop( int desktop )
void KWin::setCurrentDesktopViewport( int desktop, TQPoint viewport )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETRootInfo info( tqt_xdisplay(), NET::CurrentDesktop );
NETPoint netview;
netview.x = viewport.x();
@@ -683,7 +683,7 @@ void KWin::setCurrentDesktopViewport( int desktop, TQPoint viewport )
void KWin::iconifyWindow( WId win, bool animation)
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if ( !animation )
{
twin_net_create_atoms();
@@ -696,7 +696,7 @@ void KWin::iconifyWindow( WId win, bool animation)
void KWin::deIconifyWindow( WId win, bool animation )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if ( !animation )
{
twin_net_create_atoms();
@@ -708,7 +708,7 @@ void KWin::deIconifyWindow( WId win, bool animation )
void KWin::raiseWindow( WId win )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETRootInfo info( tqt_xdisplay(), NET::Supported );
if( info.isSupported( NET::WM2RestackWindow ))
info.restackRequest( win, None, Above );
@@ -719,7 +719,7 @@ void KWin::raiseWindow( WId win )
void KWin::lowerWindow( WId win )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
NETRootInfo info( tqt_xdisplay(), NET::Supported );
if( info.isSupported( NET::WM2RestackWindow ))
info.restackRequest( win, None, Below );
@@ -730,7 +730,7 @@ void KWin::lowerWindow( WId win )
void KWin::appStarted()
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
TDEStartupInfo::appStarted();
#endif
}
@@ -739,11 +739,11 @@ class KWin::WindowInfoPrivate
{
public:
WindowInfoPrivate()
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
: info( NULL )
#endif
{}
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
~WindowInfoPrivate() { delete info; }
NETWinInfo* info;
#endif
@@ -762,7 +762,7 @@ class KWin::WindowInfoPrivate
// KWin::info() should be updated too if something has to be changed here
KWin::WindowInfo::WindowInfo( WId win, unsigned long properties, unsigned long properties2 )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
KXErrorHandler handler;
d = new WindowInfoPrivate;
d->ref = 1;
@@ -862,7 +862,7 @@ WId KWin::WindowInfo::win() const
unsigned long KWin::WindowInfo::state() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS ] & NET::WMState ) == 0, 176 )
<< "Pass NET::WMState to KWin::windowInfo()" << endl;
return d->info->state();
@@ -873,7 +873,7 @@ unsigned long KWin::WindowInfo::state() const
NET::MappingState KWin::WindowInfo::mappingState() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS ] & NET::XAWMState ) == 0, 176 )
<< "Pass NET::XAWMState to KWin::windowInfo()" << endl;
return d->info->mappingState();
@@ -884,7 +884,7 @@ NET::MappingState KWin::WindowInfo::mappingState() const
NETExtendedStrut KWin::WindowInfo::extendedStrut() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS2 ] & NET::WM2ExtendedStrut ) == 0, 176 )
<< "Pass NET::WM2ExtendedStrut to second argument of KWin::windowInfo()" << endl;
NETExtendedStrut ext = d->info->extendedStrut();
@@ -922,7 +922,7 @@ NETExtendedStrut KWin::WindowInfo::extendedStrut() const
NETStrut KWin::WindowInfo::strut() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS ] & NET::WMStrut ) == 0, 176 )
<< "Pass NET::WMStrut to KWin::windowInfo()" << endl;
return d->info->strut();
@@ -934,7 +934,7 @@ NETStrut KWin::WindowInfo::strut() const
NET::WindowType KWin::WindowInfo::windowType( int supported_types ) const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS ] & NET::WMWindowType ) == 0, 176 )
<< "Pass NET::WMWindowType to KWin::windowInfo()" << endl;
return d->info->windowType( supported_types );
@@ -965,7 +965,7 @@ TQString KWin::Info::visibleNameWithState() const
TQString KWin::WindowInfo::visibleName() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS ] & NET::WMVisibleName ) == 0, 176 )
<< "Pass NET::WMVisibleName to KWin::windowInfo()" << endl;
return d->info->visibleName() && d->info->visibleName()[ 0 ] != '\0'
@@ -977,7 +977,7 @@ TQString KWin::WindowInfo::visibleName() const
TQString KWin::WindowInfo::name() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS ] & NET::WMName ) == 0, 176 )
<< "Pass NET::WMName to KWin::windowInfo()" << endl;
return d->name_;
@@ -998,7 +998,7 @@ TQString KWin::WindowInfo::visibleIconNameWithState() const
TQString KWin::WindowInfo::visibleIconName() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS ] & NET::WMVisibleIconName ) == 0, 176 )
<< "Pass NET::WMVisibleIconName to KWin::windowInfo()" << endl;
if( d->info->visibleIconName() && d->info->visibleIconName()[ 0 ] != '\0' )
@@ -1013,7 +1013,7 @@ TQString KWin::WindowInfo::visibleIconName() const
TQString KWin::WindowInfo::iconName() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS ] & NET::WMIconName ) == 0, 176 )
<< "Pass NET::WMIconName to KWin::windowInfo()" << endl;
if( d->info->iconName() && d->info->iconName()[ 0 ] != '\0' )
@@ -1026,7 +1026,7 @@ TQString KWin::WindowInfo::iconName() const
bool KWin::WindowInfo::isOnCurrentDesktop() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
return isOnDesktop( KWin::currentDesktop());
#else
return false;
@@ -1035,7 +1035,7 @@ bool KWin::WindowInfo::isOnCurrentDesktop() const
bool KWin::WindowInfo::isOnDesktop( int desktop ) const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS ] & NET::WMDesktop ) == 0, 176 )
<< "Pass NET::WMDesktop to KWin::windowInfo()" << endl;
return d->info->desktop() == desktop || d->info->desktop() == NET::OnAllDesktops;
@@ -1046,7 +1046,7 @@ bool KWin::WindowInfo::isOnDesktop( int desktop ) const
bool KWin::WindowInfo::onAllDesktops() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS ] & NET::WMDesktop ) == 0, 176 )
<< "Pass NET::WMDesktop to KWin::windowInfo()" << endl;
return d->info->desktop() == NET::OnAllDesktops;
@@ -1057,7 +1057,7 @@ bool KWin::WindowInfo::onAllDesktops() const
int KWin::WindowInfo::desktop() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS ] & NET::WMDesktop ) == 0, 176 )
<< "Pass NET::WMDesktop to KWin::windowInfo()" << endl;
return d->info->desktop();
@@ -1068,7 +1068,7 @@ int KWin::WindowInfo::desktop() const
TQRect KWin::WindowInfo::geometry() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS ] & NET::WMGeometry ) == 0, 176 )
<< "Pass NET::WMGeometry to KWin::windowInfo()" << endl;
return d->geometry_;
@@ -1079,7 +1079,7 @@ TQRect KWin::WindowInfo::geometry() const
TQRect KWin::WindowInfo::frameGeometry() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS ] & NET::WMKDEFrameStrut ) == 0, 176 )
<< "Pass NET::WMKDEFrameStrut to KWin::windowInfo()" << endl;
return d->frame_geometry_;
@@ -1090,7 +1090,7 @@ TQRect KWin::WindowInfo::frameGeometry() const
WId KWin::WindowInfo::transientFor() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS2 ] & NET::WM2TransientFor ) == 0, 176 )
<< "Pass NET::WM2TransientFor to KWin::windowInfo()" << endl;
return d->info->transientFor();
@@ -1101,7 +1101,7 @@ WId KWin::WindowInfo::transientFor() const
WId KWin::WindowInfo::groupLeader() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS2 ] & NET::WM2GroupLeader ) == 0, 176 )
<< "Pass NET::WM2GroupLeader to KWin::windowInfo()" << endl;
return d->info->groupLeader();
@@ -1112,7 +1112,7 @@ WId KWin::WindowInfo::groupLeader() const
TQCString KWin::WindowInfo::windowClassClass() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS2 ] & NET::WM2WindowClass ) == 0, 176 )
<< "Pass NET::WM2WindowClass to KWin::windowInfo()" << endl;
return d->info->windowClassClass();
@@ -1123,7 +1123,7 @@ TQCString KWin::WindowInfo::windowClassClass() const
TQCString KWin::WindowInfo::windowClassName() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS2 ] & NET::WM2WindowClass ) == 0, 176 )
<< "Pass NET::WM2WindowClass to KWin::windowInfo()" << endl;
return d->info->windowClassName();
@@ -1134,7 +1134,7 @@ TQCString KWin::WindowInfo::windowClassName() const
TQCString KWin::WindowInfo::windowRole() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS2 ] & NET::WM2WindowRole ) == 0, 176 )
<< "Pass NET::WM2WindowRole to KWin::windowInfo()" << endl;
return d->info->windowRole();
@@ -1145,7 +1145,7 @@ TQCString KWin::WindowInfo::windowRole() const
TQCString KWin::WindowInfo::clientMachine() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS2 ] & NET::WM2ClientMachine ) == 0, 176 )
<< "Pass NET::WM2ClientMachine to KWin::windowInfo()" << endl;
return d->info->clientMachine();
@@ -1156,7 +1156,7 @@ TQCString KWin::WindowInfo::clientMachine() const
bool KWin::WindowInfo::actionSupported( NET::Action action ) const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
kdWarning(( d->info->passedProperties()[ NETWinInfo::PROTOCOLS2 ] & NET::WM2AllowedActions ) == 0, 176 )
<< "Pass NET::WM2AllowedActions to KWin::windowInfo()" << endl;
if( allowedActionsSupported())
@@ -1169,7 +1169,7 @@ bool KWin::WindowInfo::actionSupported( NET::Action action ) const
// see NETWM spec section 7.6
bool KWin::WindowInfo::isMinimized() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if( mappingState() != NET::Iconic )
return false;
// NETWM 1.2 compliant WM - uses NET::Hidden for minimized windows
@@ -1186,7 +1186,7 @@ bool KWin::WindowInfo::isMinimized() const
bool KWin::Info::isMinimized() const
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if( mappingState != NET::Iconic )
return false;
// NETWM 1.2 compliant WM - uses NET::Hidden for minimized windows
@@ -1208,7 +1208,7 @@ bool KWin::Info::isIconified() const
bool KWin::icccmCompliantMappingState()
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
static enum { noidea, yes, no } wm_is_1_2_compliant = noidea;
if( wm_is_1_2_compliant == noidea ) {
NETRootInfo info( tqt_xdisplay(), NET::Supported );
@@ -1222,7 +1222,7 @@ bool KWin::icccmCompliantMappingState()
bool KWin::allowedActionsSupported()
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
static enum { noidea, yes, no } wm_supports_allowed_actions = noidea;
if( wm_supports_allowed_actions == noidea ) {
NETRootInfo info( tqt_xdisplay(), NET::Supported );
@@ -1236,13 +1236,13 @@ bool KWin::allowedActionsSupported()
TQString KWin::readNameProperty( WId win, unsigned long atom )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
XTextProperty tp;
char **text = NULL;
int count;
#endif
TQString result;
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if ( XGetTextProperty( tqt_xdisplay(), win, &tp, atom ) != 0 && tp.value != NULL )
{
if (!twin_UTF8_STRING)
diff --git a/tdecore/twinmodule.cpp b/tdecore/twinmodule.cpp
index 7eafa34d7..fc1a37574 100644
--- a/tdecore/twinmodule.cpp
+++ b/tdecore/twinmodule.cpp
@@ -22,7 +22,7 @@
*/
#include <tqwidget.h>
-#ifdef Q_WS_X11 //FIXME
+#ifdef TQ_WS_X11 //FIXME
#include "twinmodule.h"
#include "twin.h"
#include <X11/Xatom.h>