Interface Closable<S extends Closable<S>>

Type Parameters:
S - the control's own type, which close() returns
All Superinterfaces:
EventTarget<S>
All Known Subinterfaces:
ComboBox<T>, DatePicker, DateTimePicker, DropDownButton, Flyout, InfoBar, Menu, Openable<S>, Overlay, Popup<S>, TimePicker, Window

public interface Closable<S extends Closable<S>> extends EventTarget<S>
Something that can be closed, such as a window, an overlay, a combo box's list or a menu.

Do not implement this interface.

  • Field Details

    • CLOSE

      static final EventType<RequestEvent<Closable<?>>> CLOSE
      Asked before the user closes it, as each implementation describes, such as a press on a window's close button or Escape. Cancel it to keep it open. Fires only for the user's actions, and only where the implementation says so.
    • CLOSED

      static final EventType<ControlEvent<Closable<?>>> CLOSED
      Told after it closed, by the user or from code.
  • Method Details

    • close

      S close()
      Closes it and fires CLOSED, never CLOSE. Each implementation says what closing does and what a second call does.
      Returns:
      this