diff options
author | Michele Calgaro <michele.calgaro@yahoo.it> | 2023-09-12 21:15:32 +0900 |
---|---|---|
committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2023-09-12 21:15:32 +0900 |
commit | 0f36f8966371d24decc0740ccf9f8b0cc2c57838 (patch) | |
tree | 13adb17728b88c3e7bdcc83fd2c2a131939f7770 /tdecore/tdeapplication.cpp | |
parent | cc5cf548f13ee0c43c41ac60ad056765e7dccb26 (diff) | |
download | tdelibs-0f36f8966371d24decc0740ccf9f8b0cc2c57838.tar.gz tdelibs-0f36f8966371d24decc0740ccf9f8b0cc2c57838.zip |
Replace various tqtinterface's TQ_* defines with actual types
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'tdecore/tdeapplication.cpp')
-rw-r--r-- | tdecore/tdeapplication.cpp | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/tdecore/tdeapplication.cpp b/tdecore/tdeapplication.cpp index dbed066e3..d3ff5bcb2 100644 --- a/tdecore/tdeapplication.cpp +++ b/tdecore/tdeapplication.cpp @@ -3632,7 +3632,7 @@ uint TDEApplication::mouseState() return mousestate & 0xff00; } -TQ_ButtonState TDEApplication::keyboardMouseState() +Qt::ButtonState TDEApplication::keyboardMouseState() { int ret = 0; #ifdef Q_WS_X11 @@ -3644,35 +3644,35 @@ TQ_ButtonState TDEApplication::keyboardMouseState() &root_x, &root_y, &win_x, &win_y, &state ); // transform the same way like Qt's qt_x11_translateButtonState() if( state & Button1Mask ) - ret |= TQ_LeftButton; + ret |= LeftButton; if( state & Button2Mask ) - ret |= TQ_MidButton; + ret |= MidButton; if( state & Button3Mask ) - ret |= TQ_RightButton; + ret |= RightButton; if( state & ShiftMask ) - ret |= TQ_ShiftButton; + ret |= ShiftButton; if( state & ControlMask ) - ret |= TQ_ControlButton; + ret |= ControlButton; if( state & KKeyNative::modX( KKey::ALT )) - ret |= TQ_AltButton; + ret |= AltButton; if( state & KKeyNative::modX( KKey::WIN )) - ret |= TQ_MetaButton; + ret |= MetaButton; #elif defined(Q_WS_WIN) const bool mousebtn_swapped = GetSystemMetrics(SM_SWAPBUTTON); if (GetAsyncKeyState(VK_LBUTTON)) ret |= (mousebtn_swapped ? RightButton : LeftButton); if (GetAsyncKeyState(VK_MBUTTON)) - ret |= TQ_MidButton; + ret |= MidButton; if (GetAsyncKeyState(VK_RBUTTON)) - ret |= (mousebtn_swapped ? TQ_LeftButton : TQ_RightButton); + ret |= (mousebtn_swapped ? LeftButton : RightButton); if (GetAsyncKeyState(VK_SHIFT)) - ret |= TQ_ShiftButton; + ret |= ShiftButton; if (GetAsyncKeyState(VK_CONTROL)) - ret |= TQ_ControlButton; + ret |= ControlButton; if (GetAsyncKeyState(VK_MENU)) - ret |= TQ_AltButton; + ret |= AltButton; if (GetAsyncKeyState(VK_LWIN) || GetAsyncKeyState(VK_RWIN)) - ret |= TQ_MetaButton; + ret |= MetaButton; #else //TODO: other platforms #endif |