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 64342 - IllegalArgumentException when moving two components outside JFrame's border
Summary: IllegalArgumentException when moving two components outside JFrame's border
Status: VERIFIED FIXED
Alias: None
Product: guibuilder
Classification: Unclassified
Component: Natural Layout (show other bugs)
Version: 5.x
Hardware: Sun Solaris
: P2 blocker (vote)
Assignee: issues@guibuilder
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-09-14 13:43 UTC by Max Sauer
Modified: 2005-09-15 09:54 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
exception stack traces (3.20 KB, text/plain)
2005-09-14 13:43 UTC, Max Sauer
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Max Sauer 2005-09-14 13:43:03 UTC
When moving two larger components selected at once and exceeding JFrame's
border, following two exceptions may pop up:

java.lang.IllegalArgumentException: An explored context (jScrollPane1
[JScrollPane]) must be within the root context (Form NewJFrame7).
	at org.openide.explorer.ExplorerManager.checkUnderRoot(ExplorerManager.java:488)
	at org.openide.explorer.ExplorerManager.access$300(ExplorerManager.java:52)
	at
org.openide.explorer.ExplorerManager$1SetExploredContextAndSelection.run(ExplorerManager.java:333)
	at org.openide.util.Mutex.readAccess(Mutex.java:261)
...
or

java.lang.IllegalArgumentException: A node selection cannot contain nodes
(jTree3 [JTree]) not underneath the root (Form NewJFrame).
	at org.openide.explorer.ExplorerManager.checkUnderRoot(ExplorerManager.java:488)
	at org.openide.explorer.ExplorerManager.access$300(ExplorerManager.java:52)
	at
org.openide.explorer.ExplorerManager$1AtomicSetSelectedNodes.checkArgumentIsValid(ExplorerManager.java:194)
	at
org.openide.explorer.ExplorerManager$1AtomicSetSelectedNodes.run(ExplorerManager.java:246)
...
(stack traces attached)

Steps to reproduce:
---------------------
1) Create a JFrame Form
2) Add two JTrees, align them together (I have also tried two larger JTextPanes)
3) Select both
4) Move them partially or whole outside of JFrame's border
--> exceptions

[200509131800, JDK 1.5.0_05 b03, solaris 10/sparc]
Comment 1 Max Sauer 2005-09-14 13:43:59 UTC
Created attachment 24795 [details]
exception stack traces
Comment 2 Milan Kubec 2005-09-14 16:26:21 UTC
Raising priority, very easily achievable exception and lost layout - those
components are moved to Other Components node (they are not visible in the form).
Comment 3 Jan Stola 2005-09-14 17:22:12 UTC
The components are moved to Other components because they were dropped there.
The exception is harmless, but I am fixing it preferentially because it
has been identified as high priority issue :-/.
Comment 4 Max Sauer 2005-09-15 09:54:08 UTC
The exceptions have been fixed well, thanks. (Verified in 200509141800)
But the behaviour of moving one component differ from behaviur of moving two --
I filed issue 64409 against it (P4).