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 36796

Summary: Last item in Document Window contextual menu is separator
Product: platform Reporter: Marian Mirilovic <mmirilovic>
Component: Window SystemAssignee: Petr Nejedly <pnejedly>
Status: VERIFIED FIXED    
Severity: blocker CC: mslama, pzavadsky
Priority: P4    
Version: 3.x   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter:
Attachments: Document Window Menu

Description Marian Mirilovic 2003-10-23 14:44:02 UTC
[nb winsys](031022), [jdk1.4.2_02]

see attached screenshot
Comment 1 Marian Mirilovic 2003-10-23 14:44:27 UTC
Created attachment 11948 [details]
Document Window Menu
Comment 2 Peter Zavadsky 2003-10-23 14:54:24 UTC
This is a problem of CloneableEditor which adds FilesystemsAction into
its popup actions.

That action is JInlineAction which in that case is empty, but the
popup creator doesn't know about that and includes it there which
causes the double separators to appear.
Comment 3 Petr Nejedly 2004-01-07 13:24:28 UTC
Looking at the problem...
Comment 4 Petr Nejedly 2004-01-07 15:04:57 UTC
It seems there is one explicit separator forced by the CloneableEditor
and another one added at the top of JInlineMenu
(which is used as a FSAction presenter).
If I remove the explicit one, JIM still adds it, but it can be fixed
to not add it if it is actually empty...
Comment 5 Petr Nejedly 2004-01-07 16:02:45 UTC
The CloneableEditor part of the problem is fixed.
The rest of the problem is that JInlineMenu keeps adding
"pre-separator" even when it have no items itself and is the last entry.

openide/src/org/openide/text/CloneableEditor.java,v1.64
Comment 6 Marian Mirilovic 2004-12-21 08:04:45 UTC
I guess this won't be fixed for NB4.0 , please evaluate again.
Comment 7 Marian Mirilovic 2005-10-18 09:07:48 UTC
It looks like it has been fixed. Also the menu has been redesigned for NB5.0.
It works in NB5.0(200510171800), JDK1.5.0_06
Comment 8 Marian Mirilovic 2005-10-19 13:22:52 UTC
verified in NB5.0(200510190645)