diff --git a/linphone-app/src/components/notifier/Notifier.cpp b/linphone-app/src/components/notifier/Notifier.cpp index 61a291e14..0a726c80b 100644 --- a/linphone-app/src/components/notifier/Notifier.cpp +++ b/linphone-app/src/components/notifier/Notifier.cpp @@ -276,10 +276,10 @@ void Notifier::notifyReceivedMessage (const shared_ptr &m map["message"] = txt; shared_ptr chatRoom(message->getChatRoom()); map["timelineModel"].setValue(CoreManager::getInstance()->getTimelineListModel()->getTimeline(chatRoom, true).get()); - map["peerAddress"] = Utils::coreStringToAppString(chatRoom->getPeerAddress()->asStringUriOnly()); - map["localAddress"] = Utils::coreStringToAppString(chatRoom->getLocalAddress()->asStringUriOnly()); - map["fullPeerAddress"] = Utils::coreStringToAppString(chatRoom->getPeerAddress()->asString()); - map["fullLocalAddress"] = Utils::coreStringToAppString(chatRoom->getLocalAddress()->asString()); + map["peerAddress"] = Utils::coreStringToAppString(message->getFromAddress()->asStringUriOnly()); + map["localAddress"] = Utils::coreStringToAppString(message->getToAddress()->asStringUriOnly()); + map["fullPeerAddress"] = Utils::coreStringToAppString(message->getFromAddress()->asString()); + map["fullLocalAddress"] = Utils::coreStringToAppString(message->getToAddress()->asString()); map["window"].setValue(App::getInstance()->getMainWindow()); CREATE_NOTIFICATION(Notifier::ReceivedMessage, map) } diff --git a/linphone-app/ui/modules/Linphone/Notifications/NotificationReceivedMessage.qml b/linphone-app/ui/modules/Linphone/Notifications/NotificationReceivedMessage.qml index 74a8e4e10..d349dc0c8 100644 --- a/linphone-app/ui/modules/Linphone/Notifications/NotificationReceivedMessage.qml +++ b/linphone-app/ui/modules/Linphone/Notifications/NotificationReceivedMessage.qml @@ -37,9 +37,14 @@ Notification { Contact { Layout.fillWidth: true - - //entry: SipAddressesModel.getSipAddressObserver(notification.fullPeerAddress, notification.fullLocalAddress) - entry:notification.timelineModel.getChatRoomModel() + property ChatRoomModel chatRoomModel : notification.timelineModel.getChatRoomModel() + //entry: notification.fullPeerAddress? SipAddressesModel.getSipAddressObserver(notification.fullPeerAddress, notification.fullLocalAddress): notification.timelineModel.getChatRoomModel() + entry: ({ + sipAddress: SipAddressesModel.getSipAddressObserver(notification.fullPeerAddress, notification.fullLocalAddress), + isOneToOne: chatRoomModel.isOneToOne, + haveEncryption: chatRoomModel.haveEncryption, + securityLevel: chatRoomModel.securityLevel + }) } Rectangle {