PropertyEventMethodIndex
WebSquare.uiplugin.pageList - 5.0_2.2916B.20171222.151448

Manages pages. Provides user interfaces only to set page counting and page selection. Does not actually page the data.

Type

uiplugin

Property Summary

buttonShowType
Type of the page moving buttons. (Previous/Next Pages, Previous/Last Lists, First/Last Page)
class
Class of the component
deliImage
Image of the delimiter
deliImageStyle
Style of the delimiter
delimiter
Delimiter
deliWidth
Width of the delimiter
displayButtonType
Page button type for the first or last page
displayFormat
Index displaying format
displaySearchbox
[default:false, true] Adds a page number input box.
displaySelectedIndex
[default:false, true] Displays the current page number in the input box when displaySearchbox is "true".
id
Component ID
leftPageBackImage
Image of the button to move the page to the left as many as the pageSize
leftPageBackImageClass
Class of the button to move the page to the left as many as the pageSize
leftPageImage
Image of the button to move the page to the left by one page
leftPageImageClass
Class of the button to move the page to the left by one page
naviType
Valid only when the buttonShowType is 2. Specifies how to move a single page. (1: Move the list, 2: Select a page) The pagingType will be ignored.
oneMoveButtonWidth
Width of the button to move the page by one page
pageSize
Number of page indices on a single screen
pagingType
Page displaying method when the remaining page is smaller than the page size. (1: Adjust to the pagingSize, 2: Display only the remaining pages
renderType
Depending on the layout to be rendered, two types (table and list) are supported.
rightPageBackImage
Image of the button to move the page to the right by one page
rightPageBackImageClass
Class of the button to move the page to the right by one page
rightPageImage
Image of the button to move the page to the right
rightPageImageClass
Class of the button to move the page to the right
shiftMoveButtonWidth
Width of the button to move the page as many as the pageSize
tabIndex
Same as the tabindex property in HTML standard. Indicates the focusing order of the component by the tab key.
title
Current value of the title property of the component
useDelim
Specifies whether to use the delimiter or not.
userData1
User-defined property
userData2
User-defined property
userData3
User-defined property

Event Summary

onchange
Triggered upon changes in selection.
onclick
Triggered upon clicking of the component.
oninputblur
Triggered upon focusing out after the user’s entering the page number when the displaySearchbox is "true".
onviewchange
Triggered upon page number changes by mouse clicking or keyboard pressing.

Method Summary

addClass( className )
Adds a class to the component.
bind( eventType , function )
Dynamically allocates events to the component.
changeClass( oldClassName , newClassName )
Renames the class from oldClassName to newClassName.
focus( )
Moves the focus to the component.
getCount( )
Returns the total page count of the PageList component.
getDisabled( )
Gets the current value of the disabled property.
getGenerator( )
Called by a component under the Generator component. When called, gets the parent Generator object.
getID( )
Gets the ID of the component.
getInitStyle( property )
Gets the initial style of the component.
getLabel( idx )
Returns the label of the corresponding index.
getOpacity( )
Gets the opacity of the component defined in CSS.
getPageSize( )
Returns the pageSize of the PageList component.
getPluginName( )
Gets the pluginName (or the name) of the component.
getPosition( positionName )
Gets the left or top position of the component.
getReadOnly( )
Gets the current setting of the readOnly property.
getScope( )
Returns the parent WFrame object when the component is a child of the WFrame which uses the scope feature (scope=true).
getScopeWindow( )
Returns the scope object of the parent when the component is a child of the WFrame which uses the scope feature (scope=true).
getSelectedIndex( )
Returns the selected index.
getSize( sizeName )
Gets the size of the component.
getStyle( propertyName )
Gets the current value of the propertyName of the component defined in CSS.
getStyleValue( style )
[deprecated] Use getStyle instead.
getTitle( )
Gets the title value.
getUdcHome( )
Returns the path of the file which defines the UDC.
getUdcRoot( )
Returns the path of the file which defines the UDC.
getUserData( key )
Returns the user-defined property value set by setUserData as the user data or source (page XML).
hasClass( className )
Checks whether the component has className received as a parameter or not.
hide( )
Hides the component.
moveLeft( )
Reduces the selected index by 1.
moveRight( )
Increases the selected index by 1.
pageLeft( )
elects the first page on the previous page list.
pageRight( )
Selects the first page on the next list.
removeClass( className )
Removes className from the component.
setCount( count , flag )
Sets the total page count of the page list.
setDisabled( disabled )
Sets the disabled property.
setEventPause( evList , flag )
Disables or enables the component event.
setIdxClass( idx )
Functions same as setSelectedindex.
setInitStyle( property )
Initializes the component style.
setOpacity( value )
Sets the opacity of the component.
setPosition( left , top , mode )
Sets the position (left, top) of the component.
setReadOnly( readOnly )
Controls the "readOnly" property.
setSelectedIndex( idx )
Changes the selected index of the page.
setSize( width , heigth )
Sets the size (width, height) of the component.
setStyle( propertyName , value )
Sets the style of the specified property.
setUserData( key , value )
Sets the user data in the component.
setValue( value )
Functions same as setSelectedindex.
show( displayType )
Displays the component.
toggleClass( className )
Removes a class named className, or if there is no such a class, adds a class named className.
trigger( type , array )
Triggers a certain event registered for the component.
unbind( type , function )
Removes an event registered for the component.
visible( flag )
[deprecated] Shows/Hides the component, or sets the visible property using setStyle.

Property Detail

buttonShowType
Type of the page moving buttons. (Previous/Next Pages, Previous/Last Lists, First/Last Page)
0: Previous/Next List (2 buttons)
1 (Default): Previous/Next Pages + Previous/Next Lists (4 buttons)
2: Previous/Next Pages (2 buttons)
3: Previous/Next List + First/Last Pages (4 buttons)
class
Class of the component
deliImage
Image of the delimiter
deliImageStyle
Style of the delimiter
delimiter
Delimiter
deliWidth
Width of the delimiter
displayButtonType
Page button type for the first or last page. (display: always, auto: Does not display on the last page. displayOver: Display when the pageCount is higher than the pageSize. (If smaller, same as.) autoOver: Display when the pageCount is higher than the pageSize. (If smaller, same as auto.) autoHidden: Not display as many as displayed on the first and the last pages.)
displayFormat
Index displaying format
displaySearchbox
[default:false, true] Adds an input box to enter the page number. The page of the corresponding page number will be displayed. (true: Add, false (Default): Not add.)
displaySelectedIndex
[default:false, true] Displays the current page number in the input box when displaySearchbox is "true".
true: Display the current page number.
false (Default): Not display the current page number.
id
Component ID
leftPageBackImage
Image of the button to move the page to the left as many as the pageSize
leftPageBackImageClass
Class of the button to move the page to the left as many as the pageSize
leftPageImage
Image of the button to move the page to the right by one page
leftPageImageClass
Class of the button to move the page to the left by one page
naviType
Valid only when the buttonShowType is 2. Specifies how to move a single page. (1: Move the list, 2: Select a page) The pagingType will be ignored.
oneMoveButtonWidth
Width of the button to move the page by one page
pageSize
Number of page indices on a single screen
pagingType
Page displaying method when the remaining page is smaller than the page size. (1: Adjust to the pagingSize, 2: Display only the remaining pages.) If the buttonShowType is 3, pagingType=1 will not be supported.
renderType
Depending on the layout to be rendered, two types (table and list) are supported.
rightPageBackImage
Image of the button to move the page to the right by one page
rightPageBackImageClass
Class of the button to move the page to the right by one page
rightPageImage
Image of the button to move the page to the right
rightPageImageClass
Class of the button to move the page to the right
shiftMoveButtonWidth
Width of the button to move the page as many as the pageSize
tabIndex
Same as the tabindex property in HTML standard. Indicates the focusing order of the component by the tab key.
title
Current value of the title property of the component
useDelim
Specifies whether to use the delimiter or not.
userData1
User-defined property. Use getUserData("userData1") to get the data.
userData2
User-defined property. Use getUserData("userData2") to get the data.
userData3
User-defined property. Use getUserData("userData3") to get the data.

Event Detail

onchange
Triggered upon changes in selection.
Parameter
nametypedescription
currentNumberPage number
beforeNumberCurrent page number
Sample
ev:event="onchange( current , before )" The above is to change from page 2 to the next page. output1.setValue(before +"->" + current); 2 -> 3
onclick
Triggered upon clicking of the component.
Parameter
nametypedescription
idxNumberPage number
Sample
In an example of ev:event="onclick( idx )", click page 2. output1.setValue(idx); 2
oninputblur
Triggered upon focusing out after the user’s entering the page number when the displaySearchbox is "true". (The event occurs int he page number input box.)
Parameter
nametypedescription
BlurNumberValue entered upon event occurrence
Sample
ev:event="oninputblur( value )" output1.setValue(value +"->" + value);
onviewchange
Triggered upon page number changes by mouse clicking or keyboard pressing. In case the change was made by a script, no event will be triggered. (Similar to the native onchange event.)
Parameter
nametypedescription
infoObjectReturns an object containing oldValue, newValue, oldSelectedIndex, and newSelectedIndex. <Number> info.oldSelectedIndex : Old index <Number> info.newSelectedIndex : New index
Sample
<script ev:event="onviewchange( info )"><![CDATA[ var oldSelectedIndex = info.oldIndex; var newSelectedIndex = info.newIndex; ]]></script>

Method Detail

addClass( className )
Adds a class to the component.
Parameter
nametyperequireddescription
classNameStringYName of the class to add
Sample
// Add oddClass to component input1. input1.addClass("oddClass");
bind( eventType , function )
Dynamically allocates events to the component.
Parameter
nametyperequireddescription
eventTypeStringYName of the event to allocate.
functionFunctionYHandler function of the event to allocate.
Sample
// Define the event handler function for the onclick event in the input component, and bind the function. input1.bind("onclick", function(e){ alert(input1.getValue();})); // Bind commObj.ev_click function for the onclick event with component input1. var commObj = {}; commObj.ev_click = function(e){ alert("click :: "+this.id); }; input1.bind("onclick", commObj.ev_click );
changeClass( oldClassName , newClassName )
Renames the class from oldClassName to newClassName.
In the default setting, only the classes added by addClass will be applied. In order to directly remove the class defined in the "class" property of the component, add the following setting in config.xml file.
<style><removeDefaultClass value="true" /></style>
Parameter
nametyperequireddescription
oldClassNameStringYName of the class to remove
newClassNameStringYName of the class to add
Sample
// Define a class for the Input component. <xf:input id="input1" style="position: relative;width: 144px;height: 21px;" class="tmpInputClass"></xf:input> // Add the following to config.xml. <style> <removeDefaultClass value="true" /> </style> // Change tmpInputClass class to tmpInputWarninClass. input1.changeClass("tmpInputClass","tmpInputWarninClass");
focus( )
Moves the focus to the component.
getCount( )
Returns the total page count of the PageList component.
Return
typedescription
Number:YTotal page count
Sample
pageList1.getCount();
getDisabled( )
Gets the current value of the disabled property.
Return
typedescription
BooleanThe value of the disabled property.
Sample
var returnValue = componentId.getDisabled(); (Return example) false
getGenerator( )
Called by a component under the Generator component. When called, gets the parent Generator object.
Return
typedescription
ObjectParent Generator object
Sample
<w2:generator id="generator1"> <w2:trigger id="trigger1" ev:onclick="scwin.trigger1_onclick"></w2:trigger></w2:generator> scwin.trigger1.onclick = function(){ console.log(this.getGenerator());} // Click trigger1 to display the generator1 object on the console. // See https://inswave.com/jira/browse/WPF-1425.
getID( )
Gets the ID of the component.
Return
typedescription
StringID of the WebSquare5 component
Sample
// The WebSquare5 component dynamically received as a parameter can be used as shown in the following. function fn_validCheck(tmpObj){ // tmpObj has an ID of "input1". var compID = tmpObj.getID(); // (Return Example) "input1" }
getInitStyle( property )
Gets the initial style of the component.
Parameter
nametyperequireddescription
propertyStringNName of the attribute (If not specified, all information will be ouputted.)
getLabel( idx )
Returns the label of the corresponding index.
Parameter
nametyperequireddescription
idxNumberYIndex of the page
Return
typedescription
StringLabel of the corresponding index.
Sample
var returnValue = pageList1.getLabel(1); “1” will be returned.
getOpacity( )
Gets the opacity of the component defined in CSS.
Return
typedescription
IntegerOpacity
Sample
// Apply opacity CSS to the Input component. <xf:input id="input1" style="position: relative;width: 144px;height: 21px;opacity:0.2;"></xf:input> var returnValue = input1.getOpacity(); // "returnValue" is a real number between 0 and 1. // (Return Value) "0.2"
getPageSize( )
Returns the pageSize of the PageList component.
Sample
pageList1.getPageSize();
getPluginName( )
Gets the pluginName (or the name) of the component.
Return
typedescription
StringpluginName of the WebSquare5 component
Sample
// For a WebSquare5 object dynamically received by a common function, conditional statements can be used as shown below. var commObj = {}; commObj.fn_makeReqData = function(tmpObj){ var tmpID = tmpObj.getID(); // Component ID var tmpCompType = tmpObj.getPluginName(); // Component Type if(tmpCompType == "input"){ //..Logic.. }else if(tmpCompType == "gridView"){ //..Logic .. }else{ //..Logic.. } };
getPosition( positionName )
Gets the left or top position of the component. If set by %, the corresponding pixel value will be returned.
Parameter
nametyperequireddescription
positionNameStringY[left,top] Type of the position
Return
typedescription
NumberPosition of the component
Sample
// Apply margin CSS to the Input component. <xf:input id="input1" style="position: relative;width: 144px;height: 21px;margin:10px;"></xf:input> var returnValue = input1.getPosition("top"); // The returnValue will be a position in pixels. // (Return Example) 10
getReadOnly( )
Gets the current setting of the readOnly property.
Return
typedescription
BooleanThe current setting of the readOnly property
Sample
var returnValue = componentId.getReadOnly(); // (Return Example) false
getScope( )
Returns the parent WFrame object when the component is a child of the WFrame which uses the scope feature (scope=true).
Returns null when the component is not a child of the WFrame using the scope feature (scope=true).
Return
typedescription
Objectwframe object or null
Sample
// The main page contains wframe1, and wframe1 contains wframe11 which contains textbox1. textbox1.getScope(); // Returns wframe11 object.
getScopeWindow( )
Returns the scope object of the parent when the component is a child of the WFrame which uses the scope feature (scope=true).
Returns a global window object when the component is not a child of the WFrame using the scope feature (scope=true.
Return
typedescription
ObjectScope object of the wframe object, or a global window object
Sample
// The main page contains wframe1, and wframe1 contains wframe11 which contains textbox1. var scope = textbox1.getScopeWindow(); scope.wframe11 === textbox1.getScope(); // true
getSelectedIndex( )
Returns the selected index.
Return
typedescription
NumberCurrent index.
Sample
Select Page 5. var returnValue = pageList1.getSelectedIndex(); “5” will be returned.
getSize( sizeName )
Gets the size of the component. If set by "%", the corresponding pixel value will be returned.
Parameter
nametyperequireddescription
sizeNameStringY[height, innerHeight, outerHeight, outerMarginHeight, width, innerWidth, outerWidth, outerMarginWidth] Type of the size. For the calculation of each size type, see below.
height : element.clientHeight innerHeight : element.clientHeight + padding outerHeight : element.clientHeight + padding + border outerMarginHeight : element.clientHeight + padding + border + margin width : element.clientWidth innerWidth : element.clientWidth + padding outerWidth : element.clientWidth + padding + border outerMarginWidth : element.clientWidth + padding + border + margin
Return
typedescription
NumberSize of the component
Sample
var returnValue = componentId.getSize("width"); // "returnValue" will be a size in pixels. If set by "%", the corresponding pixel value will be returned. // (Return Example) 100
getStyle( propertyName )
Gets the current value of the propertyName of the component defined in CSS.
Parameter
nametyperequireddescription
propertyNameStringYName of the property in the style
Return
typedescription
StringStyle value
Sample
// Define an Input component. <xf:input id="input1" style="position: relative;width: 144px;height: 21px;"></xf:input> var returnValue = input1.getStyle("width"); // (Return Example) "144px"
getStyleValue( style )
[deprecated] Use getStyle instead.
Gets the current value of the propertyName of the component defined in CSS.
Parameter
nametyperequireddescription
styleStringYName of the property defined in the style
Return
typedescription
StringValue defined in the style property. (In case of a color, the hexcode of the color will be returned.)
getTitle( )
Gets the title value.
Return
typedescription
StringTitle value
Sample
// Define the "title" for the Input component. <xf:input id="input1" style="position: relative;width: 144px;height: 21px;" title="이름 입력"></xf:input> var tmpTitle = input1.getTitle(); // (Return Example ) "Input Name"
getUdcHome( )
Returns the path of the file which defines the UDC. Includes the file extension of .xml. For a path without .xml, use getUdcRoot. When called by a component, not a UDC object, undefined will be returned.
Return
typedescription
StringWhen called by a component, not a UDC object, undefined will be returned.
Sample
The udc file is /a/b/udc.xml, the XML file is /a/c/main.xml, and the UDC object ID is udc1. udc1.getUdcHome(); // The execution result is /a/b/udc.xml.
getUdcRoot( )
Returns the path of the file which defines the UDC. udc1.getUdcHome(); // The execution result is /a/b/udc.xml. For a path including .xml, use getUdcHome. When called by a component, not a UDC object, undefined will be returned.
Return
typedescription
StringWhen called by a component, not a UDC object, undefined will be returned.
Sample
The udc file is /a/b/udc.xml, the XML file is /a/c/main.xml, and the UDC object ID is udc1. udc1.getUdcHome(); // The execution result is /a/b/udc.xml.
getUserData( key )
Returns the user-defined property value set by setUserData as the user data or source (page XML).
Parameter
nametyperequireddescription
keyStringYRandom data key
Return
typedescription
StringData of the corresponding key
Sample
// Apply the customized property (eduTest) to the Input component. <xf:input id="input1" style="position: relative;width: 144px;height: 21px;" eduTest="Hello"></xf:input> input1.getUserData("eduTest"); // (Return Example) "Hello" // Use setUserData. input1.setUserData("eduTest","WebSquare"); input1.getUserData("WebSquare"); // (Return Example) "Hello"
hasClass( className )
Checks whether the component has className received as a parameter or not.
Parameter
nametyperequireddescription
classNameStringYclassName to check
Return
typedescription
BooleanWhether the component has the class or not
Sample
// Define a class for the Input component. <xf:input id="input1" style="position: relative;width: 144px;height: 21px;" class="tmpInputClass"></xf:input> var returnValue = input1.hasClass("tmpInputClass"); // (Return Example) true
hide( )
Hides the component.
he CSS setting will be "display:none;" and "visibility:hidden;".
Sample
componentId.hide();
moveLeft( )
Reduces the selected index by 1.
Sample
The current page is page 3. pageList1.moveLeft(); Page 2 will be selected.
moveRight( )
Increases the selected index by 1.
Sample
The current page is page 3. pageList1.moveRight(); Page 4 will be selected.
pageLeft( )
Selects the first page on the previous page list.
When the pageSize is 10 and the end user is currently on page 23, the end user will move to page 11.
Sample
The pageSize is 10 and the end user is currently on page 23. pageList1.pageLeft(); Will be moved to page 11.
pageRight( )
Selects the first page on the next list.
When the pageSize is 10 and the end user is currently on page 23, the end user will move to page 31.
Sample
The pageSize is 10 and the end user is currently on page 23. pageList1.pageRight(); Will be moved to page 31.
removeClass( className )
Removes className from the component.
In the default setting, only the classes added by addClass will be applied. In order to directly remove the class defined in the "class" property of the component, add the following setting in config.xml file.
<style><removeDefaultClass value="true" /></style>
Parameter
nametyperequireddescription
classNameStringYName of the class to remove
Sample
// Define a class for the Input component. <xf:input id="input1" style="position: relative;width: 144px;height: 21px;" class="tmpInputClass"></xf:input> // Add the following to config.xml. <style> <removeDefaultClass value="true" /> </style> // Remove tmpInputClass class. input1.removeClass("tmpInputClass");
setCount( count , flag )
Sets the total page count of the page list.
The page list will be updated with the new total page count.
Initialized to the first page upon calling of the API.
Parameter
nametyperequireddescription
countNumberYTotal page count to set
flagBooleanNKeeps the previous output type. (true to keep, or false not to keep. If not specified, will be updated to page 1.)
Sample
pageList1.setCount(100);
setDisabled( disabled )
Sets the disabled property. True to disable, or false not to disable.
Parameter
nametyperequireddescription
disabledBooleanYTrue to disable, or false not to disable.
Sample
// Disable the component. componentId.setDisabled(true);
setEventPause( evList , flag )
Disables or enables the component event.
Parameter
nametyperequireddescription
evListStringNList of the events. If not specified, all user events of the component will be listed. (Enter null data.)
flagBooleanYtrue is to pause, or false is to cancel pausing.
Sample
input1.setEventPause("onclick", true); // Dynamically pauses the onclick event. input1.setEventPause("onfocus,onblur", false); // Restarts the onfocus and the onblur events. input1.setEventPause(null, true); // Pauses all user events registered for the Input component.
setIdxClass( idx )
Functions same as setSelectedindex.
Parameter
nametyperequireddescription
idxNumberYIndex to select
Sample
pageList1.setIdxClass(5); Page 5 will be selected.
setInitStyle( property )
Initializes the component style.
Parameter
nametyperequireddescription
propertyStringNName of the property (If not specified, all properties will be returned.)
Sample
group1.getInitStyle();
setOpacity( value )
Sets the opacity of the component.
Parameter
nametyperequireddescription
valueNumberYOpacity value (A real number between 0 and 1)
Sample
componentId.setOpacity(0.45);
setPosition( left , top , mode )
Sets the position (left, top) of the component.
Parameter
nametyperequireddescription
leftNumberYLeft position or null.
topNumberYTop position or null.
modeStringN[defulat:absolute, delta] absolute sets the current positions as x and y, and delta adds x and y to the current positions.
Sample
// Set the top position of the component as 100 pixels. componentId.setPosition(null, 100);
setReadOnly( readOnly )
Controls the "readOnly" property. True to enable, or false to disable.
Parameter
nametyperequireddescription
readOnlyBooleanYTrue to enable, or false to disable.
Sample
// Enable the read-only. componentId.setReadOnly(true);
setSelectedIndex( idx )
Changes the selected index of the page.
Parameter
nametyperequireddescription
idxNumberYIndex to select
Sample
pageList1.setSelectedIndex(5); Page 5 will be selected.
setSize( width , heigth )
Sets the size (width, height) of the component.
Parameter
nametyperequireddescription
widthNumberYComponent width or null
heigthNumberYComponent height or null
Sample
// Set the component height as 100 pixels. componentId.setSize(null,100);
setStyle( propertyName , value )
Sets the style of the specified property.
Parameter
nametyperequireddescription
propertyNameStringYName of the style
valueStringYValue of the style
Sample
// Set the component width as 200px. componentId.setStyle("width", "200px"); // Change the background color to olive. componentId.setStyle("background-color","olive");
setUserData( key , value )
Sets the user data in the component. If the key cannot be set for the component, corresponding logs will be displayed.
Parameter
nametyperequireddescription
keyStringYRandom data key
valueStringYRandom data key
Sample
// Setting a (key, value) pair of ("data", "WebSquare5") in the component. componentId.setUserData("data", "WebSquare"); // Some keys cannot be set for the component. componentId.setUserData("title", "WebSquare"); // (Log Example) !!!WARNING - [title] can't define as UserData
setValue( value )
Functions same as setSelectedindex.
Parameter
nametyperequireddescription
valueStringYIndex to select
Sample
pageList1.setValue(5); Page 5 will be selected.
show( displayType )
Displays the component.
The related CSS properties are display and visibility:show;.
Parameter
nametyperequireddescription
displayTypeStringN[default:block ,inline ,none ,""] Value of the Display property.
Sample
// Block the "display" property. componentId.show(); // Enable the "display" property in the class. componentId.show("");
toggleClass( className )
Removes a class named className, or if there is no such a class, adds a class named className.
In the default setting, only the classes added by addClass can be removed. To remove other classes, add the following setting in config.xml.
<style><removeDefaultClass value="true" /></style>
Parameter
nametyperequireddescription
classNameStringYclassName to set
Sample
// Define a class for the Input component. <xf:input id="input1" style="position: relative;width: 144px;height: 21px;" class="tmpInputClass"></xf:input> // Add the following to config.xml. <style> <removeDefaultClass value="true" /> </style> // Remove tmpInputClass class. input1.toggleClass("tmpInputClass"); // Add tmpInputClass class again. input1.toggleClass("tmpInputClass");
trigger( type , array )
Triggers a certain event registered for the component.
Parameter
nametyperequireddescription
typeStringYName of the event to trigger
arrayArrayNArray of parameters to send to the event handler
Sample
// Trigger the onclick event in the input1 component. input1.trigger("onclick"); // Trigger the onviewchange event in the input component and call the event handler function by sending arguments of (1, 2). input1.trigger("onviewchange", [1,2]);
unbind( type , function )
Removes an event registered for the component.
Parameter
nametyperequireddescription
typeStringNName of the event to remove. If not specified, all events of the components will be removed.
functionFunctionNHandler function of the event to remove. If not specified, all handler functions of the event will be removed.
Sample
// Remove all events registered in the input component. input1.unbind(); // Remove all handler functions of onviewchange event registered in the input component. input1.unbind("onviewchange"); // Remove the func1 event handler of onviewchange event registered for component input1. input1.unbind("onviewchange", func1);
visible( flag )
[deprecated] Shows/Hides the component, or sets the visible property using setStyle.
Sets the visibility of the component style. In case of true, set visible. In case of false, set hidden.
Parameter
nametyperequireddescription
flagBooleanYVisibility (In case of true, set visible. In case of false, set hidden.)