Class ModListWidget.ModEntry
java.lang.Object
net.minecraft.client.gui.components.AbstractSelectionList.Entry<ModListWidget.ModEntry>
net.minecraft.client.gui.components.ObjectSelectionList.Entry<ModListWidget.ModEntry>
net.neoforged.neoforge.client.gui.widget.ModListWidget.ModEntry
- All Implemented Interfaces:
GuiEventListener,TabOrderedElement,NarrationSupplier
- Enclosing class:
ModListWidget
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final net.neoforged.fml.ModContainerprivate final ModListScreenFields inherited from class net.minecraft.client.gui.components.AbstractSelectionList.Entry
listFields inherited from interface net.minecraft.client.gui.components.events.GuiEventListener
DOUBLE_CLICK_THRESHOLD_MS -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionnet.neoforged.fml.ModContainernet.neoforged.neoforgespi.language.IModInfogetInfo()booleanbooleanmouseClicked(double p_mouseClicked_1_, double p_mouseClicked_3_, int p_mouseClicked_5_) Called when a mouse button is clicked within the GUI element.voidrender(GuiGraphics guiGraphics, int entryIdx, int top, int left, int entryWidth, int entryHeight, int mouseX, int mouseY, boolean isMouseOver, float partialTick) voidsetFocused(boolean focused) Sets the focus state of the GUI element.Methods inherited from class net.minecraft.client.gui.components.ObjectSelectionList.Entry
updateNarrationMethods inherited from class net.minecraft.client.gui.components.AbstractSelectionList.Entry
isMouseOver, renderBackMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.minecraft.client.gui.components.events.GuiEventListener
charTyped, getBorderForArrowNavigation, getCurrentFocusPath, getRectangle, keyPressed, keyReleased, mouseDragged, mouseMoved, mouseReleased, mouseScrolled, nextFocusPathMethods inherited from interface net.minecraft.client.gui.components.TabOrderedElement
getTabOrderGroup
-
Field Details
-
container
private final net.neoforged.fml.ModContainer container -
parent
-
-
Constructor Details
-
ModEntry
ModEntry(net.neoforged.fml.ModContainer info, ModListScreen parent)
-
-
Method Details
-
getNarration
- Specified by:
getNarrationin classObjectSelectionList.Entry<ModListWidget.ModEntry>
-
render
public void render(GuiGraphics guiGraphics, int entryIdx, int top, int left, int entryWidth, int entryHeight, int mouseX, int mouseY, boolean isMouseOver, float partialTick) - Specified by:
renderin classAbstractSelectionList.Entry<ModListWidget.ModEntry>
-
mouseClicked
public boolean mouseClicked(double p_mouseClicked_1_, double p_mouseClicked_3_, int p_mouseClicked_5_) Description copied from interface:GuiEventListenerCalled when a mouse button is clicked within the GUI element.- Specified by:
mouseClickedin interfaceGuiEventListener- Overrides:
mouseClickedin classObjectSelectionList.Entry<ModListWidget.ModEntry>- Parameters:
p_mouseClicked_1_- the X coordinate of the mouse.p_mouseClicked_3_- the Y coordinate of the mouse.p_mouseClicked_5_- the button that was clicked.- Returns:
trueif the event is consumed,falseotherwise.
-
setFocused
public void setFocused(boolean focused) Description copied from interface:GuiEventListenerSets the focus state of the GUI element.- Specified by:
setFocusedin interfaceGuiEventListener- Overrides:
setFocusedin classAbstractSelectionList.Entry<ModListWidget.ModEntry>- Parameters:
focused-trueto apply focus,falseto remove focus
-
isFocused
public boolean isFocused()- Specified by:
isFocusedin interfaceGuiEventListener- Overrides:
isFocusedin classAbstractSelectionList.Entry<ModListWidget.ModEntry>
-
getInfo
public net.neoforged.neoforgespi.language.IModInfo getInfo() -
getContainer
public net.neoforged.fml.ModContainer getContainer()
-