mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-27 15:24:05 +00:00
fix: disable anchor default behavior (#1857)
* fix: prevent anchor link default behavior (in mdx dictionary)
This commit is contained in:
parent
047f725858
commit
e749a6077f
|
@ -920,8 +920,8 @@ void MdxDictionary::replaceLinks( QString & id, QString & article )
|
|||
QRegularExpressionMatch match = RX::Mdx::audioRe.match( newLink );
|
||||
if ( match.hasMatch() ) {
|
||||
// sounds and audio link script
|
||||
QString newTxt =
|
||||
match.captured( 1 ) + match.captured( 2 ) + "gdau://" + id + "/" + match.captured( 3 ) + match.captured( 2 );
|
||||
QString newTxt = match.captured( 1 ) + match.captured( 2 ) + "gdau://" + id + "/" + match.captured( 3 )
|
||||
+ match.captured( 2 ) + R"( onclick="return false;" )";
|
||||
newLink =
|
||||
QString::fromUtf8(
|
||||
addAudioLink( "\"gdau://" + getId() + "/" + match.captured( 3 ).toUtf8().data() + "\"", getId() ).c_str() )
|
||||
|
|
Loading…
Reference in a new issue