Skip to content

RoundPushButton

Overview

RoundPushButton is a round push button, used to initiate some action.

@author John Blanco (PhET Interactive Simulations) @author Sam Reid (PhET Interactive Simulations)

Class RoundPushButton

import { RoundPushButton } from 'scenerystack/sun';

Constructor

new RoundPushButton( providedOptions? : RoundPushButtonOptions )

Instance Methods

dispose()

addListener( listener : PushButtonListener )

Adds a listener that will be notified when the button fires.

removeListener( listener : PushButtonListener )

Removes a listener.

Instance Properties

pushButtonModel : PushButtonModel

(protected, readonly)

RoundButton has this.buttonModel, but we also need this.pushButtonModel, because it has additional methods

Type RoundPushButtonOptions

import type { RoundPushButtonOptions } from 'scenerystack/sun';

Source Code

See the source for RoundPushButton.ts in the sun repository.