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 80958 - NPE when substitution group is being changed
Summary: NPE when substitution group is being changed
Status: VERIFIED FIXED
Alias: None
Product: xml
Classification: Unclassified
Component: Schema Tools (show other bugs)
Version: 5.x
Hardware: PC Windows XP
: P1 blocker (vote)
Assignee: bhate
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-07-24 13:16 UTC by Andrei Chistiakov
Modified: 2006-07-25 13:20 UTC (History)
4 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andrei Chistiakov 2006-07-24 13:16:10 UTC
Reproduced in build 060723.

To reproduce the bug:

- create a new schema;
- add a new global element;
- in Properties edit substitution group of the element;
- in 'Global Element - Substitution Group' window select 'newElement'.

java.lang.NullPointerException
	at
org.netbeans.modules.xml.schema.ui.basic.UIUtilities.findNode(UIUtilities.java:178)
	at
org.netbeans.modules.xml.schema.ui.basic.editors.SchemaComponentSelectionPanel.propertyChange(SchemaComponentSelectionPanel.java:220)
	at
java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:339)
	at
java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:276)
	at org.openide.explorer.ExplorerManager$2.run(ExplorerManager.java:776)
	at org.openide.util.Mutex.doEvent(Mutex.java:1158)
	at org.openide.util.Mutex.readAccess(Mutex.java:284)
	at org.openide.explorer.ExplorerManager.fireInAWT(ExplorerManager.java:773)
	at org.openide.explorer.ExplorerManager.access$600(ExplorerManager.java:58)
	at
org.openide.explorer.ExplorerManager$1AtomicSetSelectedNodes.updateSelection(ExplorerManager.java:248)
	at
org.openide.explorer.ExplorerManager$1AtomicSetSelectedNodes.run(ExplorerManager.java:253)
	at org.openide.util.Mutex.readAccess(Mutex.java:293)
	at org.openide.explorer.ExplorerManager.setSelectedNodes(ExplorerManager.java:259)
	at
org.openide.explorer.ExplorerManager$1SetExploredContextAndSelection.run(ExplorerManager.java:340)
	at org.openide.util.Mutex.readAccess(Mutex.java:293)
	at
org.openide.explorer.ExplorerManager.setExploredContextAndSelection(ExplorerManager.java:353)
	at org.openide.explorer.view.BeanTreeView.selectionChanged(BeanTreeView.java:103)
	at org.openide.explorer.view.TreeView.callSelectionChanged(TreeView.java:710)
	at org.openide.explorer.view.TreeView$TreePropertyListener.run(TreeView.java:1245)
	at org.openide.util.Mutex.postRequest(Mutex.java:1119)
	at org.openide.util.Mutex.postReadRequest(Mutex.java:472)
	at
org.openide.explorer.view.TreeView$TreePropertyListener.valueChanged(TreeView.java:1216)
	at
javax.swing.tree.DefaultTreeSelectionModel.fireValueChanged(DefaultTreeSelectionModel.java:629)
	at
javax.swing.tree.DefaultTreeSelectionModel.notifyPathChange(DefaultTreeSelectionModel.java:1078)
	at
javax.swing.tree.DefaultTreeSelectionModel.setSelectionPaths(DefaultTreeSelectionModel.java:287)
	at
javax.swing.tree.DefaultTreeSelectionModel.setSelectionPath(DefaultTreeSelectionModel.java:170)
	at javax.swing.JTree.setSelectionPath(JTree.java:1604)
	at javax.swing.plaf.basic.BasicTreeUI.selectPathForEvent(BasicTreeUI.java:2410)
	at
