Filed to use instead of instanceof ViewBase.
Determines the depth of suspended updates. When the value is 0 the current property updates are not batched nor scoped and must be immediately applied. If the value is 1 or greater, the current updates are batched and does not have to provide immediate update. Do not set this field, the _batchUpdate method is responsible to keep the count up to date, as well as adding/rmoving the view to/from the visual tree.
A property bag holding suspended native updates. Native setters that had to execute while there was no native view, or the view was detached from the visual tree etc. will accumulate in this object, and will be applied when all prerequisites are met.
Gets or sets the CSS class name for this view.
Setting column
property is the same as col
Setting columnSpan
property is the same as colSpan
Gets or sets the id for this view.
Returns true if visibility is set to 'collapse'. Readonly property
read-only. If you want to set out-of-band the nativeView use the setNativeView method.
Gets owner page. This is a read-only property.
Gets the parent view. This property is read-only.
Gets the template parent or the native parent. Sets the template parent.
Gets the style object associated to this view.
Gets the name of the constructor function for this instance. E.g. for a Button class this will return "Button".
returns the native UIViewController.
String value used when hooking to loaded event.
String value used when hooking to propertyChange event.
String value used when hooking to unloaded event.
Method is intended to be overridden by inheritors and used as "protected"
Performs the core logic of adding a child view to the native visual tree. Returns true if the view's native representation has been successfully added, false otherwise.
Allow multiple updates to be performed on the instance at once.
This method is intended to be overriden by inheritors to provide additional implementation.
Method is intended to be overridden by inheritors and used as "protected"
Method is intended to be overridden by inheritors and used as "protected"
Method is intended to be overridden by inheritors and used as "protected"
Setups the UI for ViewBase and all its children recursively. This method should not be overridden by derived views.
Tears down the UI for ViewBase and all its children recursively. This method should not be overridden by derived views.
Adds a listener for the specified event name.
Comma delimited names of the events to attach the listener to.
A function to be called when some of the specified event(s) is raised.
An optional parameter which when set will be used as "this" in callback method call.
Closes the current modal view that this page is showing.
Any context you want to pass back to the host when closing the modal view.
Creates a native view. Returns either android.view.View or UIView.
Clean up references to the native view.
Iterates over children of type ViewBase.
Called for each child of type ViewBase. Iteration stops if this method returns falsy value.
Gets the value of the specified property.
Returns the child view with the specified id.
Checks whether a listener is registered for the specified event name.
The name of the event to check for.
Initializes properties/listeners of the native view.
Load view.
to load.
Notifies all the registered listeners for the event provided in the data.eventName.
The data associated with the event.
Notifies all the registered listeners for the property change event.
Shortcut alias to the removeEventListener method.
A basic method signature to hook an event listener (shortcut alias to the addEventListener method).
String corresponding to events (e.g. "propertyChange"). Optionally could be used more events separated by ,
(e.g. "propertyChange", "change").
Callback function which will be executed when event is raised.
An optional parameter which will be used as this
context for callback execution.
Raised when a propertyChange occurs.
Adds one-time listener function for the event named event
.
Name of the event to attach to.
A function to be called when the specified event is raised.
An optional parameter which when set will be used as "this" in callback method call.
Removes listener(s) for the specified event name.
Comma delimited names of the events the specified listener is associated with.
An optional parameter pointing to a specific listener. If not defined, all listeners for the event names will be removed.
An optional parameter which when set will be used to refine search of the correct callback which will be removed as event listener.
Invalidates the layout of the view and triggers a new layout pass.
Resets properties/listeners set to the native view.
Updates the specified property with the provided value.
Set the nativeView field performing extra checks and updates to the native properties on the new view. Use in cases where the createNativeView is not suitable. As an example use in item controls where the native parent view will create the native views for child items.
Shows the View contained in moduleName as a modal view.
The name of the module to load starting from the application root.
A ShowModalOptions instance
Shows the view passed as parameter as a modal view.
View instance to be shown modally.
A ShowModalOptions instance
Unload view.
to unload.
Please note that should you be using the
new Observable({})
constructor, it is obsolete since v3.0, and you have to migrate to the "data/observable"fromObject({})
or thefromObjectRecursive({})
functions.