Class: UWA.Environment.AbstractView

UWA/Environment. UWA.Environment.AbstractView

new UWA.Environment.AbstractView()

Base class to create views. An instance of a view is tied to a single event and environment. Each valid request to change a view will create a new View instance, and this instance may be used more than one time (example: if a view fails to enter, the previous view will be entered again)

Mixes In

  • UWA.Class.Events

Index

Members

event :Object

the view event

Type
  • Object

environment :UWA.Environment

the environment

Type
  • UWA.Environment

Methods

destroy()

Destroy this instance. It should not be used after that.

enter()

Called when the view is activated. This method must dispatch the event onEnter or onError.

leave()

Called when the view is deactivated. This method must dispatch the event onLeave or onError.

isSingle() → {Boolean}

Check if the view should be in single mode (= only one view can be in single mode at a time)

Returns
Type
Boolean

matchEvent() → {Object}

Check if this view matches another event. If it matches, there is no need to leave the current view and create another view.

Returns

another view event

Type
Object

onEnter()

Default action to do when the view is activating. Adds a CSS class on the widget body with the view type.

onLeave()

Default action to do when the view is deactivating. Removes the CSS class added by

<onEnter>.