| Summary: | [Navigator] Package explorer flicker when switching/closing editors | ||
|---|---|---|---|
| Product: | [Eclipse Project] Platform | Reporter: | Dan Berindei <dberindei> |
| Component: | UI | Assignee: | Nick Edgar <n.a.edgar> |
| Status: | VERIFIED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | CC: | billy.biggs, dirk_baeumer, snorthov |
| Version: | 3.0 | ||
| Target Milestone: | 3.1 M7 | ||
| Hardware: | PC | ||
| OS: | Windows XP | ||
| Whiteboard: | |||
|
Description
Dan Berindei
The linking is implemented by calling fViewer.setSelection(newSelection, true) where new selection contains the element presented in the editor. Moving to Platform/UI for comments. There was an issue with the way AbstractTreeViewer was implemented. To reveal /A/B/C/D.java, it would: - create children for A - expand A - create children for B - expand B - create children for C - expand C - select and reveal D.java I've changed to create all parent elements before expanding them, and to do the expansion bottom up: - create children for A - create children for B - create children for C - expand C - expand B - expand A - select and reveal D.java This should result in much less flicker and jumpiness. While tracing through this, I noticed that the tree widget repaints itself eagerly, when disposing the dummy element or toggling expansion state, even though events are not getting processed yet. Steve, is this expected? Steve says that the explicit setExpanded and showItem calls should not be necessary if the resulting items are being selected with setSelection, so I've changed AbstractTreeViewer.setSelection to call internalExpand with expand=false, and commented out the showItem call. This works fine on Win2K. Need to test on GTK and the Mac. ... and Motif. BB to make sure that SWT doesn't have a bug in this area. Windows paints when Windows wants to paint. It's possible that we are forcing this somehow to work around a bug. Should we investigate more? I think the changes here should reduce the amount of explicit painting done by Windows anyway, so let's just try running with this for a while and see if it improves things. It should hopefully make a big improvement for Link with Editor. Billy, can you confirm that this change works OK on GTK, Mac and Motif? Looks good to me on GTK+, Motif, and Carbon on I20050510-0010. Thanks Billy. Verified in I20050509-2010 on Win2K. |