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 17911 - Can't open right click menu on java file
Summary: Can't open right click menu on java file
Status: CLOSED FIXED
Alias: None
Product: platform
Classification: Unclassified
Component: Actions (show other bugs)
Version: 3.x
Hardware: Sun Solaris
: P1 blocker (vote)
Assignee: Jesse Glick
URL:
Keywords:
Depends on:
Blocks: 18017
  Show dependency tree
 
Reported: 2001-11-20 23:41 UTC by Rochelle Raccah
Modified: 2008-12-22 23:22 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
stack trace (2.56 KB, text/plain)
2001-11-20 23:43 UTC, Rochelle Raccah
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Rochelle Raccah 2001-11-20 23:41:40 UTC
In the FFJ builds, the persistence module adds an action directly to the java
data loader's menu.  Right clicking on the colorpicker/ColorPreview java file in
the build from 11/16 is fine, but doing the same thing from an evening build on
11/19 causes a NPE.  The stack trace is attached, but the interesting line is at
org.openide.util.actions.CookieAction.enable(CookieAction.java:102) which has
the code listener.setNodes(activatedNodes);

CookieAction.java changed on 11/19 and the cvs commit message for that revision
(1.19) mentions cleanup of listener handling, so I suspect the persistence
module has exposed a case where listener is not properly initialized after the
cleanup.
Comment 1 Rochelle Raccah 2001-11-20 23:43:25 UTC
Created attachment 3503 [details]
stack trace
Comment 2 _ ttran 2001-11-21 08:49:19 UTC
CookieAction cannot be at fault here.  The listener field is created
in CookieAction.initialize() method and never changes.  Very likely
some subclass overrides this method but forgets to call
super.initialize() or  something similar.  
Comment 3 Rochelle Raccah 2001-11-28 20:46:55 UTC
This is actually a core issue and has been fixed by Jesse's fix for
issue 18017.
Comment 4 Rochelle Raccah 2001-11-28 20:48:22 UTC
Marking as fixed as per earlier comments.
Comment 5 Jesse Glick 2001-11-29 11:27:04 UTC
I doubt this is a duplicate of issue 18017 fixed in 1.20.2.1, but
anyway 1.20 should have fixed this.
Comment 6 Jan Zajicek 2001-11-30 09:44:54 UTC
verified in 011129_2
Comment 7 Jesse Glick 2001-11-30 11:57:42 UTC
Just making a link between the two bug #s.

BTW the problem here was that enable(Node[]), normally called *by*
CookieAction, was here called from other code, without the action
having been first initialized. Unusual but not specifically
prohibited.

The fix for #18017 rolls back 1.20 and fixes the same apparent problem
in a better way which covers other scenarios.
Comment 8 Quality Engineering 2003-07-01 16:16:02 UTC
Resolved for 3.4.x or earlier, no new info since then -> closing.