Community
Participate
Working Groups
In the Java perspective there is a JDT toolbar that has buttons for creating a new Java project, package, or class. Beside the class button there is a dropdown that lets you create a new class, interface, enum, etc. This should be extended by WTP to add the option for a new servlet.
Tim, Do you mean that we need to extend the toolbar in the Java perspective? Or you mean that we need a similar toolbar in the Java EE perspective that include the Servlet wizard? If we contribute new action items to the Java perspective toolbar, then with the same logic we may add all other Java EE artifacts in addition to the Servlet. In this case we may overcrowd the Java perspective with Java EE content.
I agree, adding all of the EE5 artifacts to the existing menu could be a bit much. I use the regular drop down to create all my Java classes, so I really just want to do the same thing for Java EE. Right now we have 5 separate buttons on the JEE perspective toolbar (one for each project type). Ideally I think we'd just have two drop downs - one for 'projects' (EAR, EJB, Web, App Client, Connector) and one for 'artifacts' (Servlet, EJB, JPA, JSP, etc.).
I think I can do this for M4.
Created attachment 84854 [details] patch This patch removes the old five toolbar buttons for creating Java EE projects and replaces them with two pulldown toolbar buttons: - for creating Java EE projects: Web, EJB, EAR, etc. - for creating Java EE artifacts: Servlet, Listeners, XDoclet beans, etc. This patch covers only the JavaEE and EJB components, because I am a committer only for them. Other projects and artifacts like JPA project, JSP, Web Services, etc. should be added to the pulldown buttons by the respective committers. I will inform them how to do this on the mailing list.
Dropped to HEAD.
I just checked this out, and I like the idea, but I have a couple suggestions. We need to be similar to other multiple action buttons, like Run and Debug. They have separate hover text, and icons defining the group of actions. And they all have "launch history" to capture the last action taken (which is the default action if the button is selected rather than expanded. Right now the first action defined "Dynamic Web Project" is selected. Also - The Category names should be Named "Create Java EE Project" and "Create Java EE Artifact" - because the "Create" verb isn't currently included in the titles of these actions.
Chuck, thanks for the suggestions. I have made the Java EE Projects and Java EE Artifacts pulldown buttons similar not to the Run/Debug buttons, but to the Java class artifacts in the Java (JDT) perspective. I have selected Dynamic Web Project and Servlet wizard to be default, because it is in my opinion the first action that the user would use. I like the idea of having "launch history" and dynamically change the default action of the pulldown buttons. Unfortunately, it seems that the technology of the pulldown button does not allow changing the default icon - we have to make new generic icons for "Create Java EE Project" and "Create Java EE Artifact". It should be possible to change the tooltip text dynamically. Currently, the Java EE pulldown button have the same behavior of the Java class (JDT) pulldown button - there the default action is fixed to "New Java Class". About the action titles - I haven't touched them. If I put "Create" prefix in the action titles, then this will be also reflected in the File > New submenus, which is undesired effect. Again, check the Java class pulldown in the JDT perspective - there is no "Create" verb in the action titles.
Verified with the S-3.0M4-20071227065330 build.
Closing