| Summary: | [Workbench] Creating OK statuses | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | [Eclipse Project] Platform | Reporter: | John Arthorne <john.arthorne> | ||||||||||
| Component: | UI | Assignee: | Krzysztof Daniel <krzysztof.daniel> | ||||||||||
| Status: | VERIFIED FIXED | QA Contact: | Paul Webster <pwebster> | ||||||||||
| Severity: | trivial | ||||||||||||
| Priority: | P5 | CC: | krzysztof.daniel, pwebster | ||||||||||
| Version: | 3.0 | Keywords: | helpwanted | ||||||||||
| Target Milestone: | 3.6 M3 | Flags: | john.arthorne:
review?
(pwebster) |
||||||||||
| Hardware: | PC | ||||||||||||
| OS: | Windows 2000 | ||||||||||||
| Whiteboard: | hasPatch | ||||||||||||
| Attachments: |
|
||||||||||||
|
Description
John Arthorne
The following places in the workbench UI create new instances of Status with severity of OK. There is a singleton (Status.OK_STATUS) that can be used instead. Marking as trivial, but in some cases this can have non-trivial performance benefit. Someone familiar with the code could evaluate if these changes are worthwhile. org.eclipse.ui.ide/src/org/eclipse/ui/internal/ide/dialogs - FileFolderSelectionDialog.java org.eclipse.ui.intro/src/org/eclipse/ui/internal/intro/impl/util - Log.java org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/dialogs - CheckedTreeSelectionDialog.java (2 matches) org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/dialogs - ElementTreeSelectionDialog.java org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal - EditorHistory.java (2 matches) org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal - EditorHistoryItem.java (2 matches) org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal - EditorManager.java org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal - EditorSashContainer.java (2 matches) org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal - PartStack.java (2 matches) org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal - Perspective.java org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal - PerspectiveHistory.java (2 matches) org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/registry - PerspectiveDescriptor.java (2 matches) org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal - ViewFactory.java (4 matches) org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal - Workbench.java org.eclipse.ui.workbench.texteditor/src/org/eclipse/ui/texteditor - AbstractDocumentProvider.java I'd change: CheckedTreeSelectionDialog, ElementTreeSelectionDialog - because there OK status is used in validation. I do not see performance improvement in EditorHistory, EditorHistoryItem, EditorSashContainer, PartStack, Perspective, PerspectiveDescriptor, ViewFactory, Workbench, AbstractDocumentProvider. I think it is not necessary to change those classes because OK status is used in saving and restoring changes. I wouldn't change EditorManager (there is MultiStatus used). I have not found: Log, PerspectiveHistory (probably had been moved). Created attachment 90051 [details]
Patch that fizes most important IMO classes
Created attachment 90052 [details]
mylyn/context/zip
Created attachment 120675 [details]
Work in progress
The fix will not be as easy as expected, because I have found out that some logic relies on the OK status empty message.
Can this bug be assigned to me?
Created attachment 125381 [details]
Fix proposition
FileFolderSeletcionDialog - nothing to change
Log - Status is not mutable object, and in that class it comes with different messages
EditorHistory - replaced
EditorHistoryItem - replaced
PartStack - replaced
PerspectiveDescriptor - replaced
CheckedTreeSelectionDialog,
ElementTreeSelectionDialog,
AbstractDocumentProvider - sorry, some logic relies on Status message. Will break compatibility.
EditorManager - multistatus, not replaceable
Perspective,
EditorSashContainer,
ViewFactory,
Workbench,
- one replacement, other are multi
PerspectiveHistory - class not found
Paul, note this has a fairly recent patch and looks like a trivial fix. Something to consider throwing into M1. Sorry, this fell between the cracks. I can look at this in 3.6 M3 or you can take it Christopher (and move me to the CC) PW Latest patch released on 2009-10-01 Verified in N20091024-2000 by code inspection. |