[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    KDE/kdevelop/lib/util
From:       Harald Fernengel <harry () kdevelop ! org>
Date:       2005-11-01 15:17:10
Message-ID: 1130858230.688517.16571.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 476585 by harald:

okay, startWith is faster but boring. Go back to contains


 M  +2 -2      kfiltermodel.cpp  


--- trunk/KDE/kdevelop/lib/util/kfiltermodel.cpp #476584:476585
@@ -207,7 +207,7 @@
 }
 
 /**
- * Matches an index in the model. The default implementation checks whether the item starts with
+ * Matches an index in the model. The default implementation checks whether the item contains
  * the string set by setFilter().
  *
  * @param index The index to match
@@ -217,7 +217,7 @@
 {
     Q_ASSERT(index.isValid());
 
-    return d->sourceModel->data(index).toString().startsWith(d->filterStr);
+    return d->sourceModel->data(index).toString().contains(d->filterStr);
 }
 
 QString KFilterModel::filter() const
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic