D20035: Set autofocus to child KPluginSelector on UI load

Jayesh Bhoot noreply at phabricator.kde.org
Tue Mar 26 14:20:00 GMT 2019


jayeshbhoot added a comment.


  This is my first patch. So I will need someone to land it.

INLINE COMMENTS

> ngraham wrote in kcm.cpp:41
> Don't need to include `QTimer` anymore.

Fixed

> ngraham wrote in kcm.cpp:89
> I'm not thrilled about this workaround. Any chance you can figure out why `m_pluginSelector->setFocus()` doesn't work all on its own?
> 
> Also, don't use first-person comments in code.

My guess is parent class KCModule somehow messes up the setFocus() call in constructor. I can't be sure though; not enough knowledge on the codebase yet. But only that seems to explain the focus shifting to Defaults button in the module.
Now, the focus is set in the overridden load() method.

My bad on the first-person comment. Fixed.

REPOSITORY
  R119 Plasma Desktop

BRANCH
  fix/focus-searchbar-in-plasmasearch-kcm (branched from master)

REVISION DETAIL
  https://phabricator.kde.org/D20035

To: jayeshbhoot, #plasma, ngraham
Cc: ngraham, plasma-devel, jraleigh, GB_2, ragreen, Pitel, ZrenBot, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, mart
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20190326/b25837a9/attachment.html>


More information about the Plasma-devel mailing list