summaryrefslogtreecommitdiffstats
path: root/Swift
diff options
context:
space:
mode:
authorRemko Tronçon <git@el-tramo.be>2010-10-10 18:01:30 (GMT)
committerRemko Tronçon <git@el-tramo.be>2010-10-10 18:01:30 (GMT)
commitdcf30da8e1bf6c3e42f9d0ac8adbdb14f77a9622 (patch)
treed564a22737c77fe33e43e42e6ff8f55a98a6dc6d /Swift
parent1a3208aff3349cdecec30f12dacfd10ecb5901eb (diff)
downloadswift-contrib-dcf30da8e1bf6c3e42f9d0ac8adbdb14f77a9622.zip
swift-contrib-dcf30da8e1bf6c3e42f9d0ac8adbdb14f77a9622.tar.bz2
Move SoftwareVersion responder from Swift to Client.
Diffstat (limited to 'Swift')
-rw-r--r--Swift/Controllers/MainController.cpp13
-rw-r--r--Swift/Controllers/MainController.h2
2 files changed, 3 insertions, 12 deletions
diff --git a/Swift/Controllers/MainController.cpp b/Swift/Controllers/MainController.cpp
index c219ae9..d7801f3 100644
--- a/Swift/Controllers/MainController.cpp
+++ b/Swift/Controllers/MainController.cpp
@@ -47,7 +47,6 @@
#include "Swiften/Elements/ChatState.h"
#include "Swiften/Elements/Presence.h"
#include "Swiften/Elements/VCardUpdate.h"
-#include "Swiften/Queries/Responders/SoftwareVersionResponder.h"
#include "Swift/Controllers/Settings/SettingsProvider.h"
#include "Swiften/Elements/DiscoInfo.h"
#include "Swiften/Queries/Responders/DiscoInfoResponder.h"
@@ -116,7 +115,6 @@ MainController::MainController(
xmppRosterController_ = NULL;
chatsManager_ = NULL;
eventWindowController_ = NULL;
- clientVersionResponder_ = NULL;
discoResponder_ = NULL;
mucSearchController_ = NULL;
@@ -201,11 +199,6 @@ void MainController::resetClient() {
delete discoResponder_;
discoResponder_ = NULL;
}
- if (clientVersionResponder_) {
- clientVersionResponder_->stop();
- delete clientVersionResponder_;
- clientVersionResponder_ = NULL;
- }
delete eventWindowController_;
eventWindowController_ = NULL;
delete xmppRosterController_;
@@ -293,9 +286,6 @@ void MainController::handleConnected() {
eventWindowController_ = new EventWindowController(eventController_, eventWindowFactory_);
- clientVersionResponder_ = new SoftwareVersionResponder(client_->getIQRouter());
- clientVersionResponder_->setVersion(CLIENT_NAME, buildVersion);
- clientVersionResponder_->start();
loginWindow_->morphInto(rosterController_->getWindow());
DiscoInfo discoInfo;
@@ -420,6 +410,9 @@ void MainController::performLoginFromCachedCredentials() {
}
if (!client_) {
client_ = new Swift::Client(jid_, password_);
+
+ client_->setSoftwareVersion(CLIENT_NAME, buildVersion);
+
presenceSender_ = new PresenceSender(client_->getStanzaChannel());
presenceOracle_ = new PresenceOracle(client_->getStanzaChannel());
mucRegistry_ = new MUCRegistry();
diff --git a/Swift/Controllers/MainController.h b/Swift/Controllers/MainController.h
index 0887007..fb26a9d 100644
--- a/Swift/Controllers/MainController.h
+++ b/Swift/Controllers/MainController.h
@@ -52,7 +52,6 @@ namespace Swift {
class EntityCapsManager;
class LoginWindow;
class EventLoop;
- class SoftwareVersionResponder;
class LoginWindowFactory;
class MUCController;
class Notifier;
@@ -149,7 +148,6 @@ namespace Swift {
EventController* eventController_;
EventWindowController* eventWindowController_;
LoginWindow* loginWindow_;
- SoftwareVersionResponder* clientVersionResponder_;
NickResolver* nickResolver_;
DiscoInfoResponder* discoResponder_;
UIEventStream* uiEventStream_;