API Docs for: 2.7.3
Show:

LockComponent Class

Extends BaseComponent3D
Module: Component
Parent Module: Wanaplan

This component is responsible for adding a lock icon to lock/unlock the drag action on all objects in the scene.

Constructor

LockComponent

(
  • core
)

Parameters:

  • core Core

    The main engine.

Methods

compute

() private

Inherited from BaseComponent3D:

Recompute of the component.

destroy

()

Inherited from BaseComponent3D

Removes the icon from the menu and stops listening to the lock event.

disable

()

Inherited from BaseComponent3D:

Disables the component

enable

()

Inherited from BaseComponent3D:

Enables the component

getFloor

(
  • [structure]
)
BABYLON.Mesh

Inherited from BaseComponent3D:

Gets the 3D mesh of the floor structure in parameter (by default current floor).

Parameters:

Returns:

BABYLON.Mesh:

The floor mesh in 3D.

initialize

()

Inherited from BaseComponent3D

Initializes objects and adds a custom stylesheet.

onContextChanged

(
  • context
)

Inherited from BaseComponent3D:

Method called when the context is switched (2D -> 3D or 3D -> 2D)

Parameters:

  • context String

    The new context

startListening

()

Inherited from BaseComponent3D:

Calls all the event listeners.

stopListening

()

Inherited from BaseComponent3D:

Removes all the event listeners.

toggleLock

(
  • event
)

Toggles lock or unlock. Triggered on event wnp.component.lock

Parameters:

  • event Object

    The event object.

update

(
  • deltaTime
)

Inherited from BaseComponent3D:

Updates the dynamic part of the component.

Parameters:

  • deltaTime Number
    The time interval.

Properties

keyboardManager

wnp.KeyboardManager

Inherited from BaseComponent3D:

Instance of the Keyboard Manager (shortcut to wanaplan.keyboardManager).

name

String

Inherited from BaseComponent3D:

Name of the component.

structure

wnp.Structure

Inherited from BaseComponent3D:

Instance of the structure (shortcut to wanaplan.structure).

Events

wnp.component.lock

Fired to lock/unlock the drag action on scene.

wnp.menu.top.sub.add

Fired to add a menu item into the sub menu.

wnp.menu.top.sub.delete

Fired to delete a menu item from the sub menu.

wnp.menu.top.sub.replace

Fired to replace a sub menu item.