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.
Repro Steps: - create a collaboration diagram - add and name 2 lifeline elements - connect the 2 lifeline elements with the Connector link - select the Connector link - press Shift-F10 and no menu pops up
attached NullPointerException appears in ide-coco-061121_17.
Created attachment 36203 [details] NPE on shift+F10 for connector
Forced TestBedMenuManager.getLocation() to return (0,0) if the location had not been set. As is the case when the popup menu is displayed via accelerator.
verified in build 061127_12
I had to revert the change, because it caused another problem.
I have made the connector link behave correctly when the mouse location is not valid (i.e. null). The problem is that when you use the keyboard to open the context menu, you do not have a valid mouse location, so null is being returned. So, the original solution was just to default to return a mouse location of [0,0]. That does not work for nodes like the class. In this case, we need to know that the context menu is being opened by the keyboard, not the mouse. So, when the mouse location is not valid, it also adds menu item for the list compartments (add attributes, and add operations are added). When we default point [0,0] the draw engine can not determine if this location was generated by the mouse, or because of a keyboard event.
verified in build 061130_7.