SimpleButton constructor
SimpleButton(
- [DisplayObject? upState,
- DisplayObject? overState,
- DisplayObject? downState,
- DisplayObject? hitTestState]
Creates a new SimpleButton instance.
Any or all of the display objects that represent the various button states can be set as parameters in the constructor.
Implementation
SimpleButton(
[this.upState, this.overState, this.downState, this.hitTestState]) {
useHandCursor = true;
onMouseOver.listen(_onMouseEvent);
onMouseOut.listen(_onMouseEvent);
onMouseDown.listen(_onMouseEvent);
onMouseUp.listen(_onMouseEvent);
onTouchOver.listen(_onTouchEvent);
onTouchOut.listen(_onTouchEvent);
onTouchBegin.listen(_onTouchEvent);
onTouchEnd.listen(_onTouchEvent);
}