tooltipmanager: use qstyle wakeup delay instead of hardcoding
ClosedPublic

Authored by sitter on Jan 17 2020, 5:51 PM.

Details

Summary

aids in making kinfocenter and systemsettings behave with the
same delay. plus not hardcoding things is always cool

Test Plan

builds, tooltip shows up, qdebugging says timeout is now 700

Diff Detail

Repository
R102 KInfoCenter
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
sitter created this revision.Jan 17 2020, 5:51 PM
Restricted Application added a project: Plasma. · View Herald TranscriptJan 17 2020, 5:51 PM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
sitter requested review of this revision.Jan 17 2020, 5:51 PM

The code if memory serves originates from Dolphin, it was copied from there into System Settings (which was done by me - we weren't sure about API stability at the time for upstreaming to kdelibs as it was at the time), and then must have been copied again from there into KInfoCenter.

ugh :(

Thanks for context though.

Yeah, it might be nice to extract this into a framework that can bee used by all three apps so it can't diverge this way again.

mart accepted this revision.Jan 22 2020, 10:08 AM
mart added a subscriber: mart.

couldn't this just use the standard delay set by the style?

QStyle::SH_ToolTip_WakeUpDelay

This revision is now accepted and ready to land.Jan 22 2020, 10:08 AM
mart requested changes to this revision.Jan 22 2020, 10:08 AM
This revision now requires changes to proceed.Jan 22 2020, 10:08 AM

I suppose. That is not what systemsettings does though.

sitter updated this revision to Diff 74131.Jan 22 2020, 3:38 PM

get delay from qstyle

sitter retitled this revision from sync tooltip delay with systemsettings to tooltipmanager: use qstyle wakeup delay instead of hardcoding.Jan 22 2020, 3:38 PM
sitter edited the summary of this revision. (Show Details)
sitter edited the test plan for this revision. (Show Details)
mart accepted this revision.Jan 22 2020, 5:05 PM
This revision is now accepted and ready to land.Jan 22 2020, 5:05 PM
This revision was automatically updated to reflect the committed changes.