Silverfrost Forums

Welcome to our forums

clearwin and %eb structure

22 Jul 2005 8:14 #238

For some time I have used the %eb format to successfully display material and detect both the double click of the left mouse and mouse right click.

I note that the edit_info structure also includes at offsets 10 and 11 some link to the keyboard, but this is not described anywhere?

I would like to detect whether (say) shift is depressed at the point when a double click has been detected. I have set vk_key (i.e. array element 10) = 10 (for shift - MS site) - or should this be 16 -, but there appears to be no change in offset 11 (the shift state) when holding down shift and double clicking? Could anyone provide further information on how this might be done and whether I have interpreted the edit_info parameters correctly?

Many Thanks

Bill Dowsland.

22 Jul 2005 9:12 #239

I don't think the vk_shift variable is used any more (I'm not sure it has ever been used) and the vk_key variable is only used for the KEY_DOWN callback.

You may be able to check the status of the shift key from within your callback routine using the GetKeyState Windows API routine, i.e. GetKeyState(VK_SHIFT). You will need to include the usual windows headers (or use the modules).

For more information on GetKeyState see http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/winui/windowsuserinterface/userinput/keyboardinput/keyboardinputreference/keyboardinputfunctions/getkeystate.asp

Martin

22 Jul 2005 9:33 #240

Many thanks Martin for a VERY quick response.

Calling GetKeyState(16) - for Shift - works fine and enables me to provide an alternate action on double click when Shift is held down.

Thanks again, Bill

Please login to reply.