MCPcopy Index your code
hub / github.com/BombusMod/BombusMod / menuAction

Method menuAction

src/main/java/Statistic/StatsWindow.java:96–121  ·  view source on GitHub ↗
(MenuCommand command, VirtualList displayable)

Source from the content-addressed store, hash-verified

94 }
95
96 public void menuAction(MenuCommand command, VirtualList displayable) {
97//#ifdef CLIPBOARD
98 if (command == cmdCopy) {
99 try {
100 String str = ((MultiLine) getFocusedObject()).toString();
101 if (str == null)
102 str = "";
103 ClipBoardIO.getInstance().setClipBoard(str);
104 } catch (Exception e) {/*no messages*/}
105 }
106
107 if (command == cmdCopyPlus) {
108 try {
109 String str = ((MultiLine) getFocusedObject()).toString();
110 if (str == null)
111 str = "";
112 ClipBoardIO.getInstance().append(str);
113 } catch (Exception e) {/*no messages*/}
114 }
115//#endif
116 if (command==cmdClear) {
117 st.saveToStorage(true);
118 cmdCancel();
119 }
120 super.menuAction(command, displayable);
121 }
122
123 public boolean doUserKeyAction(int command_id) {
124 switch (command_id) {

Callers

nothing calls this directly

Calls 8

getInstanceMethod · 0.95
getFocusedObjectMethod · 0.80
appendMethod · 0.80
menuActionMethod · 0.65
toStringMethod · 0.45
setClipBoardMethod · 0.45
saveToStorageMethod · 0.45
cmdCancelMethod · 0.45

Tested by

no test coverage detected