Class SchedulerCellContainer
A base class for all visual elements in RadScheduler that can contain cells or appointments (for example DayViewAppointmentsTable, MonthViewAreaElement, TimelineAppointmentsPresenter, etc.)
Inheritance
Inherited Members
Namespace: Telerik.WinControls.UI
Assembly: Telerik.WinControls.Scheduler.dll
Syntax
public abstract class SchedulerCellContainer : SchedulerVisualElement, INotifyPropertyChanged, ICustomTypeDescriptor, ISupportSystemSkin, IComponent, IDisposable, IBindableComponent, ISupportDrag, ISupportDrop, IShortcutProvider, IStylableElement, IStylableNode, IPrimitiveElement, IShapedElement, IFillElement, IBorderElement, IBoxStyle, IBoxElement, IImageElement, ITextPrimitive, ITextProvider
Constructors
SchedulerCellContainer(RadScheduler, SchedulerView)
Declaration
public SchedulerCellContainer(RadScheduler scheduler, SchedulerView view)
Parameters
RadScheduler
scheduler
|
SchedulerView
view
|
Properties
AppointmentElements
Gets the AppointmentElement elements that belong to this container.
Declaration
public List<AppointmentElement> AppointmentElements { get; }
Property Value
System.Collections.Generic.List<AppointmentElement>
|
CellElements
Gets the SchedulerCellElement elements that belong to this container.
Declaration
public List<SchedulerCellElement> CellElements { get; }
Property Value
System.Collections.Generic.List<SchedulerCellElement>
|
Methods
CreateAppointmentElements()
Creates AppointmentElement elements which will be used in this container.
Declaration
protected abstract IEnumerable<AppointmentElement> CreateAppointmentElements()
Returns
System.Collections.Generic.IEnumerable<AppointmentElement>
A collection of the newly created appointment elements. |
CreateCellElements()
Creates SchedulerCellElement elements which will be used in this container.
Declaration
protected abstract IEnumerable<SchedulerCellElement> CreateCellElements()
Returns
System.Collections.Generic.IEnumerable<SchedulerCellElement>
A collection of the newly created cells. |
GetAppointmentElement(IEvent)
Gets the visual AppointmentElement associated with a specified appointment from this container.
Declaration
public AppointmentElement GetAppointmentElement(IEvent appointment)
Parameters
IEvent
appointment
The specified appointment. |
Returns
AppointmentElement
The visual element or null if no such element is found. |
GetCellByDate(DateTime)
Gets the cell which represents a specified date.
Declaration
public SchedulerCellElement GetCellByDate(DateTime date)
Parameters
System.DateTime
date
The specified date. |
Returns
SchedulerCellElement
The corresponding cell. |
InitializeAppointments()
Recycles the existing appointment elements in this container and replaces them with new ones.
Declaration
public virtual void InitializeAppointments()
InitializeCells()
Recycles the existing cell elements in this container and replaces them with new ones.
Declaration
public virtual void InitializeCells()
InitializeChildren()
Recycles the existing cell and appointment elements in this container and replaces them with new ones.
Declaration
public void InitializeChildren()
OnAppointmentLayout(AppointmentElement, RectangleF, SizeF)
Called when an appointment element is being arranged. Override to correct the arrange position of the appointment.
Declaration
protected virtual RectangleF OnAppointmentLayout(AppointmentElement appointment, RectangleF proposedRect, SizeF finalSize)
Parameters
AppointmentElement
appointment
The appointment element that is being arranged. |
System.Drawing.RectangleF
proposedRect
The calculated arrange rectangle. |
System.Drawing.SizeF
finalSize
The arrange size of the parent container. |
Returns
System.Drawing.RectangleF
The corrected arrange bounds. |
OnAppointmentsRefreshed()
Fires the AppointmentsRefreshed event.
Declaration
protected virtual void OnAppointmentsRefreshed()
OnAppointmentsRefreshing(CancelEventArgs)
Fires the AppointmentsRefreshing event.
Declaration
protected virtual void OnAppointmentsRefreshing(CancelEventArgs args)
Parameters
System.ComponentModel.CancelEventArgs
args
The event arguments for the event. |
OnBeginDispose()
OnCellLayout(SchedulerCellElement, RectangleF, SizeF)
Called when a cell element is being arranged. Override to correct the arrange position of the cell.
Declaration
protected virtual RectangleF OnCellLayout(SchedulerCellElement cell, RectangleF proposedRect, SizeF finalSize)
Parameters
SchedulerCellElement
cell
The cell element that is being arranged. |
System.Drawing.RectangleF
proposedRect
The calculated arrange rectangle. |
System.Drawing.SizeF
finalSize
The arrange size of the parent container. |
Returns
System.Drawing.RectangleF
The corrected arrange bounds. |
OnCellsRefreshed()
Fires the CellsRefreshed event.
Declaration
protected virtual void OnCellsRefreshed()
OnCellsRefreshing(CancelEventArgs)
Fires the CellsRefreshing event.
Declaration
protected virtual void OnCellsRefreshing(CancelEventArgs args)
Parameters
System.ComponentModel.CancelEventArgs
args
The event arguments for the event. |
RecycleAppointments()
Removes the existing appointment elements from the Children collection of the current container and tries to cache them for reusing in the future. If the caching is not successfull, the appointment element is disposed.
Declaration
protected virtual void RecycleAppointments()
RecycleCells()
Removes the existing cell elements from the Children collection of the current container and tries to cache them for reusing in the future. If the caching is not successfull, the cell is disposed.
Declaration
protected virtual void RecycleCells()
UpdateAppointments()
Synchronizes all appointment elements in this container with their associated IEvent.
Declaration
public virtual void UpdateAppointments()
UpdateCells()
Updates the existing cell elements according to the current settings of the associated view.
Declaration
public void UpdateCells()
UpdateCellsCore()
Events
AppointmentsRefreshed
Fired after the appointment elements in this container have been refreshed.
Declaration
public event EventHandler AppointmentsRefreshed
Event Type
System.EventHandler
|
AppointmentsRefreshing
Fired when the appointment elements in this container are about to be refreshed. Cancelable.
Declaration
public event CancelEventHandler AppointmentsRefreshing
Event Type
System.ComponentModel.CancelEventHandler
|
CellsRefreshed
Fired when the cell element in this container have been refreshed.
Declaration
public event EventHandler CellsRefreshed
Event Type
System.EventHandler
|
CellsRefreshing
Fired when the cell elements in this container are about to be refreshed. Cancelable.
Declaration
public event CancelEventHandler CellsRefreshing
Event Type
System.ComponentModel.CancelEventHandler
|