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

List:       kde-core-devel
Subject:    Re: Strange KFileDialog ctor
From:       "John Tapsell" <johnflux () gmail ! com>
Date:       2008-09-18 17:24:40
Message-ID: 43d8ce650809181024r5863bbex61ae0b7f51a866e1 () mail ! gmail ! com
[Download RAW message or body]

If KFileDialog just splits the string, it would be better to replace
the ctor with your version.  Although I guess it's too late for for
backwards compatibility.

2008/9/18 Christian Ehrlicher <Ch.Ehrlicher@gmx.de>:
> Hi,
>
> the KFileDialog currently wants a QString as filter. This leads to
> constructs like this:
>
>    QString filter = mimeTypes.join (" ");
>    KFileDialog fd (startURL, filter, this);
>
> inside the ctor setFilter() is used which then has to determine that it's a
> joined-mimetype string and has to split it up.
>
> Therefore I suggest a new ctor:
>
>    KFileDialog( const KUrl& startDir, const QStringList& mimefilter,
>                 QWidget *parent, QWidget* widget = 0 );
>
> to avoid the useless join/split
>
>
> Comments?
> Christian
>
[prev in list] [next in list] [prev in thread] [next in thread] 

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