com.gwtext.client.widgets.tree
Class DefaultSelectionModel

java.lang.Object
  extended by com.gwtext.client.core.JsObject
      extended by com.gwtext.client.widgets.tree.DefaultSelectionModel
All Implemented Interfaces:
TreeSelectionModel

public class DefaultSelectionModel
extends JsObject
implements TreeSelectionModel

Default Tree selection model. Using this selection model only a single node can be selected. To enable selection of multiple nodes, use MultiSelectionModel.

See Also:
MultiSelectionModel

Field Summary
 
Fields inherited from class com.gwtext.client.core.JsObject
jsObj
 
Constructor Summary
DefaultSelectionModel()
          Construct a DefaultSelectionModel.
DefaultSelectionModel(com.google.gwt.core.client.JavaScriptObject jsObj)
           
 
Method Summary
 void addSelectionModelListener(DefaultSelectionModelListener listener)
           
 void clearSelections()
          Clear all selections.
 TreeNode getSelectedNode()
           
 boolean isSelected(TreeNode treeNode)
          Returns true if the node is selected.
 void select(TreeNode treeNode)
          Select a node.
 void selectNext()
          Selects the node above the selected node in the tree, intelligently walking the nodes.
 void selectPrevious()
          Selects the node above the selected node in the tree, intelligently walking the nodes.
 void unselect(TreeNode treeNode)
          Deselect a node.
 
Methods inherited from class com.gwtext.client.core.JsObject
getJsObj, getProperties, isCreated, setJsObj
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.gwtext.client.widgets.tree.TreeSelectionModel
getJsObj
 

Constructor Detail

DefaultSelectionModel

public DefaultSelectionModel()
Construct a DefaultSelectionModel.


DefaultSelectionModel

public DefaultSelectionModel(com.google.gwt.core.client.JavaScriptObject jsObj)
Method Detail

clearSelections

public void clearSelections()
Description copied from interface: TreeSelectionModel
Clear all selections.

Specified by:
clearSelections in interface TreeSelectionModel

getSelectedNode

public TreeNode getSelectedNode()

isSelected

public boolean isSelected(TreeNode treeNode)
Description copied from interface: TreeSelectionModel
Returns true if the node is selected.

Specified by:
isSelected in interface TreeSelectionModel
Parameters:
treeNode - the node to test
Returns:
true if selected

select

public void select(TreeNode treeNode)
Description copied from interface: TreeSelectionModel
Select a node.

Specified by:
select in interface TreeSelectionModel
Parameters:
treeNode - the tree node to select

selectNext

public void selectNext()
Description copied from interface: TreeSelectionModel
Selects the node above the selected node in the tree, intelligently walking the nodes.

Specified by:
selectNext in interface TreeSelectionModel

selectPrevious

public void selectPrevious()
Description copied from interface: TreeSelectionModel
Selects the node above the selected node in the tree, intelligently walking the nodes.

Specified by:
selectPrevious in interface TreeSelectionModel

unselect

public void unselect(TreeNode treeNode)
Description copied from interface: TreeSelectionModel
Deselect a node.

Specified by:
unselect in interface TreeSelectionModel
Parameters:
treeNode - the node to deselect

addSelectionModelListener

public void addSelectionModelListener(DefaultSelectionModelListener listener)