Re: How to change BeanNode icon at runtime?

Keyur Shah <[email protected]>
Newsgroups gmane.comp.java.netbeans.modules.openide.devel
Message-ID <SG2PR02MB1309A0089487D2FAB02A8262F3630@SG2PR02MB1309.apcprd02.prod.outlook.com>
I’m using ChildFactory. Calling refresh(true) doesn’t refreshing the icon (getIcon() method is not being called) as well.

Regards,
Keyur

From: Benno Markiewicz [mailto:[email protected]]
Sent: Tuesday, April 26, 2016 1:36 AM
To: [email protected]
Subject: [platform-dev] Re: How to change BeanNode icon at runtime?

It depends on your node creation. If you are using Children.Keys use refreshKey http://bits.netbeans.org/dev/javadoc/org-openide-nodes/org/openide/nodes/Children.Keys.html#refreshKey-T-

At least this is what the javadoc says: if your notion of what the node for a given key changes (but the key stays the same), you can call refreshKey(T)<http://bits.netbeans.org/dev/javadoc/org-openide-nodes/org/openide/nodes/Children.Keys.html#refreshKey-T->.

With kind regards, markiewb

2016-04-25 14:06 GMT+02:00 <[email protected]<mailto:[email protected]>>:
I am extending BeanNode class. And on 1 of property change I want to
change the icon of that node. Property change does not occur in
ChildFactory class. So how can I refresh/update the node icon ?

************************************************************************************************************************************************************* eInfochips Business Disclaimer: This e-mail message and all attachments transmitted with it are intended solely for the use of the addressee and may contain legally privileged and confidential information. If the reader of this message is not the intended recipient, or an employee or agent responsible for delivering this message to the intended recipient, you are hereby notified that any dissemination, distribution, copying, or other use of this message or its attachments is strictly prohibited. If you have received this message in error, please notify the sender immediately by replying to this message and please delete it from your computer. Any views expressed in this message are those of the individual sender unless otherwise stated. Company has taken enough precautions to prevent the spread of viruses. However the company accepts no liability for any damage caused by any virus transmitted by this email. *************************************************************************************************************************************************************
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.