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.
Currently if you want to find a list of open TC's in a Mode, you can call Mode.getTopComponents() and check isOpened() on each. Unfortunately, loading non-open TC's can involve a lot of work. The fix for issue #156647 requires using WindowManager.modes followed by Mode.topComponents to iterate open editor TC's in visible order. This can cause lengthy delays when closing projects - see the profiler snapshot, where the window system is loading the Bugzilla window, which I have opened maybe once and never again. An API method Mode.getOpenTopComponents, which did not even try to load serialized data and classes from TC's known to not be open, would be useful here.
Created attachment 84315 [details] Profiler snapshot
*** Issue 168453 has been marked as a duplicate of this issue. ***
fixed, core-main cbc223a0ed28 i cannot add new methods to Mode interface but you can use WindowManager.getOpenedTopComponents(Mode)
Integrated into 'main-golden', will be available in build *200907160201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/cbc223a0ed28 User: S. Aubrecht <saubrecht@netbeans.org> Log: #168060 - faster method to retrieve the list of TopComponents opened in a Mode