[plasmashell] [Bug 518024] Kirigami.Icon in custom compactRepresentation absorbs mouse events, blocking parent MouseArea clicks

"thomas moore" <[email protected]>
Newsgroups gmane.comp.kde.devel.bugs
Message-ID <[email protected]/>
https://bugs.kde.org/show_bug.cgi?id=518024

--- Comment #2 from thomas moore <[email protected]> ---
Following up on my own report: this was my bug, not Kirigami's, and your
reproducer is correct.

Kirigami.Icon is a plain QQuickItem that sets no accepted mouse buttons and no
hover handling, so it cannot absorb mouse events. The premise of my report was
wrong.

The real fault was the hit area in my own compactRepresentation. What fixed it
was pinning the applet size hints so the panel hands over a slot matching the
content, and using a single TapHandler on the root item rather than a
MouseArea:

    Layout.fillWidth: false
    Layout.minimumWidth: compactLayout.implicitWidth
    Layout.preferredWidth: compactLayout.implicitWidth
    Layout.maximumWidth: compactLayout.implicitWidth

With that in place, the nested MouseArea workaround is unnecessary.

-- 
You are receiving this mail because:
You are watching all bug changes.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.