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.

Bug 223466 - NullPointerException at org.netbeans.modules.form.CodeCustomEditor.<init>
Summary: NullPointerException at org.netbeans.modules.form.CodeCustomEditor.<init>
Status: RESOLVED FIXED
Alias: None
Product: guibuilder
Classification: Unclassified
Component: Code (show other bugs)
Version: 7.3
Hardware: All All
: P3 normal (vote)
Assignee: issues@guibuilder
URL:
Keywords:
: 214936 (view as bug list)
Depends on:
Blocks:
 
Reported: 2012-12-07 10:05 UTC by Exceptions Reporter
Modified: 2013-01-04 02:32 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 196241


Attachments
stacktrace (2.79 KB, text/plain)
2012-12-07 10:05 UTC, Exceptions Reporter
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Exceptions Reporter 2012-12-07 10:05:30 UTC
This bug was originally marked as duplicate of bug 119335, that is already resolved. This bug is still valid, so this seems to be another bug, but it might be related.

Build: NetBeans IDE 7.3 Beta 2 (Build 201211062253)
VM: OpenJDK Client VM, 20.0-b12, OpenJDK Runtime Environment, 1.6.0_24-b24
OS: Linux

User Comments:
GUEST: avakldfjkldasklfdskl




Stacktrace: 
java.lang.NullPointerException
   at org.netbeans.modules.form.CodeCustomEditor.<init>(CodeCustomEditor.java:125)
   at org.netbeans.modules.form.RADConnectionPropertyEditor.getCustomEditor(RADConnectionPropertyEditor.java:184)
   at org.netbeans.modules.form.FormCustomEditor.<init>(FormCustomEditor.java:181)
   at org.netbeans.modules.form.FormPropertyEditor.getCustomEditor(FormPropertyEditor.java:325)
   at org.openide.explorer.propertysheet.PropertyDialogManager.<init>(PropertyDialogManager.java:132)
   at org.openide.explorer.propertysheet.CustomEditorAction.actionPerformed(CustomEditorAction.java:221)
Comment 1 Exceptions Reporter 2012-12-07 10:05:32 UTC
Created attachment 129032 [details]
stacktrace
Comment 2 Tomas Pavek 2013-01-03 12:30:32 UTC
The NPE in CodeCustomEditor.java:125 looks like if the property editor dialog was opened for an already closed form. Also the other exception in the messages.log in ResourceSupport.isExcludedProperty(ResourceSupport.java:913) indicates the same.

The only way I was able to reproduce this was by invoking the Properties window for a component (via the context menu Properties action), then closing the form. The properties window stays open, trying to click on the [...] button of some property leads to one of the above exceptions.

To fix this case I've made the explicitly opened properties window closed when the GUI form is closed.
http://hg.netbeans.org/jet-main/rev/bc1f1232c939

Also fixed two more (unrelated) exceptions found in the messages.log file:
http://hg.netbeans.org/jet-main/rev/4d51bcb3ecc9
http://hg.netbeans.org/jet-main/rev/0e2b4cfba7c9
Comment 3 Tomas Pavek 2013-01-03 13:05:48 UTC
*** Bug 214936 has been marked as a duplicate of this bug. ***
Comment 4 Quality Engineering 2013-01-04 02:32:12 UTC
Integrated into 'main-golden', will be available in build *201301040001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/bc1f1232c939
User: Tomas Pavek <tpavek@netbeans.org>
Log: #223466: don't let explicitly opened properties windows stay around for closed forms