Advertisement

Where is my CAPS ???

Started by November 08, 1999 06:25 AM
0 comments, last by Akura 25 years, 2 months ago
Hi.

I was just wondering how i can get teh state of Caps Lock with DInput ... is it possible ??? if so how ?? if now ?? how can I so it only using the win32 api ...

Thks !!

Akura

It's good to be an outcast, you don't need to explain what you do, you just do it and say you don't belong there.
Hello Akura

You can use DIK_CAPSLOCK or DIK_CAPITAL like this:

char keys[256];
LPDIRECTINPUTDEVICE pKeyb; // I suggest that DI and DID are already properly initialized

pKeyb->GetDeviceState(sizeof(keys), keys);
if (keys[DIK_CAPSLOCK] & 0x80)
{
// CAPS LOCK is pressed
}

VirtualNext

This topic is closed to new replies.

Advertisement