summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swift/QtUI/QtJoinMUCWindow.cpp')
-rw-r--r--Swift/QtUI/QtJoinMUCWindow.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/Swift/QtUI/QtJoinMUCWindow.cpp b/Swift/QtUI/QtJoinMUCWindow.cpp
index a44cdaf..fec3c4d 100644
--- a/Swift/QtUI/QtJoinMUCWindow.cpp
+++ b/Swift/QtUI/QtJoinMUCWindow.cpp
@@ -18,33 +18,34 @@ QtJoinMUCWindow::QtJoinMUCWindow(UIEventStream* uiEventStream) : uiEventStream(u
ui.room->setPlaceholderText(tr("someroom@rooms.example.com"));
#endif
connect(ui.room, SIGNAL(returnPressed()), this, SLOT(handleJoin()));
connect(ui.searchButton, SIGNAL(clicked()), this, SLOT(handleSearch()));
connect(ui.joinButton, SIGNAL(clicked()), this, SLOT(handleJoin()));
// FIXME: Temporarily set focus on the nickName field first, so that the
// placeholder for the room is visible. This is just because Qt hides
// the placeholder when a widget is focused for some reason.
ui.nickName->setFocus();
+ ui.instantRoom->setChecked(true);
}
void QtJoinMUCWindow::handleJoin() {
if (ui.room->text().isEmpty()) {
// TODO: Error
return;
}
if (ui.nickName->text().isEmpty()) {
// TODO: Error
return;
}
lastSetNick = Q2PSTRING(ui.nickName->text());
JID room(Q2PSTRING(ui.room->text()));
- uiEventStream->send(boost::make_shared<JoinMUCUIEvent>(room, lastSetNick, ui.joinAutomatically->isChecked()));
+ uiEventStream->send(boost::make_shared<JoinMUCUIEvent>(room, lastSetNick, ui.joinAutomatically->isChecked(), !ui.instantRoom->isChecked()));
hide();
}
void QtJoinMUCWindow::handleSearch() {
onSearchMUC();
}
void QtJoinMUCWindow::setNick(const std::string& nick) {
ui.nickName->setText(P2QSTRING(nick));