Package net.minecraft

Class class_7838

All Implemented Interfaces:
Drawable, Element, Narratable, ParentElement, Selectable
Direct Known Subclasses:
class_7843, class_7845, class_7849

@Environment(CLIENT) public abstract class class_7838 extends ClickableWidget implements ParentElement
Mappings:
Namespace Name
official ejs
intermediary net/minecraft/class_7838
named net/minecraft/class_7838
  • Field Details

    • field_40750

      @Nullable private @Nullable Element field_40750
      Mappings:
      Namespace Name Mixin selector
      official a Lejs;a:Lelg;
      intermediary field_40750 Lnet/minecraft/class_7838;field_40750:Lnet/minecraft/class_364;
      named field_40750 Lnet/minecraft/class_7838;field_40750:Lnet/minecraft/client/gui/Element;
    • field_40751

      private boolean field_40751
      Mappings:
      Namespace Name Mixin selector
      official b Lejs;b:Z
      intermediary field_40751 Lnet/minecraft/class_7838;field_40751:Z
      named field_40751 Lnet/minecraft/class_7838;field_40751:Z
  • Constructor Details

    • class_7838

      public class_7838(int x, int y, int width, int height, Text message)
      Mappings:
      Namespace Name Mixin selector
      official <init> Lejx;<init>(IIIILsf;)V
      intermediary <init> Lnet/minecraft/class_339;<init>(IIIILnet/minecraft/class_2561;)V
      named <init> Lnet/minecraft/client/gui/widget/ClickableWidget;<init>(IIIILnet/minecraft/text/Text;)V
  • Method Details

    • renderButton

      public void renderButton(MatrixStack matrices, int mouseX, int mouseY, float delta)
      Overrides:
      renderButton in class ClickableWidget
      Mappings:
      Namespace Name Mixin selector
      official b Lejx;b(Ledc;IIF)V
      intermediary method_25359 Lnet/minecraft/class_339;method_25359(Lnet/minecraft/class_4587;IIF)V
      named renderButton Lnet/minecraft/client/gui/widget/ClickableWidget;renderButton(Lnet/minecraft/client/util/math/MatrixStack;IIF)V
    • isMouseOver

      public boolean isMouseOver(double mouseX, double mouseY)
      Checks if the mouse position is within the bound of the element.
      Specified by:
      isMouseOver in interface Element
      Overrides:
      isMouseOver in class ClickableWidget
      Parameters:
      mouseX - the X coordinate of the mouse
      mouseY - the Y coordinate of the mouse
      Returns:
      true if the mouse is within the bound of the element, otherwise false
      Mappings:
      Namespace Name Mixin selector
      official c Lelg;c(DD)Z
      intermediary method_25405 Lnet/minecraft/class_364;method_25405(DD)Z
      named isMouseOver Lnet/minecraft/client/gui/Element;isMouseOver(DD)Z
    • mouseMoved

      public void mouseMoved(double mouseX, double mouseY)
      Callback for when a mouse move event has been captured.
      Specified by:
      mouseMoved in interface Element
      Parameters:
      mouseX - the X coordinate of the mouse
      mouseY - the Y coordinate of the mouse
      See Also:
      Mappings:
      Namespace Name Mixin selector
      official d Lelg;d(DD)V
      intermediary method_16014 Lnet/minecraft/class_364;method_16014(DD)V
      named mouseMoved Lnet/minecraft/client/gui/Element;mouseMoved(DD)V
    • children

      public List<? extends Element> children()
      Gets a list of all child GUI elements.
      Specified by:
      children in interface ParentElement
      Mappings:
      Namespace Name Mixin selector
      official aj_ Lelf;aj_()Ljava/util/List;
      intermediary method_25396 Lnet/minecraft/class_4069;method_25396()Ljava/util/List;
      named children Lnet/minecraft/client/gui/ParentElement;children()Ljava/util/List;
    • method_46418

      protected abstract List<? extends ClickableWidget> method_46418()
      Mappings:
      Namespace Name Mixin selector
      official b Lejs;b()Ljava/util/List;
      intermediary method_46418 Lnet/minecraft/class_7838;method_46418()Ljava/util/List;
      named method_46418 Lnet/minecraft/class_7838;method_46418()Ljava/util/List;
    • isDragging

      public boolean isDragging()
      Specified by:
      isDragging in interface ParentElement
      Mappings:
      Namespace Name Mixin selector
      official al_ Lelf;al_()Z
      intermediary method_25397 Lnet/minecraft/class_4069;method_25397()Z
      named isDragging Lnet/minecraft/client/gui/ParentElement;isDragging()Z
    • setDragging

      public void setDragging(boolean dragging)
      Specified by:
      setDragging in interface ParentElement
      Mappings:
      Namespace Name Mixin selector
      official b_ Lelf;b_(Z)V
      intermediary method_25398 Lnet/minecraft/class_4069;method_25398(Z)V
      named setDragging Lnet/minecraft/client/gui/ParentElement;setDragging(Z)V
    • mouseScrolled

      public boolean mouseScrolled(double mouseX, double mouseY, double amount)
      Callback for when a mouse button scroll event has been captured.
      Specified by:
      mouseScrolled in interface Element
      Specified by:
      mouseScrolled in interface ParentElement
      Parameters:
      mouseX - the X coordinate of the mouse
      mouseY - the Y coordinate of the mouse
      amount - value is < 0 if scrolled down, > 0 if scrolled up
      Returns:
      true to indicate that the event handling is successful/valid
      See Also:
      Mappings:
      Namespace Name Mixin selector
      official a Lelg;a(DDD)Z
      intermediary method_25401 Lnet/minecraft/class_364;method_25401(DDD)Z
      named mouseScrolled Lnet/minecraft/client/gui/Element;mouseScrolled(DDD)Z
    • changeFocus

      public boolean changeFocus(boolean lookForwards)
      Changes the focusing element by cycling to the next/previous element. This action is done typically when the user has pressed the 'Tab' or 'Ctrl+Tab' key.
      Specified by:
      changeFocus in interface Element
      Specified by:
      changeFocus in interface ParentElement
      Overrides:
      changeFocus in class ClickableWidget
      Parameters:
      lookForwards - true to cycle forwards, otherwise cycle backwards
      Returns:
      true to indicate that the event handling is successful/valid
      Mappings:
      Namespace Name Mixin selector
      official b Lelg;b(Z)Z
      intermediary method_25407 Lnet/minecraft/class_364;method_25407(Z)Z
      named changeFocus Lnet/minecraft/client/gui/Element;changeFocus(Z)Z
    • method_46420

      @Nullable protected @Nullable Element method_46420()
      Mappings:
      Namespace Name Mixin selector
      official d Lejs;d()Lelg;
      intermediary method_46420 Lnet/minecraft/class_7838;method_46420()Lnet/minecraft/class_364;
      named method_46420 Lnet/minecraft/class_7838;method_46420()Lnet/minecraft/client/gui/Element;
    • getFocused

      @Nullable public @Nullable Element getFocused()
      Specified by:
      getFocused in interface ParentElement
      Mappings:
      Namespace Name Mixin selector
      official am_ Lelf;am_()Lelg;
      intermediary method_25399 Lnet/minecraft/class_4069;method_25399()Lnet/minecraft/class_364;
      named getFocused Lnet/minecraft/client/gui/ParentElement;getFocused()Lnet/minecraft/client/gui/Element;
    • setFocused

      public void setFocused(@Nullable @Nullable Element focused)
      Specified by:
      setFocused in interface ParentElement
      Mappings:
      Namespace Name Mixin selector
      official a Lelf;a(Lelg;)V
      intermediary method_25395 Lnet/minecraft/class_4069;method_25395(Lnet/minecraft/class_364;)V
      named setFocused Lnet/minecraft/client/gui/ParentElement;setFocused(Lnet/minecraft/client/gui/Element;)V
    • appendNarrations

      public void appendNarrations(NarrationMessageBuilder builder)
      Specified by:
      appendNarrations in interface Narratable
      Mappings:
      Namespace Name Mixin selector
      official a Leml;a(Lemk;)V
      intermediary method_37020 Lnet/minecraft/class_6383;method_37020(Lnet/minecraft/class_6382;)V
      named appendNarrations Lnet/minecraft/client/gui/Narratable;appendNarrations(Lnet/minecraft/client/gui/screen/narration/NarrationMessageBuilder;)V
    • getType

      public Selectable.SelectionType getType()
      Specified by:
      getType in interface Selectable
      Overrides:
      getType in class ClickableWidget
      Mappings:
      Namespace Name Mixin selector
      official ap_ Lemi;ap_()Lemi$a;
      intermediary method_37018 Lnet/minecraft/class_6379;method_37018()Lnet/minecraft/class_6379$class_6380;
      named getType Lnet/minecraft/client/gui/Selectable;getType()Lnet/minecraft/client/gui/Selectable$SelectionType;
    • method_46421

      public void method_46421(int int2)
      Overrides:
      method_46421 in class ClickableWidget
      Mappings:
      Namespace Name Mixin selector
      official h_ Lejx;h_(I)V
      intermediary method_46421 Lnet/minecraft/class_339;method_46421(I)V
      named method_46421 Lnet/minecraft/client/gui/widget/ClickableWidget;method_46421(I)V
    • method_46419

      public void method_46419(int int2)
      Overrides:
      method_46419 in class ClickableWidget
      Mappings:
      Namespace Name Mixin selector
      official b Lejx;b(I)V
      intermediary method_46419 Lnet/minecraft/class_339;method_46419(I)V
      named method_46419 Lnet/minecraft/client/gui/widget/ClickableWidget;method_46419(I)V
    • hoveredElement

      public Optional<Element> hoveredElement(double mouseX, double mouseY)
      Specified by:
      hoveredElement in interface ParentElement
      Mappings:
      Namespace Name Mixin selector
      official e Lelf;e(DD)Ljava/util/Optional;
      intermediary method_19355 Lnet/minecraft/class_4069;method_19355(DD)Ljava/util/Optional;
      named hoveredElement Lnet/minecraft/client/gui/ParentElement;hoveredElement(DD)Ljava/util/Optional;
    • mouseClicked

      public boolean mouseClicked(double mouseX, double mouseY, int button)
      Callback for when a mouse button down event has been captured. The button number is identified by the constants in GLFW class.
      Specified by:
      mouseClicked in interface Element
      Specified by:
      mouseClicked in interface ParentElement
      Overrides:
      mouseClicked in class ClickableWidget
      Parameters:
      mouseX - the X coordinate of the mouse
      mouseY - the Y coordinate of the mouse
      button - the mouse button number
      Returns:
      true to indicate that the event handling is successful/valid
      See Also:
      Mappings:
      Namespace Name Mixin selector
      official a Lelg;a(DDI)Z
      intermediary method_25402 Lnet/minecraft/class_364;method_25402(DDI)Z
      named mouseClicked Lnet/minecraft/client/gui/Element;mouseClicked(DDI)Z
    • mouseReleased

      public boolean mouseReleased(double mouseX, double mouseY, int button)
      Callback for when a mouse button release event has been captured. The button number is identified by the constants in GLFW class.
      Specified by:
      mouseReleased in interface Element
      Specified by:
      mouseReleased in interface ParentElement
      Overrides:
      mouseReleased in class ClickableWidget
      Parameters:
      mouseX - the X coordinate of the mouse
      mouseY - the Y coordinate of the mouse
      button - the mouse button number
      Returns:
      true to indicate that the event handling is successful/valid
      See Also:
      Mappings:
      Namespace Name Mixin selector
      official b Lelg;b(DDI)Z
      intermediary method_25406 Lnet/minecraft/class_364;method_25406(DDI)Z
      named mouseReleased Lnet/minecraft/client/gui/Element;mouseReleased(DDI)Z
    • mouseDragged

      public boolean mouseDragged(double mouseX, double mouseY, int button, double deltaX, double deltaY)
      Callback for when a mouse button drag event has been captured. The button number is identified by the constants in GLFW class.
      Specified by:
      mouseDragged in interface Element
      Specified by:
      mouseDragged in interface ParentElement
      Overrides:
      mouseDragged in class ClickableWidget
      Parameters:
      mouseX - the current X coordinate of the mouse
      mouseY - the current Y coordinate of the mouse
      button - the mouse button number
      deltaX - the difference of the current X with the previous X coordinate
      deltaY - the difference of the current Y with the previous Y coordinate
      Returns:
      true to indicate that the event handling is successful/valid
      See Also:
      Mappings:
      Namespace Name Mixin selector
      official a Lelg;a(DDIDD)Z
      intermediary method_25403 Lnet/minecraft/class_364;method_25403(DDIDD)Z
      named mouseDragged Lnet/minecraft/client/gui/Element;mouseDragged(DDIDD)Z