|Eclipse Job doesn't have a sleep(long timeout) API [message #1022116]
||Thu, 21 March 2013 09:54
| Maqsood Ahmed
Registered: September 2010
Based on selection in the outline view, i must trigger a selection in the editor area with DELAY.
How can i do it?
I tried to use Job but it has no sleep(timeout) . Besides Thread.sleep() will block my UI.
Solution I chose :
I added a key adapter to the outline page treeviewer and then maintain flags to indicate if the if the arrow keys are released then i trigger a selection.
In the selection listener of the treeviewer i check if the flags(arrowreleased = true && arrowpressed = false) then i trigger a selection, Also i trigger on keyReleased() method. It works now. Is there a way to achieve the same using Jobs/Scheduling?
[Updated on: Thu, 21 March 2013 12:41]
Report message to a moderator
Powered by FUDForum
. Page generated in 0.01566 seconds