问题
I need to fire event resize after collapse and expand. When I try to do that using SWT.Collapse and SWT.Expand, there is no changes on tree because its fire before its happen. Is there any way to this?
回答1:
Try calling Display.asyncExec to schedule a Runnable in the SWT.Collapse/Expand listener. The Runnable will not run until the current Tree operation is complete.
来源:https://stackoverflow.com/questions/18868107/fire-event-after-expand-collapse-tree