mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-27 15:24:05 +00:00
Merge pull request #1599 from xiaoyifang/fix/ctrl-f-scanpopup
fix: Ctrl+F does not work in scanpopup dialog
This commit is contained in:
commit
10104d77aa
|
@ -1942,7 +1942,7 @@ void ArticleView::openSearch()
|
|||
searchPanel->lineEdit->selectAll();
|
||||
|
||||
// Clear any current selection
|
||||
if ( !webview->selectedText().isEmpty() ) {
|
||||
if ( webview->hasSelection() ) {
|
||||
webview->findText( "" );
|
||||
}
|
||||
|
||||
|
|
|
@ -113,6 +113,7 @@ ScanPopup::ScanPopup( QWidget * parent,
|
|||
connect( definition, &ArticleView::typingEvent, this, &ScanPopup::typingEvent );
|
||||
|
||||
openSearchAction.setShortcut( QKeySequence( "Ctrl+F" ) );
|
||||
addAction( &openSearchAction );
|
||||
connect( &openSearchAction, &QAction::triggered, definition, &ArticleView::openSearch );
|
||||
|
||||
wordListDefaultFont = ui.translateBox->completerWidget()->font();
|
||||
|
|
Loading…
Reference in a new issue