PebbleOS
Loading...
Searching...
No Matches
Functions
Alarm pins

Timeline pins showing alarms. More...

Functions

status_t alarm_pin_add (time_t alarm_time, AlarmId id, AlarmType type, AlarmKind kind, Uuid *uuid_out)
 Add a pin for an alarm to the timeline.
 
void alarm_pin_remove (Uuid *alarm_id)
 Remove an alarm pin from the timeline.
 
status_t alarm_pin_remove_untracked_future (time_t now, const Uuid *tracked, size_t tracked_count)
 Remove future alarm pins that no alarm tracks anymore.
 

Detailed Description

Timeline pins showing alarms.

Pins are created from the watch with the alarms data source as parent, and an action that opens the alarm in the alarms app.

Function Documentation

◆ alarm_pin_add()

status_t alarm_pin_add ( time_t  alarm_time,
AlarmId  id,
AlarmType  type,
AlarmKind  kind,
Uuid *  uuid_out 
)

Add a pin for an alarm to the timeline.

Parameters
alarm_timeTime of the pin.
idAlarm the pin belongs to.
typeAlarm type, selects the pin title.
kindAlarm recurrence, shown on the pin.
[out]uuid_outID of the new pin, may be NULL.
Return values
S_SUCCESSPin added.
E_OUT_OF_MEMORYThe pin could not be created.
Returns
Other pin database errors.

◆ alarm_pin_remove()

void alarm_pin_remove ( Uuid *  alarm_id)

Remove an alarm pin from the timeline.

Parameters
alarm_idID of the pin to remove.

◆ alarm_pin_remove_untracked_future()

status_t alarm_pin_remove_untracked_future ( time_t  now,
const Uuid *  tracked,
size_t  tracked_count 
)

Remove future alarm pins that no alarm tracks anymore.

Parameters
nowCurrent time; pins before it are kept.
trackedIDs of the pins still owned by alarms.
tracked_countNumber of entries in tracked.
Return values
S_SUCCESSAll untracked future pins were removed.
Returns
Otherwise, the pin database error.