ClassDesktopAlertPopup
This class represents the popup of a RadDesktopAlertcomponent. This popup hosts an instance of the RadDesktopAlertElementclass which represents the element hierarchy of the alert.
Definition
Namespace:Telerik.WinControls.UI
Assembly:Telerik.WinControls.UI.dll
Syntax:
public class DesktopAlertPopup : RadPopupControlBase, IDropTarget, ISynchronizeInvoke, IWin32Window, IBindableComponent, IComponent, IDisposable, INotifyPropertyChanged, ISupportInitializeNotification, ISupportInitialize, IComponentTreeHandler, ILayoutHandler, IAnalyticsProvider, IPopupControl
Inheritance: objectMarshalByRefObjectComponentControlScrollableControlRadControlRadPopupControlBaseDesktopAlertPopup
Implements:
Inherited Members
Constructors
DesktopAlertPopup(RadDesktopAlert)
Creates an instance of the DesktopAlertPopupclass.
Declaration
public DesktopAlertPopup(RadDesktopAlert owner)
Parameters
owner
An instance of the RadDesktopAlertclass that represents the owner alert of the DesktopAlertPopup
DesktopAlertPopup(RadElement, RadDesktopAlert)
Creates an instance of the DesktopAlertPopupclass with specified owner.
Declaration
public DesktopAlertPopup(RadElement element, RadDesktopAlert owner)
Parameters
element
An instance of the RadElementclass that represents the owner element of the DesktopAlertPopup
owner
An instance of the RadDesktopAlertclass that represents the owner alert of the DesktopAlertPopup
Properties
AlertElement
Gets an instance of the RadDesktopAlertElementwhich represents the main alert element.
Declaration
public RadDesktopAlertElement AlertElement { get; }
Property Value
AutoClose
Gets a sets a boolean value determining whether the alert popup will be automatically closed after a given amount of time.
AutoCloseDelay
Gets or sets the amount of time in seconds after which the alert will be automatically closed.
ButtonItems
Gets an instance of the RadItemCollectionthat holds the buttons items added to the alert component.
Declaration
public RadItemCollection ButtonItems { get; }
Property Value
CanMove
Gets or sets a boolean value determining whether the popup can be moved by dragging it by the grip.
CaptionText
Gets or sets the caption text of the alert.
ContentText
Gets or sets the content text of the alert.
Image
Gets or sets the content image of the alert.
IsPinned
Gets or sets a boolean value determining whether the popup is pinned on the screen.
OptionItems
Declaration
public RadItemCollection OptionItems { get; }
Property Value
ShowCloseButton
Gets or sets a boolean value determining whether the close button is shown.
ShowOptionsButton
Gets or sets a boolean value determining whether the options button is shown.
ShowPinButton
Gets or sets a boolean value determining whether the pin button is shown.
ThemeClassName
Gets or sets the class name string that ThemeResolutionService will use to find the themes registered for the control.
Declaration
public override string ThemeClassName { get; set; }
Property Value
Overrides
Remarks
By default the return value is RadControl's type FullName; Some controls like drop down menu has different ThemeClassName depending on the runtime usage of the control.
Methods
CanClosePopup(RadPopupCloseReason)
This method determines whether the IPopupControl can be closed. Used in the PopupManager class to prevent the IPopupControl from closing in specific occasions.
Declaration
public override bool CanClosePopup(RadPopupCloseReason reason)
Parameters
reason
The reason why the IPopupControl is closed.
Returns
True if the IPopupControl can be closed, otherwise false.
Overrides
ControlDefinesThemeForElement(RadElement)
Checks whether the element's theme is defined by the control.
Declaration
public override bool ControlDefinesThemeForElement(RadElement element)
Parameters
element
The element to should be checked.
Returns
true if the control defines theme for this element, false otherwise.
Overrides
Remarks
If true is returned the ThemeResolutionService would not not set any theme to the element to avoid duplicating the style settings of the element.
CreateChildItems(RadElement)
Declaration
protected override void CreateChildItems(RadElement parent)
Parameters
parent
Overrides
Dispose(bool)
Declaration
protected override void Dispose(bool disposing)
Parameters
disposing
Overrides
GetHorizontalPopupLocation(Rectangle)
Calculates the horizontal popup location based on the alignmentRectangle.
This method uses the HorizontalPopupAlignment property setting.
Declaration
protected override int GetHorizontalPopupLocation(Rectangle alignmentRectangle)
Parameters
alignmentRectangle
An instance of the Rectangle struct that represents the alignment rectangle.
Returns
Returns an integer that represents the X coordinate of the popup.
Overrides
OnKeyDown(Keys)
Executes when a key is pressed.
OnMouseDown(MouseEventArgs)
Declaration
protected override void OnMouseDown(MouseEventArgs e)
Parameters
e
Overrides
OnMouseEnter(EventArgs)
Declaration
protected override void OnMouseEnter(EventArgs e)
Parameters
e
Overrides
OnMouseLeave(EventArgs)
Declaration
protected override void OnMouseLeave(EventArgs e)
Parameters
e
Overrides
OnMouseMove(MouseEventArgs)
Declaration
protected override void OnMouseMove(MouseEventArgs e)
Parameters
e
Overrides
OnNotifyPropertyChanged(string)
Raises the PropertyChanged event
Declaration
protected override void OnNotifyPropertyChanged(string propertyName)
Parameters
propertyName
The name of the property
Overrides
OnPopupOpening(CancelEventArgs)
Fires when the popup is about to open.
Declaration
protected override void OnPopupOpening(CancelEventArgs args)
Parameters
args
A CancelEventArgs object that contains information about the event
Overrides
ResumeAutoClose()
Restarts the auto-close timer.
Declaration
public void ResumeAutoClose()
SetBoundsCore(int, int, int, int, BoundsSpecified)
Declaration
protected override void SetBoundsCore(int x, int y, int width, int height, BoundsSpecified specified)
Parameters
x
y
width
height
specified
Overrides
SuspendAutoClose()
Stops the auto-close timer.
Declaration
public void SuspendAutoClose()