Bug 21618 - Stop eager loading of TopComponents when not needed
Stop eager loading of TopComponents when not needed
Status: VERIFIED FIXED
Product: platform
Classification: Unclassified
Component: Window System
3.x
PC Linux
: P3 (vote)
: 3.x
Assigned To: Peter Zavadsky
issues@platform
: PERFORMANCE
Depends on:
Blocks: 19038
  Show dependency treegraph
 
Reported: 2002-03-15 10:40 UTC by Jaroslav Tulach
Modified: 2008-12-23 09:35 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jaroslav Tulach 2002-03-15 10:40:24 UTC
During investigation of different possibilities how to minimize the amount of
classes loaded into VM I have realized that RMIRefrshAction is loaded due to
initialization of Runtime tab. 

When the system starts the runtime tab is deserialized and inserted into AWT
hiearachy. This results in TreeView.addNotify () and that leads to
JTree.rootNode.expand which loads all nodes visible in RuntimeTab.

We have to prevent this for rumtimetab and also for editors sake.

The best place to hack this in seems to be the the initialization of
tabmodecontainer - deserialize the topcomponents but do not insert them into the
AWT hiearchy until really needed. When somebody switches to the tab, insert it
and call TopComponent.notifyOpened (). This shall work for TreeView and will
allow delayed implementation in Editor.

PS: Please also consider addition of TopComponent.notifyVisible () and
notifyNonvisible() to give components better handling of their visibility
state...
Comment 1 Peter Zavadsky 2002-05-10 15:28:58 UTC
Fixed in trunk.

New methods added to TopComponent:
protected void componentShowing()
protected void componentHidded()
(also were deprecated openNotify() and closeNotify() and replaced by
componentOpened(), componentClosed() ).

[ Also added managing methods to WindowManager:
protected void componentShowing(TopComponent)
protected void componentHidded(TopComponent) ]


See also issue #19038.

Comment 2 Jan Chalupa 2003-11-03 16:35:27 UTC
Previously RESOLVED issue that was mistakenly put into the NEW
state... closing again...
Comment 3 Marian Mirilovic 2004-03-01 08:52:51 UTC
issue doesn't apply to new window system - verified


By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo