mirror of
https://github.com/RetroShare/RetroShare.git
synced 2026-09-12 19:50:17 +05:00
fix qt6 compile
This commit is contained in:
parent
177141a042
commit
460afb7824
@ -361,7 +361,13 @@ QString MimeTextEdit::toHtml(const QByteArray &encoding) const
|
||||
if (encoding.isEmpty()) {
|
||||
html = QTextEdit::toHtml();
|
||||
} else {
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
|
||||
// Qt 6: toHtml() takes no arguments
|
||||
html = doc->toHtml();
|
||||
#else
|
||||
// Qt 5: toHtml() accepts encoding parameter
|
||||
html = doc->toHtml(encoding);
|
||||
#endif
|
||||
}
|
||||
if (doc) {
|
||||
doc->setDefaultStyleSheet(oldSheet);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user