Note: This API is now obsolete.
Manages objects that must be toggled on and off in a regular pattern over time. This is known as a cadence.
CadenceManager is intended primarily for Windows Forms controls, but can be used for any item that implements
the
ICadencedControl interface.
Inheritance HierarchySystemObject
ASCOM.ControlsCadenceManager
Namespace: ASCOM.ControlsAssembly: ASCOM.Controls (in ASCOM.Controls.dll) Version: 7.0.0-rc.0+0
Syntax[ObsoleteAttribute("An improved version of this class is available as a NuGet package at https://www.nuget.org/packages/TA.WinForms.Controls/")]
public sealed class CadenceManager
<ObsoleteAttribute("An improved version of this class is available as a NuGet package at https://www.nuget.org/packages/TA.WinForms.Controls/")>
Public NotInheritable Class CadenceManager
[ObsoleteAttribute(L"An improved version of this class is available as a NuGet package at https://www.nuget.org/packages/TA.WinForms.Controls/")]
public ref class CadenceManager sealed
The CadenceManager type exposes the following members.
Properties | Name | Description |
---|
  | Instance |
Gets a reference to the Singleton.
If the Singleton has not yet be instantiated, this causes the object
to be created and the constructor to execute (lazy loading).
This operation uses the double-checked locking pattern to ensure thread-safety.
|
Top
Methods | Name | Description |
---|
 | Add |
Adds the specified ICadencedControl to the list of managed controls.
If this is the first control being added, then the update timer is configured and started.
|
 | Remove |
Removes a control from the update list.
If no managed controls remain in the list, then the update timer is stopped.
|
Top
Remarks
CadenceManager behaves slightly differently if the managed item is a Windows Forms control.
- Invisible controls do not receive updates until they become visible again.
- The CadenceUpdate(Boolean) method is marshalled to the GUI thread.
See Also