Tomas Carnecky wrote:
So.. now that the cause is known, what would be the right solution? Do
you still think it's the WMs fault? Or should wine be changed?
The patch in the attachment removes update_key_state() from mouse.c -
the decision whether this is the right approach or not is left to
someone else. If you think it's worth a try to send this patch to
wine-patches, please do so, I'll have to continue using a custom
patchset anyway since the app I want to run doesn't work on vanilla
wine, so I don't heave really a strong interest in getting this patch
accepted.
Getting patches accepted was quite hard for me, and that was because
lack of feedback. It leads to nowhere if I submit the very same patch
more than twice, and without feedback I can't improve it. So, my two
patches (one for alsa/dsound and this for the stuck keys) will remain
public domain and free for everyone to use, and if you feel like it, to
improve and send back to wine for inclusion.
I'll (more or less) retire from writing patches. But of course if I come
up with a fix for something that I think is worth sharing, I'll let you
guys know ;)
tom
e4a76b49921e3af8095baadace976143af05160d
diff --git a/dlls/winex11.drv/mouse.c b/dlls/winex11.drv/mouse.c
index 5ac714c..4d4a83a 100644
--- a/dlls/winex11.drv/mouse.c
+++ b/dlls/winex11.drv/mouse.c
@@ -103,18 +103,6 @@ static inline void update_button_state(
/***********************************************************************
- * update_key_state
- *
- * Update the key state with what X provides us
- */
-static inline void update_key_state( unsigned int state )
-{
- key_state_table[VK_SHIFT] = (state & ShiftMask ? 0x80 : 0);
- key_state_table[VK_CONTROL] = (state & ControlMask ? 0x80 : 0);
-}
-
-
-/***********************************************************************
* update_mouse_state
*
* Update the various window states on a mouse event.
@@ -124,7 +112,6 @@ static void update_mouse_state( HWND hwn
struct x11drv_thread_data *data = x11drv_thread_data();
get_coords( hwnd, x, y, pt );
- update_key_state( state );
/* update the cursor */
@@ -712,7 +699,6 @@ BOOL X11DRV_GetCursorPos(LPPOINT pos)
if (XQueryPointer( display, root_window, &root, &child,
&rootX, &rootY, &winX, &winY, &xstate ))
{
- update_key_state( xstate );
update_button_state( xstate );
TRACE("pointer at (%d,%d)\n", winX, winY );
cursor_pos.x = winX;