KMenu title is navigable with the keyboard
Albert Astals Cid
aacid at kde.org
Thu Nov 19 22:49:41 GMT 2009
A Dijous, 19 de novembre de 2009, Thomas Lübking va escriure:
> Am Thursday 19 November 2009 schrieb Albert Astals Cid:
> > Any more suggestion or do i go with my patch?
>
> Not aside "fixing" Qt (see my reply to Ossi) - but we should nevertheless
> start efforts on changing and aligning the KMenu titles with potential
> QMenu ones (i.e. fix styles and use similar painting code) so this could
> be dropped for Qt 4.6.x
> regarding the patch:
>
> - maybe name it "kmenu_title" (it's an action and obviously "this" ;-)
Ok
>
> - you can probably spare the QWidgetAction cast (as you check for the
> object name anyway)
I'd say the cast is faster?
>
> - QList is likely faster (the Set has a fix cost part, we don't expect too
> many elements and logically won't get dupes anyway)
> - also it /should/ be sufficient to just save and check the first title
> action (as it would be encountered first anyway - yesno? do we expect to
> loose it on up/down keys?)
Right, storing the first should be enough
>
> - if the recursive titleaction is reached again
> "visitedTitles.contains(action)" you probably want to
> parent->setActiveAction(0);
> as the point is to avoid kbd selection
Seems sensible.
I've just commited the patch.
>
> Thomas
>
More information about the kde-core-devel
mailing list