标签: java swing user-interface jpopupmenu
我想知道如何弹出仅在特定范围内显示的JPopupMenu,例如(200,300)和(400,400)之间。
JPopupMenu
答案 0 :(得分:1)
java.awt.Rectangle
MouseListener
mouseClicked
mousePressed
mouseReleased
popupTrigger
Rectangle
containts
MouseEvent
show
有关详细信息,请查看How to Write a Mouse Listener和How to Use Menus