[KCM GridDelegate] Use non-attached ToolTip
Needs RevisionPublic

Authored by broulik on Fri, Nov 22, 12:42 PM.

Details

Reviewers
mart
davidedmundson
Group Reviewers
Plasma
Summary

Then it can just follow the style's delay and timeout.

Test Plan
  • Hovered grid delegate which had a tooltip, showed after a short delay, stated for like 10 seconds
  • Hovered grid delegate without one, didn't get any tooltip

Diff Detail

Repository
R296 KDeclarative
Lint
Lint Skipped
Unit
Unit Tests Skipped
broulik created this revision.Fri, Nov 22, 12:42 PM
Restricted Application added a project: Frameworks. · View Herald TranscriptFri, Nov 22, 12:42 PM
Restricted Application added a subscriber: kde-frameworks-devel. · View Herald Transcript
broulik requested review of this revision.Fri, Nov 22, 12:42 PM

This works for you? I still see that the tooltip for KCM grid delegates disappears almost immediately with this patch.

davidedmundson requested changes to this revision.Mon, Dec 2, 11:17 AM
davidedmundson added a subscriber: davidedmundson.

The attached version is a light QObject that calls a single tooltip.
The non-attached version contains /the entire tooltip instance/

Which on every delegate is too much of a problem.

You're right that we have to duplicate the delay logic to follow the theme, but at least in KDeclarative we're only doing that in one place and hiding it from the user code. If that needs to use C++ code, (or maybe kirigami theme should export this?) that might work

This revision now requires changes to proceed.Mon, Dec 2, 11:17 AM

Kirigami has a toolTipDelay in Units. The other bit is hardcoded to some heuristic:
https://cgit.kde.org/qqc2-desktop-style.git/tree/org.kde.desktop/ToolTip.qml#n48