mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-23 16:04:06 +00:00
clean: deprecated QVariant::type
This commit is contained in:
parent
997f24d62f
commit
90d55d7392
|
@ -1389,7 +1389,7 @@ void ArticleView::playSound()
|
|||
return link;})(); )";
|
||||
|
||||
webview->page()->runJavaScript( variable, [ this ]( const QVariant & result ) {
|
||||
if ( result.type() == QVariant::String ) {
|
||||
if ( result.typeId() == qMetaTypeId< QString >() ) {
|
||||
QString soundScript = result.toString();
|
||||
if ( !soundScript.isEmpty() )
|
||||
openLink( QUrl::fromEncoded( soundScript.toUtf8() ), webview->url() );
|
||||
|
|
Loading…
Reference in a new issue