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 103217 - NPE after dragging panel to Tabbed Pane
Summary: NPE after dragging panel to Tabbed Pane
Status: VERIFIED FIXED
Alias: None
Product: guibuilder
Classification: Unclassified
Component: Code (show other bugs)
Version: 6.x
Hardware: All All
: P1 blocker (vote)
Assignee: issues@guibuilder
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-05-03 10:49 UTC by novakm
Modified: 2007-11-22 15:25 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
First NPE stacktrace (1.45 KB, text/plain)
2007-05-03 11:06 UTC, novakm
Details
Second NPE stacktrace (1.20 KB, text/plain)
2007-05-03 11:07 UTC, novakm
Details
Todays first NPE stacktrace (1.97 KB, text/plain)
2007-05-04 13:50 UTC, novakm
Details
Todays second NPE stacktrace (1.48 KB, application/octet-stream)
2007-05-04 13:50 UTC, novakm
Details
Todays second NPE stacktrace (1.48 KB, text/plain)
2007-05-04 13:51 UTC, novakm
Details

Note You need to log in before you can comment on or make changes to this bug.
Description novakm 2007-05-03 10:49:34 UTC
Steps to reproduce:
1) Create a new project and add new JPanel
2) Add a Tabbed Pane component
3) Add a Panel to that tabbed pane
4) Add another Panel to that tabbed pane (it will be in the first panel)
5) Drag & drop the second panel to the Tabbed pane in the Inspector
result:
Following NPEs are thrown:
java.lang.NullPointerException
	at org.netbeans.modules.form.FormDesigner.checkDesignerSize(FormDesigner.java:814)
	at org.netbeans.modules.form.FormDesigner.access$1700(FormDesigner.java:76)
...

Since then, the designer is broken...

----
NetBeans IDE 6.0 Preview (M9, build 070502)
1.6.0_01; Java HotSpot(TM) Client VM 1.6.0_01-b06
Windows Vista version 6.0 running on x86
en_GB (nb); Cp1252
Comment 1 novakm 2007-05-03 11:06:40 UTC
Created attachment 42089 [details]
First NPE stacktrace
Comment 2 novakm 2007-05-03 11:07:22 UTC
Created attachment 42090 [details]
Second NPE stacktrace
Comment 3 Max Sauer 2007-05-03 12:13:50 UTC
This issue causes data loss. Form cannot be saved after above described scenerio
is performed.
Comment 4 Jana Maleckova 2007-05-03 15:20:49 UTC
I am not able to reproduce it :(
Comment 5 Peter Pis 2007-05-03 15:29:55 UTC
I have also reproduced this. Just put the second panel to the same level as the
first one.
Comment 6 Jana Maleckova 2007-05-03 15:53:18 UTC
Martin is really right. No I can reproduce it and after described steps, form is
not possible to save. Each attempt is terminated with exception. In my case,
data wasn't lost in every case but it happened often.
Seems, when the last step is done, variable declaration of jPanel2 disappears
from code.
Tested on 5.5 and these steps passed.
workaround is: delete the last added panel in inspector and then user can
continue working with this form.
But it's really awful and should be fixed
Comment 7 novakm 2007-05-04 13:48:29 UTC
It's strange, but following my own scenario I'm getting different two NPEs
today. I am quite sure that I attached the right files as their time of creation
match. And I didn't encounter any other NPEs yesterday. I'll attach those NPEs
from today as well.
Comment 8 novakm 2007-05-04 13:50:16 UTC
Created attachment 42133 [details]
Todays first NPE stacktrace
Comment 9 novakm 2007-05-04 13:50:46 UTC
Created attachment 42134 [details]
Todays second NPE stacktrace
Comment 10 novakm 2007-05-04 13:51:00 UTC
Created attachment 42135 [details]
Todays second NPE stacktrace
Comment 11 novakm 2007-05-04 13:53:19 UTC
Sorry, I didn't select the right filetype and then didn't manage to stop browser
fast enough, so the NPE4.txt file is attached two times.
Comment 12 Jan Stola 2007-05-14 18:18:19 UTC
I am able to reproduce this issue in M9 build. The same steps work correctly in 
the latest development build. So, it seems that this issue has been already 
fixed as a part of another fix. Hence, closing as FIXED.
Comment 13 novakm 2007-05-15 09:26:33 UTC
Verified.
Comment 14 Jana Maleckova 2007-11-22 15:25:28 UTC
tested on NetBeans IDE 6.0 RC2 (Build 200711201000)