D8773: Improve discoverability of drag-and-drop of toolbar actions

David Faure noreply at phabricator.kde.org
Sun Nov 12 18:18:07 UTC 2017


dfaure added a comment.


  I like the idea.
  
  I'm just not sure about the exact wording of the action, but I'll let the VDG decide on that.

INLINE COMMENTS

> apol wrote in ktoolbar.cpp:410
> Isn't it better to set a parent like for the other ona than use the QScopedPointer?

I'm also surprised by the inconsistency, and I bet future readers will be too.

As to whether it should all be ported to QScopedPointer, I'm not convinced.

Technically, I would bet that deletion by the parent is faster than deleting each children individually with e.g. QScopedPointer (because that will have to remove from the list of children in the parent, so it means N linear searches).

> ktoolbar.cpp:412
> +        contextEditableAction->setChecked(q->toolBarsEditable());
> +        connect(contextEditableAction.data(), &QAction::toggled, q, [this](bool toggled) {
> +            q->setToolBarsEditable(toggled);

Is this a case where &KToolBar::setToolBarsEditable would work, without the need for a lambda?

REPOSITORY
  R263 KXmlGui

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

To: elvisangelaccio, #frameworks, #vdg, dfaure
Cc: apol
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20171112/262d75da/attachment.html>


More information about the Kde-frameworks-devel mailing list