Page MenuHome

fix shift button for input devices (tablets)
Needs RevisionPublic

Authored by dan grauer (kromar) on Thu, Dec 27, 10:41 AM.

Details

Summary

some input devices like huion tablets do not recognize the shift button. this change fixes that issue.

I have tested this only on PC so far, so if someone could test this on a mac would be great.

OS: windows 10 64bit
Devices Tested:

Wacom Intuos Pro (5th generation)
Huion H950P
Huion Camvas 13 pro
PC Keyboard (US layout)

Diff Detail

Repository
rB Blender

Event Timeline

dan grauer (kromar) edited the summary of this revision. (Show Details)Thu, Dec 27, 10:48 AM
Brecht Van Lommel (brecht) requested changes to this revision.Thu, Dec 27, 10:59 AM

It appears to use these special scancode checks to fix an issue with shift + numpad:
T29932: Left Shift + Numpad 1,2,3 not Aligning to Active
rB70de23dabb17: Fix #29932 Left Shift + Numpad 1,2,3 not Aligning to Active

Does the bug in that report return after these changes? If so, is there a way to solve both issues?

intern/ghost/GHOST_Types.h
309

The changes in this file seem unnecessary?

This revision now requires changes to proceed.Thu, Dec 27, 10:59 AM
dan grauer (kromar) added a comment.EditedThu, Dec 27, 11:34 AM

it seems that its back, well no wonder since i basically removed the "fix" for that. thanks for pointing that out, i will see if i can find a different solution that works with both scenarios.

I think i opend pandoras box of keyboard trickery:O
Im reading up on how the keyboard modifiers work and so far it looks like the keys can be identified with the raw input and the pressed state so the unknown key should not be needed. I will try to come up with something but it will take me some time.

intern/ghost/GHOST_Types.h
309

you know what exactly this is doing? since i cant find that key anywhere specified i removed it. maybe it has to do with some linux or ios assignment?

intern/ghost/GHOST_Types.h
309

For the first part it seems to match key values to their ASCII codes. And then for the remaining events it starts key value from 0x100 = 256, so they are higher than any ASCII code.

I don't know if there is a specific reason for the way it works, but I don't see a reason to change it.