Java实现窗体右键菜单.rar
Java实现窗体右键菜单,简约易操作的窗体菜单,这是一个相当易懂的制作实例。 super( "右键弹出菜单" ); //调用父类构造函数 ChangeColorAction action = new ChangeColorAction(); //菜单项事件处理 String[] str = {"Blue","Pink","Yellow","Red","Orange"}; //菜单项名称 ButtonGroup colorGroup=new ButtonGroup(); //实例化按钮组 popupMenu=new JPopupMenu(); //实例化弹出菜单
文件列表
JPopMenu.rar
(预估有个5文件)
codesc.net
Java右键弹出菜单
16-1.bmp
104KB
JPopMenuDemo$1.class
887B
JPopMenuDemo.java
2KB
JPopMenuDemo.class
2KB
JPopMenuDemo$ChangeColorAction.class
903B
暂无评论