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.
Allow to add nodes into project UI by layer declaration. For more info see: http://www.netbeans.org/issues/show_bug.cgi?id=72441
Attaching patch. Can be done without issue 153347, but with many more lines of code.
Created attachment 73844 [details] Diff (requires patch from issue 153347)
One question is whether to use the same layer path as J2SEProject. In some cases, that could be useful - for example, I once wrote a patch for the UML module to display UML diagram nodes under the project they were associated with. So for modules that do something very general with any Java project, it allows them to decorate mobility projects too. On the other hand, you could have some decorator which assumes a real J2SEProject and blows up. Opinions? Preferences?
Actually, looks like reusing j2seproject's directory will break things. So we can use our own. Anyway, the attached patch works.
Thanks for the patch. It works for adding nodes. Unfortunately we need also to remove nodes (Project Configurations and probably also Resources). I'm sorry for confusing issue summary (fixed now). I used the summary from issue #72441 because I expected it will be implemented by the same way and we will get the same functionality. To clarify it - we need to add new nodes and also remove some of the existing nodes. Hopefully this could be simply solved be declaring all mobility project nodes in the layer.
Fixed in changeset a800b0159c85 Nodes can now be added to mobility projects using the same classes as in J2SEProject. The SFS folder for registering factories is Projects/org-netbeans-modules-mobility-project/Nodes
Verified.