summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKevin Smith <git@kismith.co.uk>2011-01-30 22:40:16 (GMT)
committerKevin Smith <git@kismith.co.uk>2011-01-30 22:40:16 (GMT)
commit34029b7c0d076f96cd35c9a87ae6303f14d4ff14 (patch)
tree6d9476018ee124defc5dd727adbf017bd8108749 /Swift/QtUI/QtMainWindow.cpp
parent6c6d21d6fdec74ae97ea653aaad799524a13447d (diff)
downloadswift-34029b7c0d076f96cd35c9a87ae6303f14d4ff14.zip
swift-34029b7c0d076f96cd35c9a87ae6303f14d4ff14.tar.bz2
Clickable roster header for profile edits (incomplete)
Diffstat (limited to 'Swift/QtUI/QtMainWindow.cpp')
-rw-r--r--Swift/QtUI/QtMainWindow.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/Swift/QtUI/QtMainWindow.cpp b/Swift/QtUI/QtMainWindow.cpp
index d313aba..ccf5a59 100644
--- a/Swift/QtUI/QtMainWindow.cpp
+++ b/Swift/QtUI/QtMainWindow.cpp
@@ -28,6 +28,7 @@
#include "Swift/Controllers/UIEvents/RequestJoinMUCUIEvent.h"
#include "Swift/Controllers/UIEvents/RequestAddUserDialogUIEvent.h"
#include "Swift/Controllers/UIEvents/RequestChatWithUserDialogUIEvent.h"
+#include "Swift/Controllers/UIEvents/RequestProfileEditorUIEvent.h"
#include "Swift/Controllers/UIEvents/JoinMUCUIEvent.h"
#include "Swift/Controllers/UIEvents/ToggleShowOfflineUIEvent.h"
@@ -42,6 +43,7 @@ QtMainWindow::QtMainWindow(QtSettingsProvider* settings, UIEventStream* uiEventS
meView_ = new QtRosterHeader(settings, this);
mainLayout->addWidget(meView_);
connect(meView_, SIGNAL(onChangeStatusRequest(StatusShow::Type, const QString&)), this, SLOT(handleStatusChanged(StatusShow::Type, const QString&)));
+ connect(meView_, SIGNAL(onEditProfileRequest()), this, SLOT(handleEditProfileRequest()));
tabs_ = new QtTabWidget(this);
#if QT_VERSION >= 0x040500
@@ -121,6 +123,10 @@ void QtMainWindow::setRosterModel(Roster* roster) {
treeWidget_->setRosterModel(roster);
}
+void QtMainWindow::handleEditProfileRequest() {
+ uiEventStream_->send(boost::make_shared<RequestProfileEditorUIEvent>());
+}
+
void QtMainWindow::handleEventCountUpdated(int count) {
QColor eventTabColor = (count == 0) ? QColor() : QColor(255, 0, 0); // invalid resets to default
int eventIndex = 1;
@@ -147,7 +153,7 @@ void QtMainWindow::handleSignOutAction() {
}
void QtMainWindow::handleEditProfileAction() {
- onEditProfileRequest();
+ uiEventStream_->send(boost::make_shared<RequestProfileEditorUIEvent>());
}
void QtMainWindow::handleJoinMUCAction() {