summaryrefslogtreecommitdiffstats
path: root/Swift
diff options
context:
space:
mode:
authorKevin Smith <git@kismith.co.uk>2012-06-30 17:24:08 (GMT)
committerKevin Smith <git@kismith.co.uk>2012-06-30 17:24:08 (GMT)
commit022f9117b7ddd44334aad08290a156298a3e6a95 (patch)
treebd35ec936a0bc01790a7b7c38804ae9d8f1dce93 /Swift
parent479147718f1ec544a30930c8a77d460e74eb0287 (diff)
downloadswift-022f9117b7ddd44334aad08290a156298a3e6a95.zip
swift-022f9117b7ddd44334aad08290a156298a3e6a95.tar.bz2
Don't crash when going forward/backward through User Search and completing with no selection.
Resolves: #1062
Diffstat (limited to 'Swift')
-rw-r--r--Swift/QtUI/UserSearch/QtUserSearchWindow.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/Swift/QtUI/UserSearch/QtUserSearchWindow.cpp b/Swift/QtUI/UserSearch/QtUserSearchWindow.cpp
index 2b11d02..d69c626 100644
--- a/Swift/QtUI/UserSearch/QtUserSearchWindow.cpp
+++ b/Swift/QtUI/UserSearch/QtUserSearchWindow.cpp
@@ -78,6 +78,7 @@ QtUserSearchWindow::~QtUserSearchWindow() {
}
void QtUserSearchWindow::handleCurrentChanged(int page) {
+ resultsPage_->emitCompletenessCheck();
if (page == 2 && lastPage_ == 1) {
setError("");
/* next won't be called if JID is selected */
@@ -254,6 +255,7 @@ void QtUserSearchWindow::setResults(const std::vector<UserSearchResult>& results
delete model_;
model_ = newModel;
resultsPage_->setNoResults(model_->rowCount() == 0);
+ resultsPage_->emitCompletenessCheck();
}
void QtUserSearchWindow::setResultsForm(Form::ref results) {
@@ -266,6 +268,7 @@ void QtUserSearchWindow::setResultsForm(Form::ref results) {
delete model_;
model_ = newModel;
resultsPage_->setNoResults(model_->rowCount() == 0);
+ resultsPage_->emitCompletenessCheck();
}
void QtUserSearchWindow::setSelectedService(const JID& jid) {