systray: show a small animation on the icons when activated
AcceptedPublic

Authored by apol on Mar 21 2019, 6:23 PM.

Details

Reviewers
ngraham
Group Reviewers
Plasma
Summary

Both for plasmoids and SNI

Test Plan

Now there's some kind of feedback when pressing the icons

Diff Detail

Repository
R120 Plasma Workspace
Branch
arcpatch-D19947_1
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 14576
Build 14594: arc lint + arc unit
apol created this revision.Mar 21 2019, 6:23 PM
Restricted Application added a project: Plasma. · View Herald TranscriptMar 21 2019, 6:23 PM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
apol requested review of this revision.Mar 21 2019, 6:23 PM

How do I trigger this? I'm not seeing anything happen when I click on a System Tray icon with this patch.

apol added a comment.Mar 25 2019, 11:29 AM

Use akregator for example, or the virtual keyboard enable/disable thing.

It's subtle but I quite like it.
It feels a bit inconsistent given it affects plasmoids on keyshortcut, but not on click.

applets/systemtray/package/contents/ui/items/PlasmoidItem.qml
43

Do we want it here?

apol added a comment.Mar 25 2019, 2:00 PM

It's subtle but I quite like it.

\o/

It feels a bit inconsistent given it affects plasmoids on keyshortcut, but not on click.

Agreed, but here the bug is that on click it doesn't happen I'd say, and we'll have to go over all plasmoids I'm afraid, because they all implement a MouseArea to deal with triggering.
I was looking into introducing context menu on pressAndHold and there's a similar problem.

apol updated this revision to Diff 54778.Mar 25 2019, 3:37 PM

Show a context menu onPressAndHold

See 20042

apol updated this revision to Diff 54779.Mar 25 2019, 3:38 PM

Unrelated change. Bad phabricator. *hits phab's nose with a newspaper*

In D19947#438052, @apol wrote:

It's subtle but I quite like it.

\o/

It feels a bit inconsistent given it affects plasmoids on keyshortcut, but not on click.

Agreed, but here the bug is that on click it doesn't happen I'd say, and we'll have to go over all plasmoids I'm afraid, because they all implement a MouseArea to deal with triggering.
I was looking into introducing context menu on pressAndHold and there's a similar problem.

Can we spy mouse click (in C++ side if needed) before it's propagated to applet?

apol added a comment.Mar 25 2019, 11:38 PM

Can we spy mouse click (in C++ side if needed) before it's propagated to applet?

I tried to do it and failed, it's not that I enjoy complex solutions...

apol updated this revision to Diff 54903.Mar 26 2019, 11:43 PM

Also animate when expanding, as suggested by @davidedmundson

apol added a comment.Jul 29 2019, 2:11 PM

Ping? I still miss this...

Code wise, it's fine.

Personally I like it. If VDG approve, go for it.

apol updated this revision to Diff 62799.Jul 30 2019, 3:31 PM
apol added a subscriber: broulik.

Make the animation shrink instead of expand as suggested by @broulik

filipf added a subscriber: filipf.Jul 30 2019, 3:38 PM
ngraham accepted this revision.Aug 1 2019, 7:40 PM

LGTM.

This revision is now accepted and ready to land.Aug 1 2019, 7:40 PM
filipf added a comment.Aug 1 2019, 8:00 PM

The effect doesn't always work for me.