MCPcopy Create free account
hub / github.com/BombusMod/BombusMod / MyMenu

Method MyMenu

src/main/java/Menu/MyMenu.java:51–61  ·  view source on GitHub ↗

Creates a new instance of MyMenu @param parentView @param menuListener @param menuCommands @param caption @param il

(MenuListener menuListener, String caption, ImageList il, Vector menuCommands)

Source from the content-addressed store, hash-verified

49 * @param il
50 */
51 public MyMenu(MenuListener menuListener, String caption, ImageList il, Vector menuCommands) {
52 super(caption, il);
53 this.ml=menuListener;
54 this.commands = menuCommands;
55
56 for (int i=0; i<commands.size(); i++) {
57 MenuCommand c=(MenuCommand)commands.elementAt(i);
58 addItem(c.name, i, c.img);
59 }
60 show();
61 }
62
63 public void eventOk(){
64 MenuItem me=(MenuItem) getFocusedObject();

Callers

nothing calls this directly

Calls 3

addItemMethod · 0.80
sizeMethod · 0.45
showMethod · 0.45

Tested by

no test coverage detected