Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 248424

Summary: [hotbug] Should be able to skip opening the editor after JSP creation using NewJSPWizard
Product: [WebTools] WTP Source Editing Reporter: kiril mitov <thebravoman>
Component: jst.jspAssignee: Nitin Dahyabhai <thatnitind>
Status: CLOSED FIXED QA Contact: Nitin Dahyabhai <thatnitind>
Severity: enhancement    
Priority: P3 CC: kaloyan
Version: 3.0.2   
Target Milestone: 3.0.3   
Hardware: All   
OS: All   
Whiteboard:
Attachments:
Description Flags
Patch for setOpenEditorOnFinish none

Description kiril mitov CLA 2008-09-24 08:59:39 EDT
It should be possible to skip the opening of the jsp file when using NewJSPWizard.

I am creating a new jsp in a adopter graphical editor and after the creation the editor for the newly created jsp. I would like to keep the focus on the graphical editor. This means that the wizard should allow for the configuration of whether the editor should be open. This is easily achieved using DataModelWizard since there is an option -INewJavaClassDataModelProperties.OPEN_IN_EDITOR. But the NewJspWizard is not a DataModelWizard.

I would suggest two resolutions.
1. Make the openEditor() method of the NewJspWizard protected so that I could override it.
2. Add a new field and setter method to the NewJspWizard class - setOpenEditorOnFinish. The default value of the field is "true". Add a check in the performFinish and call openEditor() only if openEditor field is true. I have attached a patch for this solution since I think this should be the preferred way.
Comment 1 kiril mitov CLA 2008-09-24 09:00:18 EDT
Created attachment 113354 [details]
Patch for setOpenEditorOnFinish
Comment 2 kiril mitov CLA 2008-09-24 09:55:16 EDT
Affiliation - SAP
Release you want this bug to be fixed in - 3.0.3
Justify why this is a hot bug and why it needs to be fixed in that release - It
stops a basic scenario in our product
Comment 3 Nitin Dahyabhai CLA 2008-09-25 14:01:07 EDT
I'll overlook the part where this skipped being a hotbug_request, but this in no way meets the criteria of a critical bug.  
Comment 4 Nitin Dahyabhai CLA 2008-10-08 01:48:35 EDT
Released.
Comment 5 kiril mitov CLA 2008-10-23 03:35:22 EDT
Verified with
M-3.0.3-20081021200034
Comment 6 Kaloyan Raev CLA 2008-11-10 04:01:14 EST
Closing.