[Patch] KListWidgetSearchLine sorts QListWidget even if sorting is disabled

Nicolas Ternisien nicolas.ternisien at gmail.com
Fri Apr 11 14:07:59 BST 2008


I've made some checks in KDE source code, and the 5 or 6 source files
which uses a KListWidgetSearchLine never uses the setHidden() and
isHidden() methods of QListWidget (even Kopete ;-), so I will commit
this patch if nobody has a problem with it.

Nicolas

On Thu, Apr 10, 2008 at 10:30 PM, Nicolas Ternisien
<nicolas.ternisien at gmail.com> wrote:
> Yes, this is right, but if this is the behavior of
>  KTreeWidgetSearchLine, it should be strange this would be not the same
>  in the KListWidgetSearchLine. I could contact any KDE project that
>  uses a KListWidgetSearchLine after commiting this patch about this
>  behavior.
>
>  If we consider KListWidgetSearchLine as a base class of the KDE API,
>  its behavior will define typical use of QListWidget and
>  KListWidgetSearchLine in other source code, and more particularly the
>  setHidden() and isHidden() use cases.
>
>
>
>  On Thu, Apr 10, 2008 at 8:59 PM, Olivier Goffart <ogoffart at kde.org> wrote:
>  > Le jeudi 10 avril 2008, Nicolas Ternisien a écrit :
>  >
>  > > And now, why not attaching the patch ? ;-)
>  >  >
>  >  > On Thu, Apr 10, 2008 at 2:40 PM, Nicolas Ternisien
>  >  >
>  >  > <nicolas.ternisien at gmail.com> wrote:
>  >  > > In fact, there is an other problem in this class, that does not rely
>  >  > >  on QListWidgetItem::setHidden() and QListWidgetItem::isHidden(), and
>  >  > >  which changes list ordering when a filter is setted and removed.
>  >  > >
>  >  > >  This new patch uses now this feature, and KListWidgetSearchLine has
>  >  > >  now the same behavior than KTreeWidgetSearchLine.
>  >  > >
>  >
>  >
>  >  The problem would be with application like kopete that would use setHidden to
>  >  hide offline contact.  You would loose that information.
>  >  (I think :-))
>  >
>




More information about the kde-core-devel mailing list