Constructor
new StateButton(name, text, parent, bgColor, hazard, state)
- Source:
Creates a state button
Parameters:
Name | Type | Description |
---|---|---|
name |
String | Button shortname |
text |
String | Button text |
parent |
HTMLElement | Button HTML Parent |
bgColor |
String | Button background color |
hazard |
Boolean | if the state it represents is hazardous |
state |
State | State this button represents |
Extends
- Button
Methods
activate()
- Source:
Sets the state button to active
deactivate()
- Source:
Sets the state button to inactive
onClick()
- Source: