api: add "Uuid" property to ActiveConnection interface

A convenience so that clients which might key certain operations off
which connections are active (checking work mail only when on VPN for
example) can more easily get which connections are active.  This would
allow those apps to store the UUID (which they would already be doing)
and not have to create a Connection proxy and then get the connection
properties just to retrieve the UUID of the connection.  Instead they
can now get it from GetAll of the ActiveConnection object, which they
would already be doing.
This commit is contained in:
Dan Williams
2011-04-22 11:29:09 -05:00
parent 5f627a52e5
commit bb8e9a0b18
8 changed files with 61 additions and 1 deletions

View File

@@ -35,6 +35,7 @@ nm_active_connection_get_next_object_path (void)
void
nm_active_connection_install_properties (GObjectClass *object_class,
guint prop_connection,
guint prop_uuid,
guint prop_specific_object,
guint prop_devices,
guint prop_state,
@@ -49,6 +50,13 @@ nm_active_connection_install_properties (GObjectClass *object_class,
DBUS_TYPE_G_OBJECT_PATH,
G_PARAM_READABLE));
g_object_class_install_property (object_class, prop_uuid,
g_param_spec_string (NM_ACTIVE_CONNECTION_UUID,
"Connection UUID",
"Connection UUID",
NULL,
G_PARAM_READABLE));
g_object_class_install_property (object_class, prop_specific_object,
g_param_spec_boxed (NM_ACTIVE_CONNECTION_SPECIFIC_OBJECT,
"Specific object",