Skip to content
kerrishotts edited this page Apr 1, 2013 · 1 revision

(part of UI.View)

Type: View

Default: null

Read-Only; to modify use add / removeSubView.

Returns the direct parent of this view. If the view is not a child of any views, the return will be null. Children are directly represented in the DOM, so if the value is null, this particular view has no child element in the DOM that has a parent. (The reverse is not always true: objects are free to remove their element out of the DOM whenever they choose.)

Usage

var aView = new UI.View();
aView.init();
var bView = new UI.View();
bView.init();
aView.addSubView (bView);
var cView = bView.superView;
// cView should = aView

Version

0.3 Introduced; Docs Valid.

Clone this wiki locally