-
public void add_action (string action, string label, owned ActionCallback callback)
Adds an action to a notification. When the action is invoked, the specified callback function will be
called, along with the value passed to user_data.
-
public void clear_actions ()
Clears all actions from the notification.
-
public void clear_hints ()
Clears all hints from the notification.
-
public bool close () throws Error
Synchronously tells the notification server to hide the notification on the screen.
-
public int get_closed_reason ()
Returns the closed reason code for the notification. This is valid only after the "closed" signal is
emitted.
-
public void set_category (string category)
Sets the category of this notification. This can be used by the notification server to filter or display
the data in a certain way.
-
public void set_hint (string key, Variant value)
Sets a hint for key with value value. If value is null
, a previously set hint for key is unset. If value is floating, it is consumed.
-
public void set_hint_byte (string key, uchar value)
Sets a hint with a byte value.
-
public void set_hint_byte_array (string key, uchar[] value, size_t len)
Sets a hint with a byte array value. The length of value must be passed as len
.
-
public void set_hint_double (string key, double value)
Sets a hint with a double value.
-
public void set_hint_int32 (string key, int value)
Sets a hint with a 32-bit integer value.
-
public void set_hint_string (string key, string value)
Sets a hint with a string value.
-
public void set_hint_uint32 (string key, uint value)
Sets a hint with an unsigned 32-bit integer value.
-
public void set_icon_from_pixbuf (Pixbuf icon)
Sets the icon in the notification from a
Pixbuf.
-
public void set_image_from_pixbuf (Pixbuf image)
Sets the image in the notification from a
Pixbuf.
-
public void set_timeout (int timeout)
Sets the timeout of the notification. To set the default time, pass
EXPIRES_DEFAULT as timeout. To set the notification to never
expire, pass EXPIRES_NEVER.
-
public void set_urgency (Urgency urgency)
Sets the urgency level of this notification.
-
public bool show () throws Error
Tells the notification server to display the notification on the screen.
-
public bool update (string summary, string body, string icon)
Updates the notification text and icon. This won't send the update out and display it on the screen. For
that, you will need to call show.