Skip to content

Commit 24722b8

Browse files
authored
Merge pull request #1409 from Vekhir/fix-setcontent-warning
refactor: use different setContent overload
2 parents 34e69c7 + 64c9e35 commit 24722b8

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

src/gui/UBBackgroundManager.cpp

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -300,8 +300,12 @@ QPixmap UBBackgroundManager::createButtonPixmap(const QDomDocument& bgDoc, bool
300300
}
301301

302302
QDomDocument doc;
303-
304-
if (!doc.setContent(&templateFile, true))
303+
#if (QT_VERSION >= QT_VERSION_CHECK(6, 5, 0))
304+
auto result = doc.setContent(&templateFile, QDomDocument::ParseOption::UseNamespaceProcessing);
305+
#else
306+
auto result = doc.setContent(&templateFile, true)
307+
#endif
308+
if (!result)
305309
{
306310
qWarning() << "Cannot load template file" << templateFile.fileName();
307311
return {};

0 commit comments

Comments
 (0)