summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKevin Smith <git@kismith.co.uk>2012-02-06 12:59:12 (GMT)
committerKevin Smith <git@kismith.co.uk>2012-02-06 13:39:43 (GMT)
commit94b7aaf53c8b20e03c8081cce49cda14cd5c01da (patch)
tree95b73b6021f332da7ae3197ad2c97dee2f2ebae3 /Swift/QtUI/QtChatWindow.cpp
parentf3d68b13e120f471326449f68aa4140587d444fc (diff)
downloadswift-contrib-94b7aaf53c8b20e03c8081cce49cda14cd5c01da.zip
swift-contrib-94b7aaf53c8b20e03c8081cce49cda14cd5c01da.tar.bz2
Display mediated invites
Diffstat (limited to 'Swift/QtUI/QtChatWindow.cpp')
-rw-r--r--Swift/QtUI/QtChatWindow.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/Swift/QtUI/QtChatWindow.cpp b/Swift/QtUI/QtChatWindow.cpp
index 88f326f..ed8e632 100644
--- a/Swift/QtUI/QtChatWindow.cpp
+++ b/Swift/QtUI/QtChatWindow.cpp
@@ -795,14 +795,18 @@ void QtChatWindow::showRoomConfigurationForm(Form::ref form) {
mucConfigurationWindow_->onFormCancelled.connect(boost::bind(boost::ref(onConfigurationFormCancelled)));
}
-void QtChatWindow::addMUCInvitation(const JID& jid, const std::string& reason, const std::string& /*password*/) {
+void QtChatWindow::addMUCInvitation(const JID& jid, const std::string& reason, const std::string& /*password*/, bool direct) {
bool accepted = false;
QMessageBox msgBox;
+ //FIXME: horrid modal untranslated popup. Fix before release.
msgBox.setText(QString("You have been invited to the room %1 by %2.").arg(P2QSTRING(jid.toString())).arg(contact_));
QString reasonString;
if (!reason.empty()) {
reasonString = QString("\"%1\"").arg(P2QSTRING(reason));
}
+ if (!direct) {
+ reasonString += QString("(%1 may not have really sent this invitation)").arg(P2QSTRING(jid.toString()));
+ }
msgBox.setInformativeText(QString("Accept invitation from %1 to enter %2?\n%3").arg(contact_).arg(P2QSTRING(jid.toString())).arg(reasonString));
msgBox.setStandardButtons(QMessageBox::Yes | QMessageBox::No);
msgBox.setDefaultButton(QMessageBox::Yes);