| Summary: | [templates] code assist no longer suggests templates for method completions as it did in 3.2 | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [Eclipse Project] JDT | Reporter: | jay_schmidgall | ||||
| Component: | Text | Assignee: | JDT-Text-Inbox <jdt-text-inbox> | ||||
| Status: | VERIFIED FIXED | QA Contact: | |||||
| Severity: | major | ||||||
| Priority: | P3 | CC: | benno.baumgartner, daniel_megert, jerome_lanneluc | ||||
| Version: | 3.3 | ||||||
| Target Milestone: | 3.3.1 | ||||||
| Hardware: | PC | ||||||
| OS: | Windows XP | ||||||
| Whiteboard: | |||||||
| Attachments: |
|
||||||
Sorry, the description of the template actually matches what is shown in the code assist popup, I just typed it in wrong in the example. Moving to JDT/Text This needs to be fixed. Probably introduced by fix for bug 21926. *** Bug 199425 has been marked as a duplicate of this bug. *** Fixed in HEAD. Created attachment 77217 [details]
Fix
The fix has two parts:
1) reverts the old behavior for the template contexts
2) checks the template name in the template edit dialog (if we want to be conservative we can skip that part for 3.3.1)
Fixed in R3_3_maintenance. start verification verified in M20080123-0800 |
Build ID: I20070625-1500 Steps To Reproduce: 1.Define a template for a method completion, say named addcomp. 2.In the java editor, define a variable, say a JButton button. 3.Type button.addcomp<code assist> 4.Note that addcomp is not one of the suggestions. It was in 3.2. More information: I have templates defined which add an anonymous listener to a Swing component. For example, Name Context Description Auto Insert addcomp java add a component listener on Preview addComponentListener(new ComponentAdapter() { public void componentHidden( ComponentEvent e ) { ${cursor} } public void componentMoved( ComponentEvent e ) { } public void componentResized( ComponentEvent e ) { } public void componentShown( ComponentEvent e ) { } }); I could then type some code like JButton button = new JButton( "button" ); button.addcomp<code assist> and in 3.2, the code assist popup would list addcomp - add component adapter addComponentListener(ComponentListener l) void - Component and I could choose addcomp to have the above code added for me. In 3.3, it longer gives me the choice, instead, it simply chooses the match and fills in button.addComponentListener( l ) If I instead type button.addc<code assist> The popup lists the methods which complete that, but not the templates. It appears that templates are no longer suggested by code assist in 3.3 when in 3.2 they would be suggested, and it was quite useful.