6 public class ConnectionManager
8 public const string JabberService
= "org.freedesktop.Telepathy.ConnectionManager.gabble";
9 public const string JabberPath
= "/org/freedesktop/Telepathy/ConnectionManager/gabble";
11 public const string MsnService
= "org.freedesktop.Telepathy.ConnectionManager.msn";
12 public const string MsnPath
= "/org/freedesktop/Telepathy/ConnectionManager/msn";
14 public static IConnectionManager
FromProtocol (string protocol
)
17 Connection conn
= NDesk
.DBus
.Bus
.Session
;
19 if (protocol
== "jabber" || protocol
== "google-talk")
20 return conn
.GetObject
<IConnectionManager
> (JabberService
, new ObjectPath (JabberPath
));
22 if (protocol
== "msn")
23 return conn
.GetObject
<IConnectionManager
> (MsnService
, new ObjectPath (MsnPath
));
25 throw new Exception ("Unsupported protocol");
28 public static class PresenceStr
30 public const string Available
= "available";
31 public const string Brb
= "brb";
32 public const string Busy
= "busy";
33 public const string Dnd
= "dnd";
34 public const string ExtendedAway
= "xa";
35 public const string Hidden
= "hidden";
36 public const string Offline
= "offline";