Community
Participate
Working Groups
I. When you select an open editor via the Navigator or Packages views, it will become visible but not active. This is probably the desired behaviour but the only problem is if you try to do an editor action (such as Close) it will close the last active editor, not the current visible one. This can be a bit confusing but is not major. Steps: 1) create file 'abc', the editor should become visible and active 2) create file 'xyz', the editor should become visible and active 3) click on 'abc' in the navigator, notice that abc's editor becomes visible but not active 4) File > Close (or Ctrl+F4) xyz closes, you would have expected abc to close. II. When you do a drag-and-drop operation on an editor to split up the editors, the editor is shown as active but the Close operation does not affect it. Steps: 1) create file 'abc', the editor should become visible and active 2) create file 'xyz', the editor should become visible and active 3) grab the title bar of 'abc' and drag it to an edge thus spliting up the editor workspace - do this in one action (do not select it before moving) 4) File > Close 'xyz' close, 'abc' should have closed NOTES: JEL (19/06/2001 3:11:00 PM) from CloseEditorAction::run -> IEditorPart part = getActiveEditor(); could be changed to -> IEditorPart part = activePage.getEditorPresentation().getVisibleEditor(); This would tell the workbench to close the Editor that is being viewed instead of the last editor that was clicked on.
PRODUCT VERSION: 125
Simon, Please try in latest 2.0 builds.
Try reproducing the problems with the original steps provided...
Build: 20020115 The first problem still exists. When a file is selected in the Navigator view, it becomes visible but not active, so clicking on File->Close doesn't necessarily close the visible file. The second problem no longer exists, since grabbing the title bar of a file in the editor workspace automatically selects it. It is impossible to drag and drop a file this way without selecting it.
The first problem comes from the implementation of the ActiveEditorAction class which did not track/cache the active editor properly. Code changed to do so. Fix in build > 2002-01-25