#include <QRegularExpression>
-#include <config-baloo.h>
-#ifdef HAVE_BALOO
+#include "config-dolphin.h"
+#if HAVE_BALOO
#include <Baloo/Query>
#endif
namespace {
-#ifdef HAVE_BALOO
+#if HAVE_BALOO
/** Checks if a given term in the Baloo::Query::searchString() is a special search term
* @return: the specific search token of the term, or an empty QString() if none is found
*/
void DolphinQuery::parseBalooQuery()
{
-#ifdef HAVE_BALOO
+#if HAVE_BALOO
const Baloo::Query query = Baloo::Query::fromSearchUrl(m_searchUrl);
m_includeFolder = query.includeFolder();
QString fileName;
const QStringList subTerms = splitOutsideQuotes(query.searchString());
- foreach (const QString& subTerm, subTerms) {
+ for (const QString& subTerm : subTerms) {
const QString token = searchTermToken(subTerm);
const QString value = stripQuotes(subTerm.mid(token.length()));