Showing the changes to interface/src/scripting/GlobalServicesScriptingInterface.cpp (1 of 2 files). Show all
Unified · Split
| @@ -104,10 +104,12 @@ void GlobalServicesScriptingInterface::loggedOut() { · 103 unmodified lines | |||
| 104 | emit GlobalServicesScriptingInterface::disconnected(QString("logout")); | 104 | emit GlobalServicesScriptingInterface::disconnected(QString("logout")); |
| 105 | } | 105 | } |
| 106 | 106 | ||
| 107 | #ifdef HAVE_QXMPP | ||
| 107 | void GlobalServicesScriptingInterface::messageReceived(const QXmppMessage& message) { | 108 | void GlobalServicesScriptingInterface::messageReceived(const QXmppMessage& message) { |
| 108 | if (message.type() != QXmppMessage::GroupChat) { | 109 | if (message.type() != QXmppMessage::GroupChat) { |
| 109 | return; | 110 | return; |
| 110 | } | 111 | } |
| 111 | const QXmppMucRoom* publicChatRoom = XmppClient::getInstance().getPublicChatRoom(); | 112 | const QXmppMucRoom* publicChatRoom = XmppClient::getInstance().getPublicChatRoom(); |
| 112 | emit GlobalServicesScriptingInterface::incomingMessage(message.from().right(message.from().count() - 1 - publicChatRoom->jid().count()), message.body()); | 113 | emit GlobalServicesScriptingInterface::incomingMessage(message.from().right(message.from().count() - 1 - publicChatRoom->jid().count()), message.body()); |
| 113 | } | 114 | } |
| 115 | #endif // HAVE_QXMPP | ||