ECalClient: Use g_bus_watch_name_on_connection().
authorMatthew Barnes <mbarnes@redhat.com>
Sat, 9 Feb 2013 21:48:43 +0000 (16:48 -0500)
committerMatthew Barnes <mbarnes@redhat.com>
Sat, 9 Feb 2013 22:01:35 +0000 (17:01 -0500)
commit071047d9f26fa0a3b9226898fe63910b2501f232
tree4ef57e7a4ffc2ee5512476fbdd4653f221152165
parenta849265b5c6270bc1a427516a977eedf6da9deba
ECalClient: Use g_bus_watch_name_on_connection().

g_bus_watch_name_on_connection() handles "NameOwnerChanged" signals
as well as "closed" signals from the GDBusConnection.  In the event
the bus name vanishes, we schedule an idle callback on the client's
GMainContext to emit a "backend-died" signal.

Also while we're at it, call the close() method asynchronously from
dispose() so we don't block.
calendar/libecal/e-cal-client.c