Class ListControl
Represents the list control that has multi-selection.
Inherited Members
Namespace: Telerik.Windows.Controls.Primitives
Assembly: Telerik.Windows.Controls.dll
Syntax
public class ListControl : ItemsControlSelector, IMultiSelector, ISelector, ISelectorInteraction, IAutocomplete, IListControl, ICommandSource, IScrollingServiceCore, IScrollingInfo
Constructors
ListControl()
Fields
CanAutocompleteSelectItemsProperty
Identifies the CanAutocompleteSelectItems dependency property.
Declaration
public static readonly DependencyProperty CanAutocompleteSelectItemsProperty
Field Value
System.
|
CanAutocompleteSelectPartialMatchesProperty
Identifies the CanAutocompleteSelectPartialMatches dependency property.
Declaration
public static readonly DependencyProperty CanAutocompleteSelectPartialMatchesProperty
Field Value
System.
|
CanKeyboardNavigationSelectItemsProperty
CommandParameterProperty
Identifies the CommandParameter dependency property.
Declaration
public static readonly DependencyProperty CommandParameterProperty
Field Value
System.
|
CommandProperty
Identifies the Command dependency property.
Declaration
public static readonly DependencyProperty CommandProperty
Field Value
System.
|
CommandTargetProperty
Identifies the CommandTarget dependency property.
Declaration
public static readonly DependencyProperty CommandTargetProperty
Field Value
System.
|
IsScrollIntoViewEnabledProperty
Identifies the IsScrollIntoViewOnSelectionEnabled dependency property. This property determines of the selected item will be automatically scrolled into the view.
Declaration
public static readonly DependencyProperty IsScrollIntoViewEnabledProperty
Field Value
System.
|
TextSearchModeProperty
Identifies the TextSearchMode dependency property.
Declaration
public static readonly DependencyProperty TextSearchModeProperty
Field Value
System.
|
TypedTextProperty
Identifies the TypedText dependency property.
Declaration
public static readonly DependencyProperty TypedTextProperty
Field Value
System.
|
Properties
AutocompleteBehavior
Gets or sets the autocomplete behavior.
Declaration
protected AutocompleteBehavior AutocompleteBehavior { get; set; }
Property Value
CanAutocompleteSelectItems
Gets or sets a value that specifies whether the autocomplete should select items, or not. This is a dependency property.
Declaration
public Nullable<bool> CanAutocompleteSelectItems { get; set; }
Property Value
System.
|
CanAutocompleteSelectPartialMatches
Gets or sets a value that specifies whether the autocomplete should select partially matching items, or not. This is a dependency property.
Declaration
public bool CanAutocompleteSelectPartialMatches { get; set; }
Property Value
System.
|
CanKeyboardNavigationSelectItems
Command
Gets or sets the Command. This is a dependency property.
Declaration
public ICommand Command { get; set; }
Property Value
System.
|
CommandParameter
Gets or sets the CommandParameter. This is a dependency property.
Declaration
public object CommandParameter { get; set; }
Property Value
System.
|
CommandTarget
Gets or sets the CommandTarget. This is a dependency property.
Declaration
public IInputElement CommandTarget { get; set; }
Property Value
System.
|
HighlightedIndex
Gets the index of the highlighted item.
Declaration
public int HighlightedIndex { get; }
Property Value
System. The index of the highlighted. |
Implements
HighlightedItem
Gets or sets the highlighted item.
Declaration
protected object HighlightedItem { get; set; }
Property Value
System.
|
IsItemsHostVisible
Gets a value indicating whether the items host is visible. Override if a custom logic is required. Default value is true.
Declaration
protected virtual bool IsItemsHostVisible { get; }
Property Value
System.
|
IsScrollIntoViewEnabled
Gets or sets the Is
Declaration
public bool IsScrollIntoViewEnabled { get; set; }
Property Value
System.
|
KeyboardNavigation
SelectAllCommand
Gets the command that will be executed when select all. This is a RoutedUICommand.
Declaration
public static RoutedUICommand SelectAllCommand { get; }
Property Value
System.
|
TextSearchMode
Gets or sets the text search mode. Specifies how TextSearch will match items. This is a dependency property.
Declaration
public TextSearchMode TextSearchMode { get; set; }
Property Value
Text The text search mode. |
TypedText
Gets or sets the current typed text. This is a dependency property.
Declaration
public string TypedText { get; set; }
Property Value
System.
|
Methods
CanPerformSelection()
Indicates whether the selection helper can perform operation or not.
Declaration
protected override bool CanPerformSelection()
Returns
System. Returns true if the panel is not null, is not Grid and ItemContainerGenerator.Status is GeneratingContainers; otherwise false. |
Overrides
ClearContainerForItemOverride(DependencyObject, Object)
Clears the values for SelectionHelper, ParentSelector and IsSelected properties.
Declaration
protected override void ClearContainerForItemOverride(DependencyObject element, object item)
Parameters
System. The ListItem container element. |
System. The item. |
ClearContainerStates(FrameworkElement)
Clears the properties that effect the visual states for the given container. This method is called in Clear
Declaration
protected virtual void ClearContainerStates(FrameworkElement container)
Parameters
System. The container which is cleared for item override. |
GetContainerForItemOverride()
Creates or identifies the element that is used to display the given item.
Declaration
protected override DependencyObject GetContainerForItemOverride()
Returns
System. The element that is used to display the given item. |
GetScrollViewerPart()
Called on initializing the ScrollViewer on template applied. It's mandatory to get the ScrollViewer in order to perform selection.
Declaration
protected virtual ScrollViewer GetScrollViewerPart()
Returns
System. The ScrollViewer instance in the control template. |
Remarks
If there is no ScrollViewer in the control template, override the logic in Can
HandleKeyboardInput(Key)
When overridden in a derived class, is invoked whenever application code or internal processes call Handle
Declaration
protected virtual bool HandleKeyboardInput(Key key)
Parameters
System. The key. |
Returns
System.
|
HighlightedIndexChanged(Int32, Key)
Highlights the changed index.
Declaration
protected virtual void HighlightedIndexChanged(int index, Key key)
Parameters
System.
|
System.
|
IsIndexSelectable(Int32)
Determines whether the index is selectable.
Declaration
protected override bool IsIndexSelectable(int index)
Parameters
System. The index. |
Returns
System.
|
Overrides
IsItemItsOwnContainerOverride(Object)
Determines if the specified item is (or is eligible to be) its own container.
Declaration
protected override bool IsItemItsOwnContainerOverride(object item)
Parameters
System. The item to check. |
Returns
System. True if the item is (or is eligible to be) its own container; otherwise, false. |
OnApplyTemplate()
When overridden in a derived class, is invoked whenever application code or internal processes call System.
Declaration
public override void OnApplyTemplate()
Overrides
OnAutocompleteBehaviorTypedTextChanged()
Called when a text is typed.
Declaration
protected virtual void OnAutocompleteBehaviorTypedTextChanged()
OnItemsPanelChanged(ItemsPanelTemplate, ItemsPanelTemplate)
Invoked when the System.
Declaration
protected override void OnItemsPanelChanged(ItemsPanelTemplate oldItemsPanel, ItemsPanelTemplate newItemsPanel)
Parameters
System. Old value of the System. |
System. New value of the System. |
OnMatchingItemChanged()
When overridden in a derived class, is invoked whenever application code or internal processes call
On
Declaration
protected virtual void OnMatchingItemChanged()
OnPropertyChanged(DependencyPropertyChangedEventArgs)
Declaration
protected override void OnPropertyChanged(DependencyPropertyChangedEventArgs e)
Parameters
System.
|
OnSelectionChanged(SelectionChangedEventArgs)
Called when the selection changes.
Declaration
protected override void OnSelectionChanged(SelectionChangedEventArgs e)
Parameters
System. The event data. |
Overrides
OnSelectionModeChanged()
Called when selection mode changed. Update CanAutocompleteSelectItems property.
Declaration
protected override void OnSelectionModeChanged()
Overrides
PrepareContainerForItemOverride(DependencyObject, Object)
Prepares the specified element to display the specified item.
Declaration
protected override void PrepareContainerForItemOverride(DependencyObject element, object item)
Parameters
System. Element used to display the specified item. |
System. Specified item. |
ScrollIntoView(Int32)
Scrolls the into view.
Declaration
public void ScrollIntoView(int index)
Parameters
System. The index. |
Implements
ScrollIntoView(Object)
Scrolls the into view.
Declaration
public void ScrollIntoView(object item)
Parameters
System.
|
Explicit Interface Implementations
IScrollingInfo.ExtentHeight
Declaration
double IScrollingInfo.ExtentHeight { get; }
Returns
System.
|
Implements
IScrollingInfo.ExtentWidth
Declaration
double IScrollingInfo.ExtentWidth { get; }
Returns
System.
|
Implements
IScrollingInfo.HorizontalOffset
Declaration
double IScrollingInfo.HorizontalOffset { get; }
Returns
System.
|
Implements
IScrollingInfo.TransformFromDropTargetToViewPort(Point)
Declaration
Point IScrollingInfo.TransformFromDropTargetToViewPort(Point positionInDropTarget)
Parameters
System.
|
Returns
System.
|
Implements
IScrollingInfo.VerticalOffset
Declaration
double IScrollingInfo.VerticalOffset { get; }
Returns
System.
|
Implements
IScrollingInfo.ViewportHeight
Declaration
double IScrollingInfo.ViewportHeight { get; }
Returns
System.
|
Implements
IScrollingInfo.ViewportWidth
Declaration
double IScrollingInfo.ViewportWidth { get; }
Returns
System.
|
Implements
IScrollingServiceCore.ScrollHorizontal(Double)
Declaration
void IScrollingServiceCore.ScrollHorizontal(double offsetX)
Parameters
System.
|
Implements
IScrollingServiceCore.ScrollVertical(Double)
Declaration
void IScrollingServiceCore.ScrollVertical(double offsetY)
Parameters
System.
|
Implements
IListControl.Items
Declaration
IList IListControl.Items { get; }
Returns
System.
|