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

Method scroll

Minecraft-Utils/1.10/src/Gui2ndChat.java:246–259  ·  view source on GitHub ↗
(int scroll)

Source from the content-addressed store, hash-verified

244 }
245
246 @Override
247 public void scroll(int scroll) {
248 this.scrollPos += scroll;
249 int chatLines = this.singleChatLines.size();
250 if (this.scrollPos > chatLines - this.getLineCount()) {
251 this.scrollPos = chatLines - this.getLineCount();
252 }
253
254 if (this.scrollPos <= 0) {
255 this.scrollPos = 0;
256 this.isScrolled = false;
257 }
258
259 }
260
261 @Override
262 public void drawComponentHover(int mouseX, int mouseY) {

Callers 2

setChatLineMethod · 0.95
keyTypedMethod · 0.95

Calls 2

getLineCountMethod · 0.95
sizeMethod · 0.80

Tested by

no test coverage detected