javax.swing.plaf.basic.BasicTreeUI$Handler.handleSelection(BasicTreeUI.java:3619)
	at javax.swing.plaf.basic.BasicTreeUI$Handler.mousePressed(BasicTreeUI.java:3558)
	at java.awt.AWTEventMulticaster.mousePressed(AWTEventMulticaster.java:221)
	at java.awt.AWTEventMulticaster.mousePressed(AWTEventMulticaster.java:221)
	at java.awt.AWTEventMulticaster.mousePressed(AWTEventMulticaster.java:221)
	at java.awt.AWTEventMulticaster.mousePressed(AWTEventMulticaster.java:221)
	at java.awt.Component.processMouseEvent(Component.java:5996)
	at javax.swing.JComponent.processMouseEvent(JComponent.java:3240)
	at java.awt.Component.processEvent(Component.java:5764)
	at java.awt.Container.processEvent(Container.java:1984)
	at java.awt.Component.dispatchEventImpl(Component.java:4407)
	at java.awt.Container.dispatchEventImpl(Container.java:2042)
	at java.awt.Component.dispatchEvent(Component.java:4237)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4248)
	at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3909)
	at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3842)
	at java.awt.Container.dispatchEventImpl(Container.java:2028)
	at java.awt.Window.dispatchEventImpl(Window.java:2405)
	at java.awt.Component.dispatchEvent(Component.java:4237)
[catch] at java.awt.EventQueue.dispatchEvent(EventQueue.java:600)
	at
java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:273)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:183)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:177)
	at java.awt.Dialog$1.run(Dialog.java:1039)
	at java.awt.Dialog$2.run(Dialog.java:1085)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.awt.Dialog.show(Dialog.java:1083)
	at org.netbeans.core.windows.services.NbPresenter.superShow(NbPresenter.java:816)
	at org.netbeans.core.windows.services.NbPresenter.doShow(NbPresenter.java:859)
	at org.netbeans.core.windows.services.NbPresenter.run(NbPresenter.java:847)
	at org.openide.util.Mutex.doEventAccess(Mutex.java:1178)
	at org.openide.util.Mutex.readAccess(Mutex.java:215)
	at org.netbeans.core.windows.services.NbPresenter.show(NbPresenter.java:832)
	at
org.openide.explorer.propertysheet.CustomEditorAction.actionPerformed(CustomEditorAction.java:307)
	at org.openide.explorer.propertysheet.SheetTable.editCellAt(SheetTable.java:957)
	at
javax.swing.plaf.basic.BasicTableUI$Handler.adjustSelection(BasicTableUI.java:1084)
	at javax.swing.plaf.basic.BasicTableUI$Handler.mousePressed(BasicTableUI.java:1014)
	at java.awt.AWTEventMulticaster.mousePressed(AWTEventMulticaster.java:222)
	at java.awt.AWTEventMulticaster.mousePressed(AWTEventMulticaster.java:221)
	at java.awt.AWTEventMulticaster.mousePressed(AWTEventMulticaster.java:221)
	at java.awt.Component.processMouseEvent(Component.java:5996)
	at javax.swing.JComponent.processMouseEvent(JComponent.java:3240)
	at
org.openide.explorer.propertysheet.SheetTable.processMouseEvent(SheetTable.java:694)
	at java.awt.Component.processEvent(Component.java:5764)
	at java.awt.Container.processEvent(Container.java:1984)
	at java.awt.Component.dispatchEventImpl(Component.java:4407)
	at java.awt.Container.dispatchEventImpl(Container.java:2042)
	at java.awt.Component.dispatchEvent(Component.java:4237)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4248)
	at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3909)
	at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3842)
	at java.awt.Container.dispatchEventImpl(Container.java:2028)
	at java.awt.Window.dispatchEventImpl(Window.java:2405)
	at java.awt.Component.dispatchEvent(Component.java:4237)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:600)
	at
java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:273)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:183)
	at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:173)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:168)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:160)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:121)
Comment 1 bhate 2006-07-24 19:06:24 UTC
currentselection maybe null if rsc is in exclude
check for it not null
Comment 2 Andrei Chistiakov 2006-07-25 13:20:03 UTC
Verified in build 060724.