Bug 322295

Summary: CommonEditorUtility does not compile with e4
Product: [WebTools] WTP Java EE Tools Reporter: Carl Anderson <ccc>
Component: jst.j2eeAssignee: Carl Anderson <ccc>
Status: RESOLVED FIXED QA Contact: Chuck Bridgham <cbridgha>
Severity: blocker    
Priority: P1 CC: david_williams
Version: 3.2   
Target Milestone: 3.3 M1   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Bug Depends on:    
Bug Blocks: 322786    
Attachments:
Description Flags
First attempt at a workaround for this issue. none

Description Carl Anderson CLA 2010-08-10 18:33:35 EDT
In e4, the EditorManager class was removed.  The static method that we use, saveAll(), needs to be replaced/updated with code that will work with e4.  If at all possible, this code should also work with Eclipse 3.7.  Here are the errors from the build:

Source File: org/eclipse/jst/j2ee/internal/plugin/CommonEditorUtility.java 
1. ERROR: ImportNotFound
The import org.eclipse.ui.internal.EditorManager cannot be resolved 

CommonEditorUtility.java : 

28 : import org.eclipse.ui.internal.EditorManager;

2. ERROR: UndefinedName
EditorManager cannot be resolved 

CommonEditorUtility.java : 

102 : return EditorManager.saveAll(dirtyEditors, true, true,false, J2EEUIPlugin.getActiveWorkbenchWindow());
Comment 1 Carl Anderson CLA 2010-08-10 18:35:58 EDT
Currently, there are only two references in WTP to this class- J2EEArtifactExportWizard and J2EEArtifactImportWizard.
Comment 2 Carl Anderson CLA 2010-08-12 00:40:51 EDT
Created attachment 176431 [details]
First attempt at a workaround for this issue.
Comment 3 Carl Anderson CLA 2010-08-12 01:21:28 EDT
Committed to HEAD for WTP 3.3 M1