Home2L - C/C++ API v1.4-0-g38cc (2024-05-25)
Smart Tools for a Private Home
|
Floorplan visualization.
Classes | |
class | CWidgetFloorplan |
Floorplan widget. More... | |
Enumerations | |
enum | EGadgetType { } |
Functions | |
void | RunResourceDialog (class CResource *rc, EGadgetType subType=gtNone, const char *title=NULL, bool emphasize=false) |
Run a dialog allowing to edit, add or delete a user request. More... | |
void | FloorplanActivate () |
Activate the floorplan screen. | |
void | FloorplanCheckAlert (CScreen *returnScreen=NULL) |
Check for an alert and if so activate the floorplan screen. More... | |
class CFloorplan * | FloorplanGetMain () |
Get a reference to the main floorplan (for CWidgetFloorplan::Setup() ). | |
void | FloorplanUnsubscribeAll () |
Unsubscribe all resources of the floorplan. More... | |
enum EGadgetType |
Gadget Type
These constants are used to identify a gadget type and for the resource dialog.
Enumerator | |
---|---|
gtWindow | window with a state of ERctWindowState (type rctBool is also allowed). |
gtDoor | door (visualized like a window) |
gtGate | gate (visualized like a window) |
gtShades | shades or blinds (type rctPercent) |
gtRoofWindow | roof window, optionally including shades |
gtGarage | garage door (open/close) |
gtTemp | temperature value |
gtLock | door lock |
gtMotion | motion status |
gtLight | light |
gtMail | mail box |
gtPhone | phone (with state ERctPhoneState) |
gtMusic | music player |
gtWlan | Wifi access point. |
gtBluetooth | Bluetooth. |
gtService | some generic service |
gtWarning | a warning sign |
Definition at line 58 of file floorplan.H.
void RunResourceDialog | ( | class CResource * | rc, |
EGadgetType | subType = gtNone , |
||
const char * | title = NULL , |
||
bool | emphasize = false |
||
) |
Run a dialog allowing to edit, add or delete a user request.
rc | is the resource. |
subType | is a subtype indication. For example, if 'rc->Type()' is rctPercent, setting the subtype to gtWindow will optimize the UI for a window opener ("%100" at the top), if set to gtShades, the UI presents a UI for shades ("0%" at the top). |
title | is the title of the dialog. If set to NULL, the title will be derived from 'subType'. If 'subType == gtNone', a generic default title will be shown. |
emphasize | lets the dialog appear red if set (if unset: auto-detect) |
void FloorplanCheckAlert | ( | CScreen * | returnScreen = NULL | ) |
Check for an alert and if so activate the floorplan screen.
returnScreen | specifies the screen to return to as soon as the alert is over. If NULL, the floorplan screen will remain activated when the alert is over. |
void FloorplanUnsubscribeAll | ( | ) |
Unsubscribe all resources of the floorplan.
On activation of the floorplan screen (FloorplanActivate () ) or some floorplan widget (CWidgetFloorplan), the resource subscriptions are updated to fit the screen or widget. On deactivation of those, nothing is changed. This function explicitly unsubscribes all resources to save power and CPU time.