git rid of gratuitous query term

(obsoleted quite some time ago)
This commit is contained in:
Aaron Seigo 2011-10-03 19:54:21 +02:00
parent 685bebaed9
commit 199e98ce5b
2 changed files with 6 additions and 17 deletions

View File

@ -367,10 +367,8 @@ bool RunnerContext::isValid() const
return (d->q != &(d->s_dummyContext));
}
bool RunnerContext::addMatches(const QString &term, const QList<QueryMatch> &matches)
bool RunnerContext::addMatches(const QList<QueryMatch> &matches)
{
Q_UNUSED(term)
if (matches.isEmpty() || !isValid()) {
//Bail out if the query is empty or the qptr is dirty
return false;
@ -402,10 +400,8 @@ bool RunnerContext::addMatches(const QString &term, const QList<QueryMatch> &mat
return true;
}
bool RunnerContext::addMatch(const QString &term, const QueryMatch &match)
bool RunnerContext::addMatch(const QueryMatch &match)
{
Q_UNUSED(term)
if (!isValid()) {
// Bail out if the qptr is dirty
return false;

View File

@ -133,27 +133,20 @@ class PLASMA_EXPORT RunnerContext : public QObject
/**
* Appends lists of matches to the list of matches.
*
* This method is thread safe and causes the matchesChanged() signal to be emitted.
*
* @param matches the matches to add
* @return true if matches were added, false if matches were e.g. outdated
*/
// trueg: what do we need the term for? It is stored in the context anyway! Plus: matches() does not have a term parameter!
// plus: it is Q_UNUSED
bool addMatches(const QString &term, const QList<QueryMatch> &matches);
bool addMatches(const QList<QueryMatch> &matches);
/**
* Appends a match to the existing list of matches.
*
* If you are going to be adding multiple matches, use addMatches instead.
* If you are going to be adding multiple matches, use @see addMatches instead.
*
* @param term the search term that this match was generated for.
* @param match the match to add
*
* @return true if the match was added, false otherwise.
*/
// trueg: what do we need the term for? It is stored in the context anyway! Plus: matches() does not have a term parameter!
// plus: it is Q_UNUSED
bool addMatch(const QString &term, const QueryMatch &match);
bool addMatch(const QueryMatch &match);
/**
* Removes a match from the existing list of matches.