┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/search/dolphinsearchbox.cpp
diff options
context:
space:
mode:
authorPeter Penz <[email protected]>2010-11-24 15:51:58 +0000
committerPeter Penz <[email protected]>2010-11-24 15:51:58 +0000
commit32764c9696bcdbaf8136e47376ec6fe7a1c8ce05 (patch)
tree9ae3000ce39a5f52ba0b6ba947bfd59a8457d92c /src/search/dolphinsearchbox.cpp
parentcd1ced91584105a53428bc1a23fb9c95cccdd6cb (diff)
Allow to search for filenames + textcontent also for non-local files.
svn path=/trunk/KDE/kdebase/apps/; revision=1200303
Diffstat (limited to 'src/search/dolphinsearchbox.cpp')
-rw-r--r--src/search/dolphinsearchbox.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/search/dolphinsearchbox.cpp b/src/search/dolphinsearchbox.cpp
index 23d0c658a..7c2d15264 100644
--- a/src/search/dolphinsearchbox.cpp
+++ b/src/search/dolphinsearchbox.cpp
@@ -97,18 +97,22 @@ KUrl DolphinSearchBox::urlForSearching() const
if (m_nepomukActivated && isSearchPathIndexed()) {
url = nepomukUrlForSearching();
} else {
- url = m_searchPath;
url.setProtocol("filenamesearch");
url.addQueryItem("search", m_searchInput->text());
if (m_contentButton->isChecked()) {
url.addQueryItem("checkContent", "yes");
}
+
+ QString encodedUrl;
if (m_everywhereButton->isChecked()) {
// It is very unlikely, that the majority of Dolphins target users
// mean "the whole harddisk" instead of "my home folder" when
// selecting the "Everywhere" button.
- url.setPath(QDir::homePath());
+ encodedUrl = QDir::homePath();
+ } else {
+ encodedUrl = m_searchPath.url();
}
+ url.addQueryItem("url", encodedUrl);
}
return url;