Package org.rspeer.game.script.model
Class ConfigPanelManager
- java.lang.Object
-
- org.rspeer.game.script.model.ConfigPanelManager
-
public class ConfigPanelManager extends Object
-
-
Constructor Summary
Constructors Constructor Description ConfigPanelManager()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description JComponentgetComponent(String key)voidsetOnAction(String key, ActionListener listener)voidsetOnKey(String key, KeyListener listener)voidsetPanels(Map<String,ModelPanel> panels, List<Pair<FieldAnnotationMapping,ModelPanel>> mappings)voidsetVisible(String key, boolean visible)
-
-
-
Method Detail
-
setPanels
public void setPanels(Map<String,ModelPanel> panels, List<Pair<FieldAnnotationMapping,ModelPanel>> mappings)
-
setOnAction
public void setOnAction(String key, ActionListener listener)
-
setOnKey
public void setOnKey(String key, KeyListener listener)
-
getComponent
public JComponent getComponent(String key)
- Parameters:
key- The key of the config- Returns:
- The component for the given key. For Selector's, this is a JComboBox, for TextField's, this is a JTextField, and for CheckBox's this is a JCheckBox.
-
setVisible
public void setVisible(String key, boolean visible)
- Parameters:
key- The key of the configvisible-trueto set the component visible,falseotherwise
-
-