Class EntityEditComponentPanel.InputFocus.Initial

java.lang.Object
is.codion.swing.framework.ui.EntityEditComponentPanel.InputFocus.Initial
Enclosing class:
EntityEditComponentPanel.InputFocus

public final class EntityEditComponentPanel.InputFocus.Initial extends Object
Manages the component that should receive the initial focus when the panel is activated.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Requests the initial focus, if an initial focus component or component attribute has been set, that component receives the focus, if not, or if that component is not focusable, this panel receives the focus.
    void
    set(Attribute<?> attribute)
    Sets the component associated with the given attribute as the component that should receive the initial focus in this edit panel.
    void
    set(Supplier<JComponent> component)
    Sets the Supplier supplying the component that should receive the focus when this edit panel is cleared or activated.
    void
    set(JComponent component)
    Sets the the component that should receive the focus when this edit panel is cleared or activated.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • set

      public void set(JComponent component)

      Sets the the component that should receive the focus when this edit panel is cleared or activated.

      Parameters:
      component - the component that should receive the focus when this edit panel is cleared or activated
    • set

      public void set(Attribute<?> attribute)
      Sets the component associated with the given attribute as the component that should receive the initial focus in this edit panel.
      Parameters:
      attribute - the attribute which component should receive the focus this edit panel is cleared or activated
    • set

      public void set(Supplier<JComponent> component)

      Sets the Supplier supplying the component that should receive the focus when this edit panel is cleared or activated.

      Parameters:
      component - supplies the component that should receive the focus when this edit panel is cleared or activated
    • request

      public void request()

      Requests the initial focus, if an initial focus component or component attribute has been set, that component receives the focus, if not, or if that component is not focusable, this panel receives the focus.

      Note that if this panel is not visible then calling this method has no effect.