collection_backend_child_added: Inherit the auth session type.
authorMatthew Barnes <mbarnes@redhat.com>
Fri, 1 Feb 2013 18:34:19 +0000 (13:34 -0500)
committerMatthew Barnes <mbarnes@redhat.com>
Fri, 1 Feb 2013 19:15:17 +0000 (14:15 -0500)
Collection children will inherit the collection source's authentication
session type, so password-based authentication is consistent across the
entire collection.

libebackend/e-collection-backend.c

index c760e86..22a8b27 100644 (file)
@@ -719,6 +719,12 @@ collection_backend_child_added (ECollectionBackend *backend,
        e_server_side_source_set_removable (
                E_SERVER_SIDE_SOURCE (child_source), FALSE);
 
+       /* Collection children inherit the authentication session type. */
+       g_object_bind_property (
+               collection_source, "auth-session-type",
+               child_source, "auth-session-type",
+               G_BINDING_SYNC_CREATE);
+
        /* Collection children inherit OAuth 2.0 support if available. */
        g_object_bind_property (
                collection_source, "oauth2-support",