Capturing shift key state on Windows 8 tablet in MFC App -


our mfc-based windows application has functionality depends on state of shift key. shift exposes power-user menu commands , shift-dragging has different behavior normal dragging. exploring our options in supporting windows 8 tablets, , seems there no straightforward way detect state of windows 8 soft keypad shift key.

using getasynckeystate(vk_shift) (our current method) doesn't detect key.

experimenting examining incoming keyboard messages, find:

  • a single isolated tap of shift key produces no keyboard event
  • a double tap of shift key produces caps lock key event, indistinguishable normal caps lock key event
  • a single tap of shift key followed keystroke (eg. 'q' key) produces shift key event, keystroke, , shift key (up?) event.

are there other ways try detect state of soft keyboard shift key? has else had success detecting state of keypad on windows 8 tablet soft keyboards.

the external keyboards plug these devices have normal behaving shift keys. problem specific soft keypad.


Comments

Popular posts from this blog

android - getbluetoothservice() called with no bluetoothmanagercallback -

sql - ASP.NET SqlDataSource, like on SelectCommand -

ios - Undefined symbols for architecture armv7: "_OBJC_CLASS_$_SSZipArchive" -