D18934: WIP: [Notifications] Remove close button border by porting to IconItem

Nathaniel Graham noreply at phabricator.kde.org
Tue Feb 12 19:01:43 GMT 2019


ngraham added a comment.


  I don't like this approach because the IconItem has no pressed state. This is already a problem for the Task Manager tooltips, and I'd like to not replicate it here too. Also I don't really like the fact that the close button is red here even before it's hovered; dismissing a notification is not a destructive action.
  
  I have an idea though. Try applying this on top of your patch:
  
    diff --git a/applets/notifications/package/contents/ui/NotificationItem.qml b/applets/notifications/package/contents/ui/NotificationItem.qml
    index 83bd9dcd..5386e557 100644
    --- a/applets/notifications/package/contents/ui/NotificationItem.qml
    +++ b/applets/notifications/package/contents/ui/NotificationItem.qml
    @@ -237,8 +237,8 @@ MouseArea {
                 PlasmaCore.IconItem {
                     id:closeIcon
                     anchors.fill: parent
    -                active: parent.containsMouse
    -                source: "window-close"
    +                active: parent.pressed
    +                source: parent.containsMouse ? "window-close" : "window-close-symbolic"
                     animated: false
                 }
             }
  
  (You can do this with `git apply -` then paste, then hit [Ctrl] + [d])
  
  Let me know if that appeals to you.

REPOSITORY
  R120 Plasma Workspace

REVISION DETAIL
  https://phabricator.kde.org/D18934

To: filipf, ngraham, #vdg, rooty, #plasma
Cc: plasma-devel, jraleigh, GB_2, ragreen, Pitel, ZrenBot, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, mart
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20190212/76ec56f6/attachment.html>


More information about the Plasma-devel mailing list