Custom property editor in the Version Netbeans IDE 6.1

View: New views
2 Messages — Rating Filter:   Alert me  

Custom property editor in the Version Netbeans IDE 6.1

by zhujihang :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi!
     I had created a RCP Appliction Program by the Netbeans IDE 6.1. In this program, I had created a custom property editor for a node's property. It works well except that the 'Cancel' button works the same as the 'Ok' button in the custom property editor, failing to reset the value of the property. Later I spent some days trying to figure it out, but I failed.
     Yesterday I ran this RCP application program by the other Netbeans IDE version: 6.0.1. I found that everything went well, and the 'cancel' button can exactly reset the value of the node's property in the custom  property editor. The same problem happended when I ran another similar RCP applcation program written by myself.
     Q:Which version of Netbeans IDE is the right one for my RCP application program. Does it exist a bug in the Netbeans IDE 61 on supporting custom property editor in the property sheet.
     Looking forword to your reply! Thank you! 
 
                                                                                        Hang
 
 



中 国 最 强 网 游 --- 网 易 梦 幻 西 游 ,166 万 玩 家 同 时 在 线

Re: Custom property editor in the Version Netbeans IDE 6.1

by ag_sachin :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Are you creating the Custom property Editor by extending the PropertyEditorSupport and implementing ExPropertyEditor, InplaceEditor.Factory

then in the method getInplaceEditor and getCustomEditor

return an frame that overrides cancelButtonActionPerformed(ActionEvent evt) {//simly dispose} and okButtonActionPerformed(ActionEvent evt) { //set text and dispose }

I hope that will solve the issue.

Regards,
Sachin.