ClassPopupEditorElement
Represents a popup editor element that provides dropdown functionality with list-based item selection and auto-complete features for data entry controls.
Definition
Namespace:Telerik.WinControls.UI
Assembly:Telerik.WinControls.UI.dll
Syntax:
public class PopupEditorElement : PopupEditorBaseElement, INotifyPropertyChanged, ICustomTypeDescriptor, ISupportSystemSkin, IBindableComponent, IComponent, IDisposable, ISupportDrag, ISupportDrop, IShortcutProvider, IStylableElement, IStylableNode, IInputEditor, IValueEditor, ISupportInitialize
Inheritance: objectDisposableObjectRadObjectRadElementVisualElementRadComponentElementRadItemRadEditorElementEditorBaseElementPopupEditorBaseElementPopupEditorElement
Derived Classes:
Implements:
Inherited Members
Constructors
PopupEditorElement()
Declaration
public PopupEditorElement()
Properties
AutoCompleteDataSource
Gets or sets the data source object that provides data items for the auto-complete suggest functionality.
Declaration
public virtual object AutoCompleteDataSource { get; set; }
Property Value
AutoCompleteDisplayMember
Gets or sets the property name of the data source that serves as the display member for auto-complete functionality.
Declaration
public virtual string AutoCompleteDisplayMember { get; set; }
Property Value
AutoCompleteValueMember
Gets or sets the property name of the data source that serves as the value member for auto-complete functionality.
Declaration
public virtual string AutoCompleteValueMember { get; set; }
Property Value
DefaultItemsCountInDropDown
Gets or sets the default number of items to display in the dropdown when the total item count exceeds this value.
Declaration
public virtual int DefaultItemsCountInDropDown { get; set; }
Property Value
DropDownHeight
Gets or sets the height in pixels of the dropdown portion of the popup editor, with automatic DPI scaling applied.
Declaration
[Browsable(true)]
public virtual int DropDownHeight { get; set; }
Property Value
DropDownMaxSize
Gets or sets the maximum size constraints for the dropdown popup, automatically adjusting minimum size if conflicts arise.
Declaration
[Browsable(true)]
public virtual Size DropDownMaxSize { get; set; }
Property Value
DropDownMinSize
Gets or sets the minimum size constraints for the dropdown popup, automatically adjusting maximum size if conflicts arise.
Declaration
[Browsable(true)]
public virtual Size DropDownMinSize { get; set; }
Property Value
ListElement
Gets or sets the RadListElement that hosts the selectable items within the popup dropdown.
Declaration
public RadListElement ListElement { get; set; }
Property Value
MaxDropDownItems
Gets or sets the maximum number of items to be displayed in the dropdown portion of the popup editor. When set to 0, all items are shown.
Popup
Gets or sets the popup control base that hosts the dropdown content, creating it lazily when first accessed.
Declaration
public virtual RadEditorPopupControlBase Popup { get; set; }
Property Value
Methods
CreateChildElements()
Creates child elements including the RadListElement and wires up event handlers for popup functionality.
Declaration
protected override void CreateChildElements()
Overrides
DisposeManagedResources()
Disposes managed resources by unwiring event handlers and calling the base dispose implementation.
Declaration
protected override void DisposeManagedResources()
Overrides
GetDesiredPopupSize()
Gets the desired popup size by calculating the optimal dimensions based on current content and settings.
GetPopupSize(RadPopupControlBase, bool)
Calculates the optimal size for the popup based on item count, sizing constraints, and available space.
Declaration
protected override Size GetPopupSize(RadPopupControlBase popup, bool measure)
Parameters
popup
The RadPopupControlBase for which to calculate the size.
measure
True to force measurement of elements; false to use cached measurements.
Returns
The calculated Size for the popup.
Overrides
InitializeFields()
Initializes the element's fields and ensures the binding context property is available for property change notifications.
Declaration
protected override void InitializeFields()
Overrides
NotifyOwner(PopupEditorNotificationData)
Notifies the owner control about popup editor events and data changes through the specified notification data.
Declaration
public virtual void NotifyOwner(PopupEditorNotificationData notificationData)
Parameters
notificationData
The PopupEditorNotificationData containing information about the event or change.
OnAutoCompeleteDataSourceChanged()
Called when the auto-complete data source changes, allowing derived classes to respond to data source modifications.
Declaration
protected virtual void OnAutoCompeleteDataSourceChanged()
OnPopupClosed(object, RadPopupClosedEventArgs)
Handles the popup closed event, allowing derived classes to perform cleanup or respond to popup closure.
Declaration
protected virtual void OnPopupClosed(object sender, RadPopupClosedEventArgs args)
Parameters
sender
The source of the event.
args
The RadPopupClosedEventArgs containing event data.
OnPopupOpened(object, EventArgs)
Handles the popup opened event, allowing derived classes to initialize popup state or respond to popup display.
OnPopupOpening(CancelEventArgs)
Handles the popup opening event, ensuring the popup size is recalculated if items are modified during opening.
Declaration
protected override void OnPopupOpening(CancelEventArgs e)
Parameters
e
The CancelEventArgs containing event data that can cancel the popup opening.
Overrides
SetDropDownBindingContext()
Sets the binding context for the dropdown popup to ensure proper data binding functionality.
Declaration
protected virtual void SetDropDownBindingContext()
UnwireEvents()
Unsubscribes from all event handlers to prevent memory leaks and ensure proper cleanup.
Declaration
protected virtual void UnwireEvents()
UpdatePopupMinMaxSize(RadPopupControlBase)
Updates the minimum and maximum size constraints for the popup control based on the configured dropdown size limits.
Declaration
protected override void UpdatePopupMinMaxSize(RadPopupControlBase popup)
Parameters
popup
The RadPopupControlBase to update with size constraints.
Overrides
WireEvents()
Subscribes to all necessary event handlers for the list element and popup control to enable proper functionality.
Declaration
protected virtual void WireEvents()
listElement_DataItemPropertyChanged(object, RadPropertyChangedEventArgs)
Handles data item property changes in the list element, allowing derived classes to respond to property modifications.
Declaration
protected virtual void listElement_DataItemPropertyChanged(object sender, RadPropertyChangedEventArgs e)
Parameters
sender
The source of the event.
e
The RadPropertyChangedEventArgs containing event data.