fix: website dictionary display incorrect text on the page.

fix #340
This commit is contained in:
Xiao YiFang 2023-02-09 23:00:32 +08:00
parent 85429d79a5
commit 2baffb0628

View file

@ -98,7 +98,12 @@ void IframeSchemeHandler::requestStarted(QWebEngineUrlRequestJob *requestJob)
else else
buffer->setData(articleString.toUtf8()); buffer->setData(articleString.toUtf8());
#ifdef Q_OS_WIN32
requestJob->reply(contentTypeV.toByteArray() , buffer );
#else
//use "text/html;charset=utf-8" will make the response html text rendered on the webpage?
requestJob->reply(contentType , buffer ); requestJob->reply(contentType , buffer );
#endif
}; };
connect( reply, &QNetworkReply::finished, requestJob, finishAction ); connect( reply, &QNetworkReply::finished, requestJob, finishAction );