diff options
author | Kevin Smith <git@kismith.co.uk> | 2010-11-16 23:16:54 (GMT) |
---|---|---|
committer | Kevin Smith <git@kismith.co.uk> | 2010-11-16 23:22:13 (GMT) |
commit | 9c3d535b1dc82ff600862a1210993c362fda9b8e (patch) | |
tree | 76676afe8e4c70ffa88b98b4880862b3113902a6 /Swift/Controllers/Chat/MUCSearchController.h | |
parent | 2c5ef44b56d9c45254ea331a53fb6d8fe6efe7d1 (diff) | |
download | swift-contrib-9c3d535b1dc82ff600862a1210993c362fda9b8e.zip swift-contrib-9c3d535b1dc82ff600862a1210993c362fda9b8e.tar.bz2 |
Remember previous MUC service searches.
Resolves: #615
Release-Notes: The MUC Search will now remember previously searched services.
Diffstat (limited to 'Swift/Controllers/Chat/MUCSearchController.h')
-rw-r--r-- | Swift/Controllers/Chat/MUCSearchController.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/Swift/Controllers/Chat/MUCSearchController.h b/Swift/Controllers/Chat/MUCSearchController.h index 44b51d8..10988ad 100644 --- a/Swift/Controllers/Chat/MUCSearchController.h +++ b/Swift/Controllers/Chat/MUCSearchController.h @@ -17,6 +17,7 @@ #include "Swift/Controllers/UIEvents/UIEvent.h" #include "Swift/Controllers/Chat/MUCSearchController.h" +#include "Swift/Controllers/Settings/SettingsProvider.h" #include "Swiften/Elements/DiscoInfo.h" #include "Swiften/Elements/DiscoItems.h" #include "Swiften/Elements/ErrorPayload.h" @@ -85,7 +86,7 @@ namespace Swift { class MUCSearchController { public: - MUCSearchController(const JID& jid, UIEventStream* uiEventStream, MUCSearchWindowFactory* mucSearchWindowFactory, IQRouter* iqRouter); + MUCSearchController(const JID& jid, UIEventStream* uiEventStream, MUCSearchWindowFactory* mucSearchWindowFactory, IQRouter* iqRouter, SettingsProvider* settings); ~MUCSearchController(); private: void handleUIEvent(boost::shared_ptr<UIEvent> event); @@ -96,11 +97,15 @@ namespace Swift { void handleDiscoError(const JID& jid, const ErrorPayload& error); void removeService(const JID& jid); void refreshView(); + void loadServices(); + void addAndSaveServices(const JID& jid); UIEventStream* uiEventStream_; MUCSearchWindow* window_; MUCSearchWindowFactory* factory_; + SettingsProvider* settings_; boost::bsignals::scoped_connection uiEventConnection_; std::vector<JID> services_; + std::vector<JID> savedServices_; std::map<JID, MUCService> serviceDetails_; IQRouter* iqRouter_; JID jid_; |