| Summary: | [formatter] FormattingStrategyJSDT should be added by provisionalConfiguration | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [WebTools] JSDT | Reporter: | Ian Tewksbury <itewksbu> | ||||
| Component: | Web | Assignee: | Ian Tewksbury <itewksbu> | ||||
| Status: | RESOLVED FIXED | QA Contact: | Nitin Dahyabhai <thatnitind> | ||||
| Severity: | normal | ||||||
| Priority: | P3 | CC: | cmjaun, nsand.dev | ||||
| Version: | 3.2 | Flags: | cmjaun:
review+
nsand.dev: review+ thatnitind: review+ |
||||
| Target Milestone: | 3.2.1 | ||||||
| Hardware: | All | ||||||
| OS: | All | ||||||
| Whiteboard: | |||||||
| Attachments: |
|
||||||
|
Description
Ian Tewksbury
Created attachment 171579 [details]
Fix Patch
Fix patch to use provisionalConfiguration slaveformattingstrategy for both HTML and JSP documents and remove the overriding of getContentFormatter now that it is being done by extension point.
All existing JUnits pass and no new ones need be added because there is no user end functional change here just back end. But even though this is a back end only change this is important so that if other contributors are using script regions in their documents they correctly pick up JS formatting for those regions.
I think you also need to add org.eclipse.wst.html.SCRIPT as a target for the JSDT JSP support. But other than that, I approve. (In reply to comment #2) > I think you also need to add org.eclipse.wst.html.SCRIPT as a target for the > JSDT JSP support. But other than that, I approve. Its the same formatter class (FormattingStrategyJSDT) that gets registered for both the org.eclipse.wst.html.SCRIPT and org.eclipse.jst.jsp.SCRIPT.JAVASCRIPT region and because the provisionalConfigurations are not content type aware org.eclipse.wst.html.SCRIPT will be formatted in JSP documents due to the provisionalConfiguration in the HTML plugin. If you notice all of the other provisionalConfigurations in the JSP plugin all only register themselves on org.eclipse.jst.jsp.SCRIPT.JAVASCRIPT because HTML does the registering for org.eclipse.wst.html.SCRIPT. Well...I don't know much about how this stuff works, so if Nick says its okay, and you have done good testing, its fine with me. Fix checked into 3.2.1 Fixed |