| Top |
| GStrv | actions | Read / Write |
| GIcon * | app-icon | Read / Write |
| GAppInfo * | app-info | Read / Write |
| char * | app-name | Read / Write |
| char * | body | Read / Write |
| char * | category | Read / Write |
| guint | id | Read / Write |
| GIcon * | image | Read / Write |
| gboolean | resident | Read / Write |
| char * | summary | Read / Write |
| GDateTime * | timestamp | Read / Write |
| gboolean | transient | Read / Write |
| PhoshNotificationUrgency | urgency | Read / Write |
| enum | PhoshNotificationUrgency |
| enum | PhoshNotificationReason |
| #define | PHOSH_NOTIFICATION_DEFAULT_ACTION |
| #define | PHOSH_TYPE_NOTIFICATION |
| struct | PhoshNotificationClass |
| PhoshNotification |
GEnum ├── PhoshNotificationReason ╰── PhoshNotificationUrgency GObject ╰── PhoshNotification ├── PhoshDBusNotification ╰── PhoshMountNotification
PhoshNotification * phosh_notification_new (guint id,const char *app_name,GAppInfo *info,const char *summary,const char *body,GIcon *icon,GIcon *image,PhoshNotificationUrgency urgency,GStrv actions,gboolean transient,gboolean resident,const char *category,GDateTime *timestamp);
void phosh_notification_set_summary (PhoshNotification *self,const char *summary);
const char *
phosh_notification_get_summary (PhoshNotification *self);
void phosh_notification_set_body (PhoshNotification *self,const char *body);
void phosh_notification_set_app_name (PhoshNotification *self,const char *app_name);
const char *
phosh_notification_get_app_name (PhoshNotification *self);
GDateTime *
phosh_notification_get_timestamp (PhoshNotification *self);
void phosh_notification_set_timestamp (PhoshNotification *self,GDateTime *timestamp);
Sets the timestamp of a notification. If NULL is passed it's set
to the current date and time.
void phosh_notification_set_app_icon (PhoshNotification *self,GIcon *icon);
GIcon *
phosh_notification_get_app_icon (PhoshNotification *self);
void phosh_notification_set_app_info (PhoshNotification *self,GAppInfo *info);
GAppInfo *
phosh_notification_get_app_info (PhoshNotification *self);
void phosh_notification_set_image (PhoshNotification *self,GIcon *icon);
void phosh_notification_set_urgency (PhoshNotification *self,PhoshNotificationUrgency urgency);
PhoshNotificationUrgency
phosh_notification_get_urgency (PhoshNotification *self);
void phosh_notification_set_actions (PhoshNotification *self,GStrv actions);
void phosh_notification_set_transient (PhoshNotification *self,gboolean transient);
Set if self
should go to the message tray
gboolean
phosh_notification_get_transient (PhoshNotification *self);
Transient notifications don't go to the message tray
void phosh_notification_set_resident (PhoshNotification *self,gboolean resident);
Set whether of not invoking actions dismiss self
gboolean
phosh_notification_get_resident (PhoshNotification *self);
When TRUE invoking an action _doesn't_ dismiss the notification
void phosh_notification_set_category (PhoshNotification *self,const char *category);
Set the type of notification, such as "email.arrived"
const char *
phosh_notification_get_category (PhoshNotification *self);
Get the category hint the notification was sent with
See https://people.gnome.org/~mccann/docs/notification-spec/notification-spec-latest.htmlcategories
void phosh_notification_activate (PhoshNotification *self,const char *action);
void phosh_notification_expires (PhoshNotification *self,int timeout);
Set self
to expire after timeout
(from this call)
Note doesn't close the notification, for that call
phosh_notification_close() is response to “expired”
void phosh_notification_close (PhoshNotification *self,PhoshNotificationReason reason);
void phosh_notification_do_action (PhoshNotification *notification,guint id,const char *action);
struct PhoshNotificationClass {
GObjectClass parent_class;
void (*do_action)(PhoshNotification *self, guint id, const char *action);
};
“actions” property“actions” GStrv
Notification actions.
Owner: PhoshNotification
Flags: Read / Write
“app-icon” property“app-icon” GIcon *
Application icon.
Owner: PhoshNotification
Flags: Read / Write
“app-info” property“app-info” GAppInfo *
When non-NULL this overrides the values of “app-name”
and “app-icon” with those from the GAppInfo
Owner: PhoshNotification
Flags: Read / Write
“app-name” property “app-name” char *
The applications's name.
Owner: PhoshNotification
Flags: Read / Write
Default value: ""
“body” property “body” char *
The notification's body.
Owner: PhoshNotification
Flags: Read / Write
Default value: ""
“category” property “category” char *
The notification's category.
Owner: PhoshNotification
Flags: Read / Write
Default value: ""
“id” property“id” guint
Notification ID.
Owner: PhoshNotification
Flags: Read / Write
Default value: 0
“image” property“image” GIcon *
Notification image.
Owner: PhoshNotification
Flags: Read / Write
“resident” property“resident” gboolean
The notification is resident.
Owner: PhoshNotification
Flags: Read / Write
Default value: FALSE
“summary” property “summary” char *
The notification's summary.
Owner: PhoshNotification
Flags: Read / Write
Default value: ""
“timestamp” property“timestamp” GDateTime *
The time that notification came in.
Owner: PhoshNotification
Flags: Read / Write
“transient” property“transient” gboolean
The notification is transient.
Owner: PhoshNotification
Flags: Read / Write
Default value: FALSE
“urgency” property“urgency” PhoshNotificationUrgency
Notification urgency.
Owner: PhoshNotification
Flags: Read / Write
Default value: PHOSH_NOTIFICATION_URGENCY_NORMAL
“actioned” signalvoid user_function (PhoshNotification *phoshnotification, char *arg1, gpointer user_data)
Flags: Run Last
“closed” signalvoid user_function (PhoshNotification *phoshnotification, PhoshNotificationReason arg1, gpointer user_data)
Flags: Run Last
“expired” signalvoid user_function (PhoshNotification *phoshnotification, gpointer user_data)
Flags: Run Last