Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface GUIController

Hierarchy

  • GUIController

Index

Properties

_disabled

_disabled: boolean

Used to determine if the controller is disabled. Use controller.disable( true|false ) to modify this value

_listening

_listening: boolean

Used to determine if the controller is currently listening. Don't modify this value directly. Use the controller.listen( true|false ) method instead.

_name

_name: string

The controller's name. Use controller.name( 'Name' ) to modify this value.

_onChange

_onChange: GUICallBack

Used to access the function bound to onChange events. Don't modify this value directly. Use the controller.onChange( callback ) method instead.

_onFinishChange

_onFinishChange: GUICallBack

Used to access the function bound to onFinishChange events. Don't modify this value directly. Use the controller.onFinishChange( callback ) method instead.

domElement

domElement: HTMLElement

The outermost container DOM element for this controller.

initialValue

initialValue: any

The value of object[ property ] when the controller was created.

object

object: object

The object this controller will modify.

parent

parent: I3JS.GUI

The GUI that contains this controller.

property

property: string

The name of the property to control.

Methods

destroy

  • destroy(): void

disable

enable

getValue

  • getValue(): any

listen

max

min

name

onChange

onFinishChange

options

  • Destroys this controller and replaces it with a new option controller. Provided as a more descriptive syntax for gui.add, but primarily for compatibility with dat.gui. Use caution, as this method will destroy old references to this controller. It will also change controller order if called out of sequence, moving the option controller to the end of the GUI.

    // safe usage
    gui.add( object1, 'property' ).options( [ 'a', 'b', 'c' ] );
    gui.add( object2, 'property' );

    // danger
    const c = gui.add( object1, 'property' );
    gui.add( object2, 'property' );
    c.options( [ 'a', 'b', 'c' ] );
    // controller is now at the end of the GUI even though it was added first

    assert( c.parent.children.indexOf( c ) === -1 )
    // c references a controller that no longer exists

    Parameters

    • options: object | any[]

    Returns GUIController

    options

reset

setValue

step

updateDisplay

Generated using TypeDoc