diff options
author | Kevin Smith <git@kismith.co.uk> | 2009-09-15 10:17:58 (GMT) |
---|---|---|
committer | Kevin Smith <git@kismith.co.uk> | 2009-09-15 10:17:58 (GMT) |
commit | e2045ebccf86d16eeb9dbf710c64dd2b4a4d6f94 (patch) | |
tree | 078eec96735f3fdf09cda7b0a39a2f45c8ecf775 /Swiften | |
parent | 13c1ef651158d8bdbd459ebea461c23c89699abd (diff) | |
download | swift-e2045ebccf86d16eeb9dbf710c64dd2b4a4d6f94.zip swift-e2045ebccf86d16eeb9dbf710c64dd2b4a4d6f94.tar.bz2 |
Reconnect seems to mostly work now.
It doesn't always re-enable the chat windows, though, so it's not perfect yet.
Diffstat (limited to 'Swiften')
-rw-r--r-- | Swiften/Client/Client.cpp | 4 | ||||
-rw-r--r-- | Swiften/Client/Client.h | 2 |
2 files changed, 6 insertions, 0 deletions
diff --git a/Swiften/Client/Client.cpp b/Swiften/Client/Client.cpp index 5d04a92..60dfade 100644 --- a/Swiften/Client/Client.cpp +++ b/Swiften/Client/Client.cpp @@ -24,6 +24,10 @@ Client::~Client() { delete connectionFactory_; } +bool Client::isAvailable() { + return session_; +} + void Client::connect() { DomainNameResolver resolver; try { diff --git a/Swiften/Client/Client.h b/Swiften/Client/Client.h index 516bee2..59e1c05 100644 --- a/Swiften/Client/Client.h +++ b/Swiften/Client/Client.h @@ -30,6 +30,8 @@ namespace Swift { void connect(); void disconnect(); + + bool isAvailable(); virtual void sendIQ(boost::shared_ptr<IQ>); virtual void sendMessage(boost::shared_ptr<Message>); |