Top | ![]() |
![]() |
![]() |
![]() |
void | galago_presence_set_idle () |
void | galago_presence_set_statuses () |
void | galago_presence_add_status () |
void | galago_presence_remove_status () |
void | galago_presence_clear_statuses () |
GalagoAccount * | galago_presence_get_account () |
gboolean | galago_presence_is_idle () |
time_t | galago_presence_get_idle_time () |
time_t | galago_presence_get_idle_start_time () |
gboolean | galago_presence_is_discarded () |
gboolean | galago_presence_is_available () |
GList * | galago_presence_get_statuses () |
GalagoStatus * | galago_presence_get_active_status () |
gboolean | galago_presence_is_status_exclusive () |
GalagoStatus * | galago_presence_get_status () |
gboolean | galago_presence_has_status () |
gboolean | galago_presence_has_status_type () |
int | galago_presence_compare () |
void | changed | Action |
void | idle-changed | Action |
void | status-added | Action |
void | status-removed | Action |
void | status-updated | Action |
GalagoPresence contains information on a GalagoAccount's presence, including idle time and a list of statuses.
void galago_presence_set_idle (GalagoPresence *presence
,gboolean idle
,time_t idle_start_time
);
Sets the idle start time on a presence.
void galago_presence_set_statuses (GalagoPresence *presence
,GList *statuses
);
Sets a list of statuses in a presence.
The presence claims ownership of the list and will free it when destroyed.
void galago_presence_add_status (GalagoPresence *presence
,GalagoStatus *status
);
Adds a single status to a presence.
void galago_presence_remove_status (GalagoPresence *presence
,const char *status_id
);
Removes a single status from a presence.
The status being removed must not be an exclusive status.
void
galago_presence_clear_statuses (GalagoPresence *presence
);
Clears all statuses in a presence.
GalagoAccount *
galago_presence_get_account (const GalagoPresence *presence
);
Returns the account from a presence.
gboolean
galago_presence_is_idle (const GalagoPresence *presence
);
Returns the idle state from a presence.
time_t
galago_presence_get_idle_time (const GalagoPresence *presence
);
Returns the presence's idle time in seconds.
time_t
galago_presence_get_idle_start_time (const GalagoPresence *presence
);
Returns the time the presence was marked idle.
gboolean
galago_presence_is_discarded (const GalagoPresence *presence
);
Returns whether or not this is a discarded presence.
A discarded presence signifies that all existing presence info for that user is to be discarded.
gboolean
galago_presence_is_available (const GalagoPresence *presence
);
Returns whether or not a presence is considered available.
GList *
galago_presence_get_statuses (const GalagoPresence *presence
);
Returns the list of statuses from a presence.
GalagoStatus *
galago_presence_get_active_status (const GalagoPresence *presence
);
Returns the active exclusive status from a presence.
gboolean galago_presence_is_status_exclusive (const GalagoPresence *presence
,const char *status_id
);
Returns whether or not the status with the specified ID in a presence is exclusive.
GalagoStatus * galago_presence_get_status (const GalagoPresence *presence
,const char *status_id
);
Returns the status from a presence with the specified ID.
gboolean galago_presence_has_status (const GalagoPresence *presence
,const char *status_id
);
Returns whether or not a presence has a status with the specified ID.
gboolean galago_presence_has_status_type (const GalagoPresence *presence
,GalagoStatusType type
);
Returns whether or not a presence has a status with the specified primitive type.
int galago_presence_compare (const GalagoPresence *presence1
,const GalagoPresence *presence2
);
Compares two presences for availability.
struct GalagoPresence;
This is an opaque structure representing a presence. This should not be used directly. Use the accessor functions below.
#define GALAGO_DBUS_PRESENCE_INTERFACE "org.freedesktop.Galago.Presence"
The D-BUS interface that GalagoPresence maps to.
“account”
property“account” GalagoAccount *
The account that owns this presence.
Flags: Read / Write / Construct Only
“changed”
signalvoid user_function (GalagoPresence *presence, gpointer user_data)
Emitted when a property (idle state or a status added or removed) on the presence is updated.
presence |
The object which received the signal. |
|
user_data |
user data set when the signal handler was connected. |
Flags: Action
“idle-changed”
signalvoid user_function (GalagoPresence *presence, gboolean idle, gulong idle_start_time, gpointer user_data)
Emitted whenever the idle state changes. If idle
is TRUE
,
idle_start_time
will be a UNIX timestamp indicating when the user
went idle. Otherwise, it will be 0.
presence |
The object which received the signal. |
|
idle |
The idle state. |
|
idle_start_time |
The time the user went idle, if |
|
user_data |
user data set when the signal handler was connected. |
Flags: Action
“status-added”
signalvoid user_function (GalagoPresence *presence, gpointer status, gpointer user_data)
Emitted whenever a status is added.
presence |
The object which received the signal. |
|
status |
The status that was added. |
|
user_data |
user data set when the signal handler was connected. |
Flags: Action
“status-removed”
signalvoid user_function (GalagoPresence *presence, gpointer status, gpointer user_data)
Emitted whenever a status is removed.
presence |
The object which received the signal. |
|
status |
The status that was removed. |
|
user_data |
user data set when the signal handler was connected. |
Flags: Action
“status-updated”
signalvoid user_function (GalagoPresence *presence, gpointer status, gchar *name, gpointer user_data)
Emitted when an attribute on a status was set or updated.
presence |
The object which received the signal. |
|
status |
The status that was updated. |
|
name |
The name of the attribute updated. |
|
user_data |
user data set when the signal handler was connected. |
Flags: Action