http://bugs.winehq.org/show_bug.cgi?id=12005
John Klehm xixsimplicityxix@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Attachment #12402|0 |1 is obsolete| |
--- Comment #25 from John Klehm xixsimplicityxix@gmail.com 2008-05-14 04:03:04 --- Created an attachment (id=13046) --> (http://bugs.winehq.org/attachment.cgi?id=13046) Support wintab compatibility mode for less than 3 cursors
This is the correct fix for the improper enumeration of cursors that I discovered before. We now avoid copying uninitialized data and will now always properly report the correct amount of cursors needed to make programs work.
What we did before in the case of 1 cursor (wizard pen) was this. 1 cursor is detected and placed in system slot 0 and number of system cursors is 1. Older programs expect main cursor to be in system slot 1. So we swap slots 1 and 0. For wacom this is fine but for 1 cursor tablets this is not right as now we have uninitialized data in slot 0 (which is harmless in this case) and the actual data is out of range of the number of system cursors (gNumCursors) which is used to keep track of appropriate indexing of the system cursor slots.
What we do now is clone a cursor instead of swap if there arent enough cursors to swap with and then increment gNumCursors to reflect the cloned data. This is a wintab facing modification so X11 behaviour should not be adversly affected.
It should allow wintab apps to find single cursor tablets.
Let me know how it goes :D