Class: CustomTreeView
Source Location: /comctrls.inc.php
Child classes:
|
Inherited Variables
|
Inherited Methods
|
Class Details
Class Variables
Class Methods
constructor __construct [line 1903]
CustomTreeView __construct(
[
$aowner = null])
|
|
Overrides QWidget::__construct() (parent method not documented)
Parameters:
method addNodeToItems [line 2365]
TreeNode addNodeToItems(
string
$caption, [integer
$tag = 0], [integer
$imageindex = -1], [integer
$selectedindex = -1])
|
|
Add a TreeNode to the Items array of the TreeView. The returned TreeNode will have Level = 1 and ParentNode = null. The Level is 1 since the true root node is static and cannot be configured yet but may in the future. <?php
function btnAddNodeClick($sender, $params)
{
}
?>
Tags:
Parameters:
method convertPureArrayToTreeNodes [line 1928]
array convertPureArrayToTreeNodes(
array
$itemsarray, [object
$parentnode = null])
|
|
The function convertPureArrayToTreeNodes() is used to convert a tree that just exists of nested arrays into a tree with TreeNodes objects. It is used to convert the array written by the tree node editor (or items editor) of the object inspector of Delphi for PHP. It may also be used to convert older code into TreeNodes. Just call this function after the tree is assembled in the array. Note: This function calls itself recursivly to convert all child nodes too.
Tags:
Parameters:
method defaultImageList [line 2438]
method defaultjsOnTreeClose [line 2502]
void defaultjsOnTreeClose(
)
|
|
method defaultjsOnTreeOpenWhileEmpty [line 2515]
void defaultjsOnTreeOpenWhileEmpty(
)
|
|
method defaultjsOnTreeOpenWithContent [line 2527]
void defaultjsOnTreeOpenWithContent(
)
|
|
method defaultOnChangeSelected [line 2547]
void defaultOnChangeSelected(
)
|
|
method defaultRootNodeCaption [line 2192]
void defaultRootNodeCaption(
)
|
|
method defaultSelectedItemID [line 2457]
void defaultSelectedItemID(
)
|
|
method defaultShowLines [line 2466]
method defaultShowRoot [line 2475]
method dumpContents [line 2196]
method dumpItem [line 2103]
void dumpItem(
array
$item, string
$parentname, integer
$level)
|
|
Dumps a tree node and its sub-nodes.
Tags:
Parameters:
method dumpJavascript [line 2296]
method dumpJsEvents [line 2289]
method dumpRow [line 2046]
void dumpRow(
array
$item, integer
$level)
|
|
Dumps the first row for the items
Tags:
Parameters:
method findNodeWithItemID [line 2400]
mixed findNodeWithItemID(
string
$itemid)
|
|
This function is used to find a TreeNode object with the ItemID property. Since ItemID is the only unique identifier of the TreeNode this function is one to safly find a tree node. This function iterates through all TreeNodes in the Items array. <?php
function btnAddToSelectedClick($sender, $params)
{
if ($node != null)
$node->addChild($this->edtNodeName->Text, 0, 1, 1);
}
?>
Tags:
Parameters:
method getRootNodeCaption [line 2190]
string getRootNodeCaption(
)
|
|
Specifies the text to be used for the root node All trees have a root node, from which all child nodes are created, by default, the caption for this node is "Items". Use this property to change that value.
method init [line 2009]
method loaded [line 2003]
method readImageList [line 2436]
Image list used to customize the tree node icons. Be sure the correct ImageIndex or SelectedIndex is used in the TreeNode.
Tags:
method readItems [line 2448]
Lists the individual nodes that appear in the tree view control. At design time the items in the Items array is build out of pure array rather than TreeNode objects. Once the TreeView is unserialized at run time the array contains TreeNode objects.
method readjsOnChangeSelected [line 2492]
mixed readjsOnChangeSelected(
)
|
|
Occurs when a tree node gets selected. <?php
function TreeView1JSChangeSelected($sender, $params)
{
?>
//Add your javascript code here
document.getElementById("lblSelectedNode1").innerHTML = "Selected node: " + TreeView1.getSelectedElement().getLabelObject().getHtml();
<?php
}
?>
method readjsOnTreeClose [line 2500]
mixed readjsOnTreeClose(
)
|
|
Occurs when a open tree node is closed. Note that the event is called before the node is closed.
method readjsOnTreeOpenWhileEmpty [line 2513]
mixed readjsOnTreeOpenWhileEmpty(
)
|
|
Occurs when a closed tree node that has no children is opened. Note that the event is called before the node is opened. This event is useful for you to provide the children dynamically, for example, using Ajax to query for the node children and populate them in javascript.
method readjsOnTreeOpenWithContent [line 2525]
mixed readjsOnTreeOpenWithContent(
)
|
|
Occurs when a closed tree node that has children is opened. This event is fired when a node is opened and has children. Note that the event is called before the node is opened.
method readOnChangeSelected [line 2545]
mixed readOnChangeSelected(
)
|
|
Occurs when a tree node gets selected. Use the $params argument passed to the event handler to get the selected tree node ($params["treenode"]) and the selected ItemID ($params["itemid"]). <?php
function TreeView1ChangeSelected($sender, $params)
{
$this->lblSelectedNode2->Caption = "Selected: ".$params["treenode"]->Caption;
}
?>
method readSelectedItemID [line 2455]
string readSelectedItemID(
)
|
|
Specifies the ItmeID of the selected node.
method readShowLines [line 2464]
Specifies whether to display the lines that link child nodes to their corresponding parent nodes.
method readShowRoot [line 2473]
Specifies whether the top-level (root) node is displayed. Currently this node can not be modified (it is static).
method serialize [line 1989]
method setRootNodeCaption [line 2191]
void setRootNodeCaption(
$value)
|
|
Parameters:
method unserialize [line 1967]
Overrides Persistent::unserialize() (This method uses PHP reflection to iterate through published properties (the ones starting with get) and retrieve the properties stored by a previous serialize() call.)
method updateExpandedNodes [line 2419]
void updateExpandedNodes(
array
$items, array
$itemidarray)
|
|
Updates the Expanded property on all TreeNodes. If the ItemID of a TreeNode is found in $itemidarray Expanded is true, otherwise false.
Tags:
Parameters:
method writeImageList [line 2437]
void writeImageList(
$value)
|
|
Parameters:
method writeItems [line 2449]
method writejsOnChangeSelected [line 2493]
void writejsOnChangeSelected(
$value)
|
|
Parameters:
method writejsOnTreeClose [line 2501]
void writejsOnTreeClose(
$value)
|
|
Parameters:
method writejsOnTreeOpenWhileEmpty [line 2514]
void writejsOnTreeOpenWhileEmpty(
$value)
|
|
Parameters:
method writejsOnTreeOpenWithContent [line 2526]
void writejsOnTreeOpenWithContent(
$value)
|
|
Parameters:
method writeOnChangeSelected [line 2546]
void writeOnChangeSelected(
$value)
|
|
Parameters:
method writeSelectedItemID [line 2456]
void writeSelectedItemID(
$value)
|
|
Parameters:
method writeShowLines [line 2465]
void writeShowLines(
$value)
|
|
Parameters:
method writeShowRoot [line 2474]
void writeShowRoot(
$value)
|
|
Parameters:
Documentation generated on Sat, 13 Jun 2009 10:51:06 -0700 by phpDocumentor 1.4.1
|