summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Swift/QtUI/UserSearch/QtUserSearchWindow.cpp6
-rw-r--r--Swift/QtUI/UserSearch/QtUserSearchWindow.h2
2 files changed, 5 insertions, 3 deletions
diff --git a/Swift/QtUI/UserSearch/QtUserSearchWindow.cpp b/Swift/QtUI/UserSearch/QtUserSearchWindow.cpp
index 7e3c98d..e426dd7 100644
--- a/Swift/QtUI/UserSearch/QtUserSearchWindow.cpp
+++ b/Swift/QtUI/UserSearch/QtUserSearchWindow.cpp
@@ -20,8 +20,10 @@
namespace Swift {
-QtUserSearchFirstPage::QtUserSearchFirstPage() {
+QtUserSearchFirstPage::QtUserSearchFirstPage(UserSearchWindow::Type type) {
setupUi(this);
+ setTitle(type == UserSearchWindow::AddContact ? "Add User" : "Chat to User");
+ setSubTitle(QString("%1. If you know their JID you can enter it directly, or you can search for them.").arg(type == UserSearchWindow::AddContact ? "Add another user to your roster" : "Chat to another user"));
connect(jid_, SIGNAL(textChanged(const QString&)), this, SLOT(emitCompletenessCheck()));
connect(service_, SIGNAL(textChanged(const QString&)), this, SLOT(emitCompletenessCheck()));
}
@@ -77,7 +79,7 @@ QtUserSearchWindow::QtUserSearchWindow(UIEventStream* eventStream, UserSearchWin
setupUi(this);
model_ = new UserSearchModel();
delegate_ = new UserSearchDelegate();
- firstPage_ = new QtUserSearchFirstPage();
+ firstPage_ = new QtUserSearchFirstPage(type);
connect(firstPage_->byJID_, SIGNAL(toggled(bool)), this, SLOT(handleFirstPageRadioChange()));
connect(firstPage_->byLocalSearch_, SIGNAL(toggled(bool)), this, SLOT(handleFirstPageRadioChange()));
connect(firstPage_->byRemoteSearch_, SIGNAL(toggled(bool)), this, SLOT(handleFirstPageRadioChange()));
diff --git a/Swift/QtUI/UserSearch/QtUserSearchWindow.h b/Swift/QtUI/UserSearch/QtUserSearchWindow.h
index cc6eefb..b238e94 100644
--- a/Swift/QtUI/UserSearch/QtUserSearchWindow.h
+++ b/Swift/QtUI/UserSearch/QtUserSearchWindow.h
@@ -25,7 +25,7 @@ namespace Swift {
class QtUserSearchFirstPage : public QWizardPage, public Ui::QtUserSearchFirstPage {
Q_OBJECT
public:
- QtUserSearchFirstPage();
+ QtUserSearchFirstPage(UserSearchWindow::Type type);
virtual bool isComplete() const;
public slots:
void emitCompletenessCheck();