Client-side base Control class
JavaScript
Comkarl.Web.UI.Controls.Control is the base class of any client-side control made using Calipso.
It provides infrastructure members as well as utilities and interesting properties and methods that should be taken in account in any Calipso development.
Any
Control base class member can be accessed using the JavaScript regular
this.member syntax, if code scope of
this is a derived class of it.
Available properties
ApplicatioPath
- this.get_ApplicationPath()
- Returns a string.
Gets the relative virtual folder application path. It's value comes from the server-side and it's the good way of using safe URLs to your server resources like files, images, stylesheets and so on in your controls.
ParentElementSelector path
- this.getParentElementSelector(), this.setParentElementSelector(String).
- Returns or sets a string.
Gets or sets a CSS element selector. This selector must point to the element on which the control must be nested.
Element
- this.get_Element()
- Returns an object.
Gets the (X)HTML element of the container of current control.
ElementCssClass
- this.get_ElementCssClass()
- Returns a string.
Gets the CSS class name of (X)HTML element of the container of current control.
Resources
- this.get_Resources()
- Returns an object
Gets the localization objects for current control.
Disabled
Sets a boolean flag (literal boolean
true or
false) that disables or enables any input elements inside control's container. If it's true, disables inputs, if it's false, enables them.
Available methods
This is called by Calipso, but derived classes add code that initializes resources just after control got rendered.
This is called by Calipso, but derived classes add code that renders the (X)HTML representing the user interface (UI) for the control.
Converts a regular path to an application path-safe one. For example, if current server ASP.NET application is a virtual folder
/myapp, calling ResolvePath for string "images/blah.jpg" will return a resolved path
/myapp/images/blah.jpg.