|
PebbleOS v4.47.0-512-g5285d4236
|
Builds timeline items from ANCS notifications. More...
Functions | |
| TimelineItem * | ancs_item_create_and_populate (const struct pbl_bt_ancs_attr *const *notif_attributes, const struct pbl_bt_ancs_attr *const *app_attributes, const ANCSAppMetadata *app_metadata, iOSNotifPrefs *notif_prefs, time_t timestamp, const struct pbl_bt_ancs_notif *notif) |
| Create a timeline item from ANCS data. | |
| void | ancs_item_update_dismiss_action (TimelineItem *item, uint32_t uid, const struct pbl_bt_ancs_attr *attr_action_neg) |
| Replace the dismiss action of an item with an ANCS negative action. | |
Builds timeline items from ANCS notifications.
| TimelineItem * ancs_item_create_and_populate | ( | const struct pbl_bt_ancs_attr *const * | notif_attributes, |
| const struct pbl_bt_ancs_attr *const * | app_attributes, | ||
| const ANCSAppMetadata * | app_metadata, | ||
| iOSNotifPrefs * | notif_prefs, | ||
| time_t | timestamp, | ||
| const struct pbl_bt_ancs_notif * | notif | ||
| ) |
Create a timeline item from ANCS data.
Strings that reach the ANCS length limit are ellipsized. Actions are, in order, the ANCS positive and negative actions followed by the actions from notif_prefs.
| notif_attributes | Notification attributes, indexed by enum ancs_notif_attr. |
| app_attributes | App attributes (the display name), indexed by enum ancs_app_attr. |
| app_metadata | Icon and color of the app. |
| notif_prefs | iOS notification prefs of the app, may be NULL. |
| timestamp | Time the notification occurred. |
| notif | The notification, as the phone told of it. |
| void ancs_item_update_dismiss_action | ( | TimelineItem * | item, |
| uint32_t | uid, | ||
| const struct pbl_bt_ancs_attr * | attr_action_neg | ||
| ) |
Replace the dismiss action of an item with an ANCS negative action.
The item's buffer is reallocated; pointers into the old one become invalid.
| [in,out] | item | Item to update. Nothing happens if it has no dismiss action. |
| uid | ANCS UID of the notification whose negative action is used. | |
| attr_action_neg | Negative action label from that notification. |