Commit 83a7ed03 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Port QLinkedList to QVector, we don't need to insert/replace etc here so

QVector is enough
parent d23b8936
......@@ -54,7 +54,7 @@ public:
bool keepParentsVisible;
QString search;
int queuedSearches;
QLinkedList<int> searchColumns;
QVector<int> searchColumns;
};
......@@ -158,7 +158,7 @@ void KViewSearchLine::setKeepParentsVisible(bool v)
d->keepParentsVisible = v;
}
void KViewSearchLine::setSearchColumns(const QLinkedList<int> &columns)
void KViewSearchLine::setSearchColumns(const QVector<int> &columns)
{
d->searchColumns = columns;
}
......@@ -222,7 +222,7 @@ bool KViewSearchLine::itemMatches(const QModelIndex & item, const QString &s) co
int row = item.row();
QModelIndex parent = item.parent();
if(!d->searchColumns.isEmpty()) {
QLinkedList<int>::const_iterator it, end;
QVector<int>::const_iterator it, end;
end = d->searchColumns.constEnd();
for(it = d->searchColumns.constBegin(); it != end; ++it)
{
......
......@@ -20,7 +20,7 @@
#include <klineedit.h>
#include <QAbstractItemView>
#include <QLinkedList>
#include <QVector>
class QAction;
......@@ -83,7 +83,7 @@ public:
*
* @see setSearchColumns
*/
QLinkedList<int> searchColumns() const;
QVector<int> searchColumns() const;
/**
* If this is true (the default) then the parents of matched items will also
......@@ -138,7 +138,7 @@ public Q_SLOTS:
*
* @see searchColumns
*/
void setSearchColumns(const QLinkedList<int> &columns);
void setSearchColumns(const QVector<int> &columns);
/**
* Sets the view that is filtered by this search line.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment