Simon853
21 Mar 2008, 14:01
I seem to be having some trouble masking events using simconnect by the event name, i.e. "parking_brakes".
I can get the event to trigger a case in my callback by using the line:
hr = SimConnect_MapClientEventToSimEvent(hSimConnect, EVENT_1,"PARKING_BRAKES");
But what I want to do is this:
hr = SimConnect_MapInputEventToClientEvent(hSimConnect, INPUT_1, "PARKING_BRAKES", EVENT_1, 0, (SIMCONNECT_CLIENT_EVENT_ID)SIMCONNECT_UNUSED, 0, true);
so I can detect the event and mask it. But despite me setting:
hr = SimConnect_SetInputGroupPriority(hSimConnect, INPUT_1, SIMCONNECT_GROUP_PRIORITY_HIGHEST_MASKABLE);
it never seems to get masked. Are these events with named strings generated from a layer lower than the highest maskable?
I know I can successfully mask raw keystrokes, but that's no good as it takes no account of the user's key configuration.
Any ideas?
Si
I can get the event to trigger a case in my callback by using the line:
hr = SimConnect_MapClientEventToSimEvent(hSimConnect, EVENT_1,"PARKING_BRAKES");
But what I want to do is this:
hr = SimConnect_MapInputEventToClientEvent(hSimConnect, INPUT_1, "PARKING_BRAKES", EVENT_1, 0, (SIMCONNECT_CLIENT_EVENT_ID)SIMCONNECT_UNUSED, 0, true);
so I can detect the event and mask it. But despite me setting:
hr = SimConnect_SetInputGroupPriority(hSimConnect, INPUT_1, SIMCONNECT_GROUP_PRIORITY_HIGHEST_MASKABLE);
it never seems to get masked. Are these events with named strings generated from a layer lower than the highest maskable?
I know I can successfully mask raw keystrokes, but that's no good as it takes no account of the user's key configuration.
Any ideas?
Si