D28879: Fix WidgetExplorer "get new widgets" always a new window opens instead of taking the focus to the already opened one

David Edmundson noreply at phabricator.kde.org
Wed Apr 29 17:23:43 BST 2020


davidedmundson added inline comments.

INLINE COMMENTS

> WidgetExplorer.qml:66
>      Component.onCompleted: {
>          if (!root.widgetExplorer) {
> +            if (!root.widgetExplorerAssistant) {

This existing code is horrible.

It's a very bad idea to reference objects outside our scope. It results in unportable, unreusable code. In Qt6 this will be an error.

Case in point AppletAlternatives imports this Item but now root is a different object and neither this property or widgetExplorerAssistant exist.

I want us to be tidying that up rather than expanding on it.

REPOSITORY
  R119 Plasma Desktop

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

To: sunny, #plasma
Cc: davidedmundson, plasma-devel, Orage, LeGast00n, The-Feren-OS-Dev, cblack, jraleigh, zachus, fbampaloukas, ragreen, ZrenBot, ngraham, himcesjf, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, ahiemstra, mart
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20200429/9f6cd589/attachment-0001.html>


More information about the Plasma-devel mailing list