DCCOMBOBOX IMMEDIATE does not work with touch screen
DCCOMBOBOX IMMEDIATE does not work with touch screen
I am using DCCOMBOBOX with IMMEDIATE and TYPE XBPCOMBO_DROPDOWNLIST. Depending on which item is selected, certain DCGETs are hidden or revealed. If I use a mouse to select an item in the combobox it is set into the variable immediately and the appropriate DCGETs are revealed, but if I touch the screen to select the item, it is displaced in the combo's SLE, but the variable is not set and the DCGETs remain hidden until the combobox loses focus. Why? Is there a workaround? Thx
Re: DCCOMBOBOX IMMEDIATE does not work with touch screen
I don't have a touch screen, so I cannot debug this for you.
I recommend that you use a custom handler clause in your DCREAD GUI command.
Use WTF to look at the events that are occurring when using the mouse vs the touch screen.
DCREAD GUI .. HANDLER myHandler
FUNCTION myHandler( nEvent, mp1, mp2, oXbp )
WTF DC_AppEventDefine(nEvent), mp1, oXbp
RETURN DCGUI_NONE
I recommend that you use a custom handler clause in your DCREAD GUI command.
Use WTF to look at the events that are occurring when using the mouse vs the touch screen.
DCREAD GUI .. HANDLER myHandler
FUNCTION myHandler( nEvent, mp1, mp2, oXbp )
WTF DC_AppEventDefine(nEvent), mp1, oXbp
RETURN DCGUI_NONE
The eXpress train is coming - and it has more cars.
Re: DCCOMBOBOX IMMEDIATE does not work with touch screen
For the Touch selection, WTF shows the following sequence:
xbeLB_ItemMarked,0,DC_XbpComboBox
xbeLB_ItemSelected,0,DC_XbpComboBox
xbeM_Motion,{46, 223},DC_XbpComboBox
followed by some xbeP_Paint actions on DC_XbpComboBox, etc...
The Mouse selection, WTF shows:
xbeLB_ItemMarked,0,DC_XbpComboBox
xbeP_Paint,{0, 241, 135, 264},DC_XbpComboBox
xbeLB_ItemSelected,0,DC_XbpComboBox
xbeM_Motion,{68, 14},DC_XbpGet
xbeP_Paint,{0, 4, 212, 19},DC_XbpGet
followed by some xbeM_Motion actions, etc...
Would this difference cause your IMMEDIATE clause not to function, or is there something else I should be looking for. Unfortunately, WTF aborted with an error message when I tried to save the results "Attempt to save non persistent data" called from DC_DEBUGBROWSESAVE(729), so I can't send you the files.
xbeLB_ItemMarked,0,DC_XbpComboBox
xbeLB_ItemSelected,0,DC_XbpComboBox
xbeM_Motion,{46, 223},DC_XbpComboBox
followed by some xbeP_Paint actions on DC_XbpComboBox, etc...
The Mouse selection, WTF shows:
xbeLB_ItemMarked,0,DC_XbpComboBox
xbeP_Paint,{0, 241, 135, 264},DC_XbpComboBox
xbeLB_ItemSelected,0,DC_XbpComboBox
xbeM_Motion,{68, 14},DC_XbpGet
xbeP_Paint,{0, 4, 212, 19},DC_XbpGet
followed by some xbeM_Motion actions, etc...
Would this difference cause your IMMEDIATE clause not to function, or is there something else I should be looking for. Unfortunately, WTF aborted with an error message when I tried to save the results "Attempt to save non persistent data" called from DC_DEBUGBROWSESAVE(729), so I can't send you the files.
Re: DCCOMBOBOX IMMEDIATE does not work with touch screen
XbpComboBox() objects have always been a problem when it comes to the order of events based on different operating systems.
The xbeLB_ItemMarked event is what fires the code block that causes the IMMEDIATE display so there should be no reason why it is not displaying, except that the xbeLB_ItemMarked event should cause an xbeP_Paint event. This appears to be failing with the touch screen.
I really don't know how to advise you on this. If I had a touch screen, I might be able to try lots of things.
Try this:
The xbeLB_ItemMarked event is what fires the code block that causes the IMMEDIATE display so there should be no reason why it is not displaying, except that the xbeLB_ItemMarked event should cause an xbeP_Paint event. This appears to be failing with the touch screen.
I really don't know how to advise you on this. If I had a touch screen, I might be able to try lots of things.
Try this:
Code: Select all
@ .. DCCOMBOBOX .. EVAL {|o|o:itemMarked := DC_MergeBlocks(o:itemMarked,{|a,b,o|o:invalidateRect()})}
The eXpress train is coming - and it has more cars.