mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-24 00:14:06 +00:00
Merge pull request #942 from xiaoyifang/fix/website-encoding
fix: website encoding problem
This commit is contained in:
commit
23bc1422e9
|
@ -92,12 +92,7 @@ void IframeSchemeHandler::requestStarted(QWebEngineUrlRequestJob *requestJob)
|
|||
|
||||
buffer->setData(articleString.toUtf8());
|
||||
|
||||
//"text/html;charset=utf-8" will be treated as text/plain in Linux .
|
||||
#if defined( Q_OS_WIN32 ) || defined( Q_OS_MAC )
|
||||
requestJob->reply( contentType, buffer );
|
||||
#else
|
||||
requestJob->reply( "text/html", buffer );
|
||||
#endif
|
||||
requestJob->reply( "text/html; charset=utf-8", buffer );
|
||||
};
|
||||
connect( reply, &QNetworkReply::finished, requestJob, finishAction );
|
||||
|
||||
|
|
Loading…
Reference in a new issue