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

Method drawSlot

Minecraft-Utils/1.13/src/FileSelector.java:236–245  ·  view source on GitHub ↗
(int id, int x, int y, int padding, int mouseX, int mouseY)

Source from the content-addressed store, hash-verified

234 }
235
236 protected void drawSlot(int id, int x, int y, int padding, int mouseX, int mouseY) {
237 File file = getFile(id);
238 if (file == null)
239 return;
240 String name = file.getName();
241 if (currentDir == null) {
242 name = fsv.getSystemDisplayName(file);
243 }
244 MinecraftFactory.getVars().drawString(MinecraftFactory.getVars().shortenToWidth(name, selectionBoxWidth - 18), x + 2, y + 2);
245 }
246
247 public boolean isSelected(int id) {
248 return selectedFile == id;

Callers 1

drawSelectionBoxMethod · 0.95

Calls 5

getFileMethod · 0.95
getVarsMethod · 0.95
drawStringMethod · 0.65
shortenToWidthMethod · 0.65
getNameMethod · 0.45

Tested by

no test coverage detected