Ok, so I promised to give a non-Palm tip this time, and I'm going to deliver! This tip has to do with intercepting navigation events on Smartphone 2002+ devices. There are two different methods of intercepting them, and both occur during a WM_KEYDOWN message. Method 1: If you are willing to invest in using the GAPI SDK, you simply compare your wParam from your WM_KEYDOWN message against the GXKeyList that you get when you call GXGetDefaultKeys(GX_NORMALKEYS). Method 2: During your WM_KEYDOWN message, compare your wParam against the normal Windows virtual keys (VK_UP, VK_DOWN, etc.). Now, you may be wondering why you would ever use method 1, and the short answer is that on devices with both navigation buttons as well as full keyboards, you can end up with id collision. For example, if you are comparing against VK_RETURN, on some devices you may not be able to distinguish between the start/select key and the enter key.
|