From 03aa7238b34bb438632b6d572b008e32960f0895 Mon Sep 17 00:00:00 2001 From: Michele Calgaro Date: Tue, 13 Feb 2024 11:10:37 +0900 Subject: Replace Q_WS_* defines with TQ_WS_* equivalents Signed-off-by: Michele Calgaro --- tdecore/tdeapplication.cpp | 164 ++++++++++++++++++++++----------------------- 1 file changed, 82 insertions(+), 82 deletions(-) (limited to 'tdecore/tdeapplication.cpp') 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 #include -#if defined Q_WS_X11 +#if defined TQ_WS_X11 #include #endif @@ -110,7 +110,7 @@ #include #include -#ifndef Q_WS_WIN +#ifndef TQ_WS_WIN #include "twin.h" #endif @@ -123,8 +123,8 @@ #include #include #include -#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 #endif @@ -134,7 +134,7 @@ #include #endif -#ifdef Q_WS_X11 +#ifdef TQ_WS_X11 #include #ifdef COMPOSITE #include @@ -149,7 +149,7 @@ #include -#ifndef Q_WS_WIN +#ifndef TQ_WS_WIN #include #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 #endif -#ifdef Q_WS_MACX +#ifdef TQ_WS_MACX #include #include #endif -#if defined Q_WS_X11 +#if defined TQ_WS_X11 #include #ifdef __linux__ #include @@ -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; -#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( receiver ); -#if defined Q_WS_X11 +#if defined TQ_WS_X11 if( w->isTopLevel() && !startupId().isEmpty() && !static_cast(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 ", I18N_NOOP("Use the X-server display 'displayname'"), 0}, #else { "display ", I18N_NOOP("Use the QWS display 'displayname'"), 0}, @@ -1656,13 +1656,13 @@ static const TDECmdLineOptions qt_options[] = { "button ", I18N_NOOP("sets the default button color"), 0}, { "name ", I18N_NOOP("sets the application name"), 0}, { "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() { -- cgit v1.2.3