diff options
author | Remko Tronçon <git@el-tramo.be> | 2011-02-07 20:39:05 (GMT) |
---|---|---|
committer | Remko Tronçon <git@el-tramo.be> | 2011-02-07 20:39:05 (GMT) |
commit | e520ec1c7521c855e8d91748ed661b9848c324a1 (patch) | |
tree | b0a9cafcb13565b3289909080c8d51e47e5832b0 /Swift/QtUI/UserSearch | |
parent | 4636fb155afcb2d7084e7a0debfa093780488f22 (diff) | |
download | swift-contrib-e520ec1c7521c855e8d91748ed661b9848c324a1.zip swift-contrib-e520ec1c7521c855e8d91748ed661b9848c324a1.tar.bz2 |
Split contact editing out into separate widget.
Diffstat (limited to 'Swift/QtUI/UserSearch')
-rw-r--r-- | Swift/QtUI/UserSearch/QtUserSearchWindow.cpp | 35 |
1 files changed, 18 insertions, 17 deletions
diff --git a/Swift/QtUI/UserSearch/QtUserSearchWindow.cpp b/Swift/QtUI/UserSearch/QtUserSearchWindow.cpp index 6a97e3a..911d410 100644 --- a/Swift/QtUI/UserSearch/QtUserSearchWindow.cpp +++ b/Swift/QtUI/UserSearch/QtUserSearchWindow.cpp @@ -28,17 +28,6 @@ QtUserSearchFirstPage::QtUserSearchFirstPage(UserSearchWindow::Type type, const connect(service_, SIGNAL(textChanged(const QString&)), this, SLOT(emitCompletenessCheck())); } -QtUserSearchFieldsPage::QtUserSearchFieldsPage() { - setupUi(this); -} - -QtUserSearchResultsPage::QtUserSearchResultsPage() { - setupUi(this); - connect(results_, SIGNAL(activated(const QModelIndex&)), this, SLOT(emitCompletenessCheck())); - connect(results_, SIGNAL(clicked(const QModelIndex&)), this, SLOT(emitCompletenessCheck())); - connect(results_, SIGNAL(entered(const QModelIndex&)), this, SLOT(emitCompletenessCheck())); -} - bool QtUserSearchFirstPage::isComplete() const { bool complete = false; if (byJID_->isChecked()) { @@ -51,22 +40,34 @@ bool QtUserSearchFirstPage::isComplete() const { return complete; } -bool QtUserSearchFieldsPage::isComplete() const { - return nickInput_->isEnabled() || firstInput_->isEnabled() || lastInput_->isEnabled() || emailInput_->isEnabled(); +void QtUserSearchFirstPage::emitCompletenessCheck() { + emit completeChanged(); } -bool QtUserSearchResultsPage::isComplete() const { - return results_->currentIndex().isValid(); + +QtUserSearchFieldsPage::QtUserSearchFieldsPage() { + setupUi(this); } -void QtUserSearchFirstPage::emitCompletenessCheck() { - emit completeChanged(); +bool QtUserSearchFieldsPage::isComplete() const { + return nickInput_->isEnabled() || firstInput_->isEnabled() || lastInput_->isEnabled() || emailInput_->isEnabled(); } void QtUserSearchFieldsPage::emitCompletenessCheck() { emit completeChanged(); } +QtUserSearchResultsPage::QtUserSearchResultsPage() { + setupUi(this); + connect(results_, SIGNAL(activated(const QModelIndex&)), this, SLOT(emitCompletenessCheck())); + connect(results_, SIGNAL(clicked(const QModelIndex&)), this, SLOT(emitCompletenessCheck())); + connect(results_, SIGNAL(entered(const QModelIndex&)), this, SLOT(emitCompletenessCheck())); +} + +bool QtUserSearchResultsPage::isComplete() const { + return results_->currentIndex().isValid(); +} + void QtUserSearchResultsPage::emitCompletenessCheck() { emit completeChanged(); } |