Class QListControl
Abstract object which is extended by anything which involves lists of selectable items. This object is the foundation for the ListBox, CheckBoxList, RadioButtonList and TreeNav. Subclasses can be used as objects to specify one-to-many and many-to-many relationships.
- QBaseClass
- QHtmlAttributeManagerBase
- QHtmlAttributeManager
- QControlBase
- QControl
- QListControl uses QListItemManager
Indirect known subclasses
ProjectPickerListBox, QListBox, QSelectMenu, QSelectMenuBase, QSelectMenuGenPackage: Controls
See:
QListItemStyle
Located at includes/base_controls/QListControl.class.php
public
|
|
public
|
#
AddItems( array $mixItemArray, mixed $mixSelectedValues = null, string $strItemGroup = null, string $mixOverrideParameters = null )
Adds an array of items, or an array of key=>value pairs. Convenient for adding a list from a type table. When passing key=>val pairs, mixSelectedValues can be an array, or just a single value to compare against to indicate what is selected. |
public
string
|
|
public
|
#
UnselectAllItems( boolean $blnRefresh = true )
Recursively unselects all the items and subitems in the list. |
public
|
#
SetSelectedItemsById( array $strIdArray, boolean $blnRefresh = true )
Selects the given items by Id, and unselects items that are not in the list. |
public
|
#
SetSelectedItemsByIndex( array $intIndexArray, boolean $blnRefresh = true )
Set the selected item by index. This can only set top level items. Lower level items are untouched. |
public
|
#
SetSelectedItemsByValue( array $mixValueArray, boolean $blnRefresh = true )
Set the selected items by value. We equate nulls and empty strings, but must be careful not to equate those with a zero. |
public
|
#
SetSelectedItemsByName( array $strNameArray, boolean $blnRefresh = true )
Set the selected items by name. |
protected
|
#
RefreshSelection( )
This method is called when a selection is changed. It should execute the code to refresh the selected state of the items in the control. |
public
null|
|
|
public
|
|
public
mixed
|
|
public
|
|
public
mixed
|
|
public
mixed|
|
|
public static
|
#
GetModelConnectorParams( )
Returns a description of the options available to modify by the designer for the code generator. |
OverrideAttributes(),
__call()
|
CommentEnd,
CommentStart
|
protected
null| |
$objItemStyle
The common style for all elements in the list |
#
null
|
$attributes,
$styles
|
$objListItemArray
|
public
integer
|
$SelectedIndex
is the index number of the control that is selected. "-1" means that nothing is selected. If multiple items are selected, it will return the lowest index number of all ListItems that are currently selected. Set functionality: selects that specific ListItem and will unselect all other currently selected ListItems. |
public
string
|
$SelectedName
simply returns ListControl::SelectedItem->Name, or null if nothing is selected. |
public
mixed
|
$SelectedValue
simply returns ListControl::SelectedItem->Value, or null if nothing is selected. |
public
array
|
$SelectedNames
returns an array of all selected names |
public
array
|
$SelectedValues
returns an array of all selected values |
public
string
|
$ItemStyle |
public read-only
integer
|
$ItemCount
the current count of ListItems in the control. |
public read-only
|
$SelectedItem
(readonly!) returns the ListItem object, itself, that is selected (or the ListItem with the lowest index number of a ListItems that are currently selected if multiple items are selected). It will return null if nothing is selected. |
public read-only
array
|
$SelectedItems
returns an array of selected ListItems (if any). |
$AccessKey,
$AltText,
$BackColor,
$BorderCollapse,
$BorderColor,
$BorderStyle,
$BorderWidth,
$CssClass,
$Cursor,
$Data,
$Display,
$DisplayStyle,
$Enabled,
$FontBold,
$FontItalic,
$FontNames,
$FontOverline,
$FontSize,
$FontStrikeout,
$FontUnderline,
$ForeColor,
$Height,
$HorizontalAlign,
$Left,
$Margin,
$NoWrap,
$Opacity,
$OrderedListType,
$Overflow,
$Padding,
$Position,
$ReadOnly,
$TabIndex,
$ToolTip,
$Top,
$UnorderedListStyle,
$VerticalAlign,
$Width
|