diff options
Diffstat (limited to 'Swift/QtUI/QtMainWindow.cpp')
-rw-r--r-- | Swift/QtUI/QtMainWindow.cpp | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/Swift/QtUI/QtMainWindow.cpp b/Swift/QtUI/QtMainWindow.cpp index 710ef61..fb84da4 100644 --- a/Swift/QtUI/QtMainWindow.cpp +++ b/Swift/QtUI/QtMainWindow.cpp @@ -40,6 +40,7 @@ QtMainWindow::QtMainWindow(UIEventStream* uiEventStream) : QWidget(), MainWindow meView_ = new QtRosterHeader(this); mainLayout->addWidget(meView_); connect(meView_, SIGNAL(onChangeStatusRequest(StatusShow::Type, const QString&)), this, SLOT(handleStatusChanged(StatusShow::Type, const QString&))); + connect(meView_, SIGNAL(onChangeNickRequest(const QString&)), this, SLOT(handleChangeNickRequest(const QString&))); tabs_ = new QtTabWidget(this); #if QT_VERSION >= 0x040500 @@ -162,8 +163,12 @@ void QtMainWindow::handleShowOfflineToggled(bool state) { } } -void QtMainWindow::setMyName(const String& name) { - meView_->setName(P2QSTRING(name)); +void QtMainWindow::setMyNick(const String& nick) { + meView_->setNick(P2QSTRING(nick)); +} + +void QtMainWindow::setMyJID(const JID& jid) { + meView_->setJID(P2QSTRING(jid.toBare().toString())); } void QtMainWindow::setMyAvatarPath(const String& path) { @@ -182,5 +187,9 @@ void QtMainWindow::setConnecting() { meView_->setConnecting(); } +void QtMainWindow::handleChangeNickRequest(const QString& nick) { + onChangeNickRequest(Q2PSTRING(nick)); +} + } |