![]() |
![]() |
![]() |
Alarmd Reference Manual | ![]() |
---|---|---|---|---|
enum SystemuiDialogReason;void (*SystemuiAlarmdDialogCallback) (gpointer user_data, SystemuiDialogReason reason);void systemui_alarm_dialog_queue_append (time_t alarm_time, constgchar *title, constgchar *message, constgchar *sound, constgchar *icon,gboolean can_snooze, SystemuiAlarmdDialogCallback cb,gpointer user_data);void systemui_alarm_dialog_queue_remove (time_t alarm_time, constgchar *title, constgchar *message, constgchar *sound, constgchar *icon, SystemuiAlarmdDialogCallback cb,gpointer user_data);void systemui_powerup_dialog_queue_append (SystemuiAlarmdDialogCallback cb,gpointer user_data);void systemui_powerup_dialog_queue_remove (SystemuiAlarmdDialogCallback cb,gpointer user_data);void update_mce_alarm_visibility (void);void systemui_ack_all_dialogs (void);gboolean systemui_is_acting_dead (void);
These functions maintain a queue of alarm dialog requests and passes them to systemui as previous ones are closed.
typedef enum { DIALOG_ACK, DIALOG_SNOOZE, DIALOG_POWEROFF, DIALOG_POWERUP, DIALOG_POWERDOWN } SystemuiDialogReason;
An enumeration describing the possible acknowledge reasons for dialogs.
void (*SystemuiAlarmdDialogCallback) (gpointer user_data, SystemuiDialogReason reason);
Defines the callbeck used for replies from systemui-alarm.
user_data : |
user data set when the callback was connected. |
reason : |
The reason for calling the callback, will be one of SystemuiDialogReason. |
void systemui_alarm_dialog_queue_append (time_t alarm_time, constgchar *title, constgchar *message, constgchar *sound, constgchar *icon,gboolean can_snooze, SystemuiAlarmdDialogCallback cb,gpointer user_data);
Adds a request for a dialog to the queue. After the dialog has been acknowledged, the request is removed from the queue, no need to remove it manually.
alarm_time : |
Time of the alarm that should be shown in the dialog. |
title : |
Title of the dialog to be appended to the queue. |
message : |
Message of the dialog to be appended to the queue. |
sound : |
Sound for the dialog to be appended to the queue. |
icon : |
Icon for the dialog to be appended to the queue. |
can_snooze : |
TRUE if the dialog should have snooze button enabled. |
cb : |
Callback called when the dialog is acknowledged. |
user_data : |
user date to pass to the callback. |
void systemui_alarm_dialog_queue_remove (time_t alarm_time, constgchar *title, constgchar *message, constgchar *sound, constgchar *icon, SystemuiAlarmdDialogCallback cb,gpointer user_data);
Removes an alarm dialog request from the dialog queue.
alarm_time : |
As passed to systemui_alarm_dialog_queue_append. |
title : |
As passed to systemui_alarm_dialog_queue_append. |
message : |
As passed to systemui_alarm_dialog_queue_append. |
sound : |
As passed to systemui_alarm_dialog_queue_append. |
icon : |
As passed to systemui_alarm_dialog_queue_append. |
cb : |
As passed to systemui_alarm_dialog_queue_append. |
user_data : |
As passed to systemui_alarm_dialog_queue_append. |
void systemui_powerup_dialog_queue_append (SystemuiAlarmdDialogCallback cb,gpointer user_data);
Appends a powerup dialog request to the dialog queue. After the dialog has been acknowledged, the request is removed from the queue, no need to remove it manually.
cb : |
Callback called when the dialog is acknowledged. |
user_data : |
user date to pass to the callback. |
void systemui_powerup_dialog_queue_remove (SystemuiAlarmdDialogCallback cb,gpointer user_data);
Removes a powerup dialog request from the dialog queue.
cb : |
As passed to systemui_powerup_dialog_queue_append. |
user_data : |
As passed to systemui_powerup_dialog_queue_append. |
void update_mce_alarm_visibility (void);
Sends message to mce telling the alarm dialog visibility status.
void systemui_ack_all_dialogs (void);
Clears the queue acknowledging all alarms and tells systemui to close the currently showing one.