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 106285 - MENU: Exception after right mouse click outside the menu bar
Summary: MENU: Exception after right mouse click outside the menu bar
Status: VERIFIED FIXED
Alias: None
Product: guibuilder
Classification: Unclassified
Component: Code (show other bugs)
Version: 6.x
Hardware: All Linux
: P3 blocker (vote)
Assignee: Joshua Marinacci
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-06-11 15:45 UTC by Jiri Vagner
Modified: 2007-07-20 13:22 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
exception.txt (1.89 KB, text/plain)
2007-06-11 15:46 UTC, Jiri Vagner
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jiri Vagner 2007-06-11 15:45:04 UTC
Steps to reproduce:
 - create JFrame form
 - add JMenuBar component
 - doubleclick on menu bar inside Inspector
 - click right mouse in design window outside the menu bar


java.awt.IllegalComponentStateException: component must be showing on the screen
to determine its location
	at java.awt.Component.getLocationOnScreen_NoTreeLock(Component.java:1800)
	at java.awt.Component.getLocationOnScreen(Component.java:1774)
	at javax.swing.JPopupMenu.show(JPopupMenu.java:909)
	at
org.netbeans.modules.form.menu.MenuEditLayer.showContextMenu(MenuEditLayer.java:593)


Product Version: NetBeans IDE Dev (Build 200706111212)
Java: 1.6.0_02-ea; Java HotSpot(TM) Client VM 1.6.0_02-ea-b02
System: Linux version 2.6.17-10-386 running on i386; UTF-8; en_US (nb)
Comment 1 Jiri Vagner 2007-06-11 15:46:13 UTC
Created attachment 43507 [details]
exception.txt
Comment 2 Joshua Marinacci 2007-07-12 22:00:23 UTC
This was caused by trying to show a context menu using the MenuEditLayer when that layer was not visible. Now the MenuEditLayer will be set to visible 
before showing the context menu
Comment 3 Jiri Vagner 2007-07-20 13:22:47 UTC
Verified

Product Version: NetBeans IDE Dev (Build 200707190325)
Java: 1.6.0_02; Java HotSpot(TM) Client VM 1.6.0_02-b05
System: Linux version 2.6.20-16-generic running on i386; UTF-8; en_US (nb)