MCPcopy Create free account
hub / github.com/5zig/The-5zig-Mod / initGui

Method initGui

The 5zig Mod/src/eu/the5zig/mod/gui/GuiLanguage.java:24–37  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

22 }
23
24 @Override
25 public void initGui() {
26 languages.clear();
27 addButton(The5zigMod.getVars().createButton(100, getWidth() / 2 - 100, getHeight() - 40, The5zigMod.getVars().translate("gui.done")));
28
29 for (Locale locale : I18n.getLanguages()) {
30 languages.add(new LanguageRow(locale));
31 }
32 languageSlot = The5zigMod.getVars().createGuiList(null, getWidth(), getHeight(), 32, getHeight() - 64, 0, getWidth(), languages);
33 languageSlot.setRowWidth(200);
34 languageSlot.setScrollX(getWidth() / 2 + 150);
35 languageSlot.setSelectedId(I18n.getLanguages().indexOf(I18n.getCurrentLanguage()));
36 addGuiList(languageSlot);
37 }
38
39 @Override
40 protected void actionPerformed(IButton button) {

Callers

nothing calls this directly

Calls 15

getVarsMethod · 0.95
getLanguagesMethod · 0.95
getCurrentLanguageMethod · 0.95
addButtonMethod · 0.80
addGuiListMethod · 0.80
clearMethod · 0.65
createButtonMethod · 0.65
getWidthMethod · 0.65
getHeightMethod · 0.65
translateMethod · 0.65
createGuiListMethod · 0.65
setRowWidthMethod · 0.65

Tested by

no test coverage detected