Use plaintext for Windows notifications
This commit is contained in:
parent
3dcbac8875
commit
8d3e463fa6
@ -5,6 +5,8 @@
|
|||||||
#include "notifications/Manager.h"
|
#include "notifications/Manager.h"
|
||||||
#include "wintoastlib.h"
|
#include "wintoastlib.h"
|
||||||
|
|
||||||
|
#include <QTextDocumentFragment>
|
||||||
|
|
||||||
#include "Cache.h"
|
#include "Cache.h"
|
||||||
#include "EventAccessors.h"
|
#include "EventAccessors.h"
|
||||||
#include "MatrixClient.h"
|
#include "MatrixClient.h"
|
||||||
@ -54,7 +56,7 @@ NotificationsManager::postNotification(const mtx::responses::Notification ¬if
|
|||||||
cache::displayName(QString::fromStdString(notification.room_id),
|
cache::displayName(QString::fromStdString(notification.room_id),
|
||||||
QString::fromStdString(mtx::accessors::sender(notification.event)));
|
QString::fromStdString(mtx::accessors::sender(notification.event)));
|
||||||
const auto text = utils::event_body(notification.event);
|
const auto text = utils::event_body(notification.event);
|
||||||
const auto formattedText = cmark_markdown_to_html(text.toStdString().c_str(), text.length(), CMARK_OPT_UNSAFE);
|
const auto formattedText = QTextDocumentFragment::fromHtml(utils::markdownToHtml(text)).toPlainText();
|
||||||
|
|
||||||
if (!isInitialized)
|
if (!isInitialized)
|
||||||
init();
|
init();
|
||||||
|
Loading…
Reference in New Issue
Block a user