Package snap.view

Class ToggleGroup

java.lang.Object
snap.view.ToggleGroup

public class ToggleGroup extends Object
A class to manage a single selection for a group of objects that can each be selected.
  • Constructor Details

    • ToggleGroup

      public ToggleGroup()
  • Method Details

    • getName

      public String getName()
      Returns the name.
    • setName

      public void setName(String aName)
      Sets the name.
    • isAllowEmpty

      public boolean isAllowEmpty()
      Returns whether group can be empty.
    • setAllowEmpty

      public void setAllowEmpty(boolean aValue)
      Sets whether group can be empty.
    • getSelected

      public ToggleButton getSelected()
      Returns the selected toggle.
    • setSelected

      public void setSelected(ToggleButton aToggle)
      Sets the selected toggle.
    • getButtons

      public List<ToggleButton> getButtons()
      Returns the buttons.
    • add

      public void add(ToggleButton aToggle)
      Add adds a toggle.
    • remove

      public void remove(ToggleButton aToggle)
      Removes a toggle.
    • buttonSelectionDidChange

      protected void buttonSelectionDidChange(PropChange anEvent)
      PropChangeListener method.