From 717a665c4e6c0c9455ed46163216e7525f36ff87 Mon Sep 17 00:00:00 2001 From: Peter Penz Date: Sun, 10 Oct 2010 16:13:24 +0000 Subject: Automatically start the searching if the user did not change the search-text for at least a second. svn path=/trunk/KDE/kdebase/apps/; revision=1184510 --- src/dolphinviewcontainer.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/dolphinviewcontainer.cpp') diff --git a/src/dolphinviewcontainer.cpp b/src/dolphinviewcontainer.cpp index 45490e363..aa20409ba 100644 --- a/src/dolphinviewcontainer.cpp +++ b/src/dolphinviewcontainer.cpp @@ -102,6 +102,7 @@ DolphinViewContainer::DolphinViewContainer(const KUrl& url, QWidget* parent) : m_searchBox->hide(); connect(m_searchBox, SIGNAL(closeRequest()), this, SLOT(closeSearchBox())); connect(m_searchBox, SIGNAL(search(QString)), this, SLOT(startSearching(QString))); + connect(m_searchBox, SIGNAL(returnPressed(QString)), this, SLOT(requestFocus())); m_dirLister = new DolphinDirLister(); m_dirLister->setAutoUpdate(true); @@ -431,7 +432,7 @@ void DolphinViewContainer::slotUrlNavigatorLocationChanged(const KUrl& url) } m_view->setUrl(url); - if (isActive()) { + if (isActive() && !isSearchUrl(url)) { // When an URL has been entered, the view should get the focus. // The focus must be requested asynchronously, as changing the URL might create // a new view widget. -- cgit v1.3