Window.expand

Syntax

expand (IsExpand);

Parameter

IsExpand. Determines whether the window will expand or collapse. If the parameter is set to True the window will expand, if the parameter is False - the window will collapse.

Description

The expand method expands and collapses window.

Example

To execute the example, the HTML page must contain the Window component named win (see Example of Creating the Window Component). Create buttons clicking which collapses and expands the window.

//Create a button labeled Collapse
var btn1 = new PP.Button({
    ParentNode: document.getElementById("btn1"),
    Content: "Collapse"
});
//Click event handler
btn1.Click.add(function (sender, args) {
    win.expand (false);
});
//Create a button labeled Expand
var btn2 = new PP.Button({
    ParentNode: document.getElementById("btn2"),
    Content: "Expand"
});
//Click event handler
btn2.Click.add(function (sender, args) {
    win.expand(true);
});

After executing the example the Collapse and Expand buttons are created clicking which respectively collapses or expands the window.

See also:

Window