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

List:       kde-core-devel
Subject:    Re: Handling of default button in KDialog broken
From:       André_Wöbbeking <Woebbeking () kde ! org>
Date:       2008-07-04 14:46:15
Message-ID: 200807041646.15757.Woebbeking () kde ! org
[Download RAW message or body]

On Friday 04 July 2008, Lubos Lunak wrote:
>  Hello,
>
>  could somebody please review the attached patch? It appears that
> KDialog has a bug with (not) setting the default button properly,

I just had a bug report about that in Cervisia.

> which has been there since about forever.

No, it worked in KDE3.

>  The KDialog code has some function called setButtonFocus(), which
> however seems to be just a thin wrapper used for confusing things.
> Making a button default does not set focus to it, making it useless
> in many cases. It appears that e.g. KMessageBox works this around by
> explicitly later setting focus to the button (which however actually
> resets the button from being the default). I suggest the attached
> patch, which will normally make default buttons focused by default
> (and consistent with QMessageBox::setDefaultButton()).
>
>  Does somebody see a problem with it?

It depends on the dialog. If you've a lineedit in the dialog it should 
have focus and not a button.

IMO it's a Qt regression to give focus to a button which is not the 
default one.


Cheers,
André

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

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