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.
It takes too long then to show Window menu, which contain that action, for the first time. Also, in the builds with the new Welcome Panel, it loads the (closed) WelcomePanel instance as well, prolonging the menu invocation time by ~8s.
One more odity: If I close the Welcome Panel, switch to GUI edititng, shutdown the IDE, start it again and open a form, the WP gets loaded and instantiated (even twice in my case).
Created attachment 6125 [details] Suggested patch
I guess problem is not instantiating WelcomeTopComponet, but that it GUI is inited in constructor, the method componentShowing should be used for that purpose. I suggest the fix (see attachment). Reassigning.
No, that is not the problem. Even if I disable the Welcome module, Window menu takes ~2s to show the first time, which is caused by the fact that OpenedWindowsAction loads all the components for the workdspace. It is only more visible with Welcome module as its TC is very slow to initialize for the first time.
OK, you want to save the deserialization time also. I don't see a simple way now to do it, unless we will create some lightweight TC delegates keeping just name, icon etc. of the TC itself. Marek what do you think about it, you know much more about how the TC loading.
What about to create workspace submenu when it is needed? So do not create submenus for all workspaces at once. The problem is that we use ModeImpl.isOrphan() to decide if mode should be added to menu or not. It causes loading of all top components. Not sure if we can use some other condition.
Maybe we could use ModeImpl.isHidden() instead of ModeImpl.isOrphan(). isHidden loads just mode properties not components. When mode is hidden all top components in mode are closed. I think (hope) it is exactly what we need. Need to check how it works for dynamicaly created mode eg.Options when it is closed.
Fixed as suggested. ModeImpl.isHidden() is used instead of ModeImpl.isOrphan() to avoid loading of top components. I had to fix status of output and properties modes in form module to hidden. (Status was not set and default is visible.) Modified: src/org/netbeans/core/actions OpenedWindowsAction.java r.1.44
Great
Resolved for 3.4.x or earlier, no new info since then -> closing.