This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 126915 - New File wizard title missing template name
Summary: New File wizard title missing template name
Status: RESOLVED WONTFIX
Alias: None
Product: projects
Classification: Unclassified
Component: Generic Infrastructure (show other bugs)
Version: 6.x
Hardware: All All
: P4 blocker (vote)
Assignee: Tomas Stupka
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-02-07 14:07 UTC by Andrei Badea
Modified: 2016-07-07 08:37 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andrei Badea 2008-02-07 14:07:18 UTC
Invoke the New File wizard. Select a two-step wizard, for example Web - Servlet. Go to the second (last) step of the
wizard. The wizard title will change to "New File", althought it was correct ("New Servlet") in the previous step.
Comment 1 Milos Kleint 2008-02-15 14:01:56 UTC
new Glassfish/Javamail session and Struts/Struts Action seem to work fine..
Comment 2 Milos Kleint 2008-02-15 14:22:37 UTC
there seems to be this code snippet scattered around the codebase (grep for "NewFileWizard_Title") :

        // XXX hack, TemplateWizard in final setTemplateImpl() forces new wizard's title
        // this name is used in NewFileWizard to modify the title
        Object substitute = gui.getClientProperty ("NewFileWizard_Title"); // NOI18N
        if (substitute != null) {
            wizard.putProperty ("NewFileWizard_Title", substitute); // NOI18N
        }

That's why it somewhere works and not in the servlet wizard..
reassigning to openide
Comment 3 Milan Kubec 2008-03-10 16:30:15 UTC
It needs to be fixed in Servlet wizard panel "Configure Servlet Deployment".
Comment 4 Andrei Badea 2008-03-11 11:07:42 UTC
I don't think I understand why each template iterator needs to copy-paste some boiler-plate code annotated by a "XXX
hack" comment. It seems the New File wizard needs fixing, not the iterators.
Comment 5 Milan Kubec 2008-03-12 10:28:36 UTC
Well, you don't need to copy any "XXX hack", just add following line to the panel code:

putClientProperty("NewFileWizard_Title", "My title");

To fix this correctly would require rewrite of project new file wizards and that will not probably happen in near future.
Also I think that according to bug priority guidelines (http://qa.netbeans.org/bugzilla/bug_priority_guidelines.html)
it's P4/P5.
Comment 6 Andrei Badea 2008-03-12 11:29:43 UTC
I won't argue about the priority, but I would argue about the putClientProperty() call. The template author has already
set the name of the template, there is no reason to expect him to do it again in all (or all but the first) panels.
Comment 7 Milan Kubec 2008-03-13 14:17:07 UTC
Setting priority according to bug priority guidelines.
Comment 8 Antonin Nebuzelsky 2010-03-29 14:10:34 UTC
Change of default owner.
Comment 9 Martin Balin 2016-07-07 08:37:53 UTC
This old bug may not be relevant anymore. If you can still reproduce it in 8.2 development builds please reopen this issue.

Thanks for your cooperation,
NetBeans IDE 8.2 Release Boss