Sign in to follow this  
Triad_prague

Using f10 keys in the game :(

Recommended Posts

Hi I'm trying to use the F10 games for quick slot bar in the game (use f1~f12). things work fine until.....I pressed the f10 keys. the game freezes for a while until I click inside the window. I wonder what's the correct ways of processing this key. oh btw the alt key does the same too (freezes the game until I click inside the window). I'm using windows message (WM_KEYDOWN and WM_KEYUP) approach if that helps

Does anyone know a "common" way to deal with it?

Thanks :D

Share this post


Link to post
Share on other sites
Your culprit is WM_SYSKEYDOWN (responsible for ALT and F10 keys - they both have to do with opening the app's menu, which can cause the freezing you're experiencing).

I can't remember what the correct way to handle it is, though... I guess you could try just returning 0 when you get that message (instead of letting it go to DefWindowProc). I seem to recall there are some ALT+? keys that you want to let through though.

(Edit) Ninja'd!

Share this post


Link to post
Share on other sites
thanks mussi, nypyren, your ideas helped me solved the problem. what I do is by processing WM_SYSKEYDOWN and WM_SYSKEYUP too and return 0 in the window procedure and process WM_SYSCOMMAND as mussi said. whew now it works good!

Thanks again :lol:

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this