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 104682

Summary: Get NPEs all the time when trying to access context menus
Product: utilities Reporter: Torbjorn Norbye <tor>
Component: DiffAssignee: diff-issues@utilities <diff-issues>
Status: RESOLVED DUPLICATE    
Severity: blocker    
Priority: P1    
Version: 5.x   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter:

Description Torbjorn Norbye 2007-05-24 01:03:05 UTC
Using a fresh trunk build both from this morning, and an updated build again this afternoon, on OSX:

I get NPEs all the time when trying to access context menus - and this exception is shown:

Annotation: You cannot add org.netbeans.modules.diff.PatchAction directly to a JMenu etc.; use 
org.openide.awt.Actions.connect instead
Annotation: You cannot add org.netbeans.modules.diff.PatchAction directly to a JMenu etc.; use 
org.openide.awt.Actions.connect instead
You cannot add org.netbeans.modules.diff.PatchAction directly to a JMenu etc.; use 
org.openide.awt.Actions.connect instead
You cannot add org.netbeans.modules.diff.PatchAction directly to a JMenu etc.; use 
org.openide.awt.Actions.connect instead
Caused: java.lang.NullPointerException
	at javax.swing.JMenuItem$MenuItemPropertyChangeListener.propertyChange(JMenuItem.java:390)
	at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:333)
	at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:270)
	at org.openide.util.SharedClassObject.firePropertyChange(SharedClassObject.java:432)
	at org.openide.util.actions.NodeAction.maybeFireEnabledChange(NodeAction.java:346)
	at org.openide.util.actions.NodeAction$NodesL$1.run(NodeAction.java:500)
	at org.openide.util.Mutex.doEvent(Mutex.java:1181)
	at org.openide.util.Mutex.readAccess(Mutex.java:287)
	at org.openide.util.actions.NodeAction$NodesL.forget(NodeAction.java:498)
	at org.openide.util.actions.NodeAction$NodesL.update(NodeAction.java:467)
	at org.openide.util.actions.NodeAction$NodesL.resultChanged(NodeAction.java:460)
	at org.openide.util.lookup.ProxyLookup.setLookups(ProxyLookup.java:170)
	at org.openide.explorer.DefaultEMLookup.updateLookups(DefaultEMLookup.java:109)
	at org.openide.explorer.DefaultEMLookup.propertyChange(DefaultEMLookup.java:141)
	at org.openide.util.WeakListenerImpl$PropertyChange.propertyChange(WeakListenerImpl.java:164)
	at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:333)
	at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:270)
	at org.openide.explorer.ExplorerManager$2.run(ExplorerManager.java:809)
	at org.openide.util.Mutex.doEvent(Mutex.java:1181)
	at org.openide.util.Mutex.readAccess(Mutex.java:287)
...
Comment 1 Peter Pis 2007-05-24 08:59:43 UTC

*** This issue has been marked as a duplicate of 104614 ***