Skip to content

Commit

Permalink
ctrl-k should not perform a new search in locator
Browse files Browse the repository at this point in the history
  • Loading branch information
uclaros authored and nyalldawson committed Apr 4, 2020
1 parent 596dbdb commit 9d09998
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/gui/locator/qgslocatorwidget.cpp
Expand Up @@ -144,18 +144,19 @@ void QgsLocatorWidget::setMapCanvas( QgsMapCanvas *canvas )

void QgsLocatorWidget::search( const QString &string )
{
window()->activateWindow(); // window must also be active - otherwise floating docks can steal keystrokes
if ( string.isEmpty() )
{
mLineEdit->setFocus();
mLineEdit->selectAll();
}
else
{
scheduleDelayedPopup();
mLineEdit->setFocus();
mLineEdit->setText( string );
performSearch();
}
window()->activateWindow(); // window must also be active - otherwise floating docks can steal keystrokes
scheduleDelayedPopup();
mLineEdit->setFocus();
performSearch();
}

void QgsLocatorWidget::invalidateResults()
Expand Down

0 comments on commit 9d09998

Please sign in to comment.