Add a button to clear the notification history
ClosedPublic

Authored by Fuchs on Mar 12 2018, 11:58 AM.

Details

Summary

Adds a button in the plasmoid header to clear the history, same as the context menu.
The icon used is the same as clear history in the klipper plasmoid.

BUG: 386068
FIXED-IN: 5.13.0

Test Plan

Please test the alignment on your screen, whilst I made sure to use provided units, due to the indentation of heading I had to use fractions, which might lead to odd results on different resolutions / dpi

Diff Detail

Repository
R120 Plasma Workspace
Branch
fuchs-notification-clearhistory (branched from master)
Lint
No Linters Available
Unit
No Unit Test Coverage
Fuchs created this revision.Mar 12 2018, 11:58 AM
Restricted Application added a project: Plasma. · View Herald TranscriptMar 12 2018, 11:58 AM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
Fuchs requested review of this revision.Mar 12 2018, 11:58 AM

Screenshot:

Fuchs retitled this revision from Add a button to clear the notification history BUG: 386068 FIXED-IN: 5.13.0 to Add a button to clear the notification historyBUG: 386068FIXED-IN: 5.13.0.Mar 12 2018, 11:59 AM
Fuchs edited the test plan for this revision. (Show Details)
Fuchs retitled this revision from Add a button to clear the notification historyBUG: 386068FIXED-IN: 5.13.0 to Add a button to clear the notification history.
Fuchs edited the summary of this revision. (Show Details)
Fuchs updated this revision to Diff 29319.Mar 12 2018, 12:02 PM
  • Capitalized History in the tooltip label as per discussion
Fuchs updated this revision to Diff 29320.Mar 12 2018, 12:04 PM
  • Use Math.round() as per discussion
Fuchs updated this revision to Diff 29321.Mar 12 2018, 12:08 PM
  • Change the layout import according to kbroulik
Fuchs updated this revision to Diff 29325.Mar 12 2018, 12:56 PM
  • Better hack for placement
broulik accepted this revision.Mar 12 2018, 12:56 PM
This revision is now accepted and ready to land.Mar 12 2018, 12:56 PM

New screenshot with fixes

Fuchs closed this revision.Mar 12 2018, 1:07 PM
abetts added a subscriber: abetts.Mar 12 2018, 2:12 PM

We have discussed something like this before. My only worry with this implementation is that we have so much red on the screen that it becomes distracting. Not the fault of this patch, but I am wondering if there is a way that we can use a monochrome X button?

Fuchs added a comment.Mar 12 2018, 2:14 PM

We have discussed something like this before. My only worry with this implementation is that we have so much red on the screen that it becomes distracting. Not the fault of this patch, but I am wondering if there is a way that we can use a monochrome X button?

Both broulik and I would have prefered the trash icon, however, due to consistency ...

red, on the other hand, is good. It is a destructive action which can't be undone, so a bit of red doesn't hurt.

We have discussed something like this before. My only worry with this implementation is that we have so much red on the screen that it becomes distracting. Not the fault of this patch, but I am wondering if there is a way that we can use a monochrome X button?

Both broulik and I would have prefered the trash icon, however, due to consistency ...

red, on the other hand, is good. It is a destructive action which can't be undone, so a bit of red doesn't hurt.

Then please use the same X icon at the top of the list, to clear all.

Fuchs added a comment.Mar 12 2018, 2:27 PM

We have discussed something like this before. My only worry with this implementation is that we have so much red on the screen that it becomes distracting. Not the fault of this patch, but I am wondering if there is a way that we can use a monochrome X button?

Both broulik and I would have prefered the trash icon, however, due to consistency ...

red, on the other hand, is good. It is a destructive action which can't be undone, so a bit of red doesn't hurt.

Then please use the same X icon at the top of the list, to clear all.

I am definitely not going to use the same icon for different actions, sorry. That goes against everything I've been taught in UX and, for destructive actions, is in my opinion quite catastrophic. If two buttons do different things, they should not have the same icon.

What should be fixed is that action-delete is something else in plasma (see screenshot) than in non-plasma (where it is a trash can, which would work). If that is fixed, the icon also looks better, and fixed across every piece of qml that uses it. But that's a different bug.

A different icon that has been proposed is "clear-all", however, due to the nature of that icon (a left pointing arrow) it also looks wrong. Once that is fixed, I'd be willing to change to clear-all, but then as well it should be fixed across plasma, and not only in this plasmoid here.

tl;dr: until some icons are fixed and more global discussions have been held, I am not going to alter this change further.