mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-24 04:24:09 +00:00
Make saving complete article work in Qt 5.15
The old code works correctly in Qt 4.8.7. But in Qt 5.15.5 selectedFilter is never equal to either element of filters. So HTML Only is saved no matter which option the user selects.
This commit is contained in:
parent
1064880450
commit
8f41079069
|
@ -3585,7 +3585,8 @@ void MainWindow::on_saveArticle_triggered()
|
||||||
filters.join( ";;" ),
|
filters.join( ";;" ),
|
||||||
&selectedFilter, options );
|
&selectedFilter, options );
|
||||||
|
|
||||||
bool complete = ( selectedFilter == filters[ 0 ] );
|
// The " (*.html)" part of filters[i] is absent from selectedFilter in Qt 5.
|
||||||
|
bool const complete = filters.at( 0 ).startsWith( selectedFilter );
|
||||||
|
|
||||||
if ( !fileName.isEmpty() )
|
if ( !fileName.isEmpty() )
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue