02-15-2016 12:13 AM
Hi All,
I am facing a problem in with respect to Right Click Shortcut menu.
I have a tree control and I am populating certain items in the tree. I am updating the tree's shortcut menu based upon the selection. I am using Point to Row Column method to find the current selection and setting it as tree value using property node. Based upon the selection there needs to be a number of operations in order to update the background data structure and UI. So I am looping in all the cases to do the same.(I use State machine architecture).
The cases starts executing as expected properly until the right click menu appears. Once it appears, the execution pauses wherever it is and resumes its execution upon next mousedown event (Either the right menu or anywhere). Because of this the Menu items are not proper and also the UI is also not updated.
Please let me know if you have any suggestions.
02-15-2016 03:10 AM
You forgot to post your code, so I'll just have to guess...
Are you using an event structure? Do you have 'lock panel until event completes' ticked? Is the event structure in the same loop as your processing/update code?
It's also quite possible that the right click menu runs in the UI thread so it blocks anything else running in the UI thread until it completes.
02-15-2016 04:34 AM
Yes I use event structure in the State Machine. There is only one while loop for the Event Structure/Operations. Few Defer panel updates are there, but the execution pauses even before the case with the defer panel property node is reached.
Even I suspect the issue is related to UI thread.
02-15-2016 04:41 AM
@Sam_Sharp wrote:You forgot to post your code, so I'll just have to guess...
How about we take the guesswork out?