Take the screen geometry into account when positioning popup notifications
ClosedPublic

Authored by dvratil on May 13 2019, 11:29 AM.

Details

Summary

The availableScreenRect is relative to the current screen, so if the notification
applet is not on the top-left screen, the notification popup will not appear next
to where the applet is but on the top-left screen instead. Adding the absolute
screen geometry to the availableScreenRect ensures that the popup is positioned
on the right screen.

Test Plan

Position two screens above each other, place the panel on the bottom screen, the
notification now correctly appears on the bottom screen next to the applet.

Diff Detail

Repository
R120 Plasma Workspace
Branch
master
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 11788
Build 11806: arc lint + arc unit
dvratil created this revision.May 13 2019, 11:29 AM
Restricted Application added a project: Plasma. · View Herald TranscriptMay 13 2019, 11:29 AM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
dvratil requested review of this revision.May 13 2019, 11:29 AM
davidedmundson accepted this revision.May 13 2019, 11:32 AM
This revision is now accepted and ready to land.May 13 2019, 11:32 AM

I'll test and report if it works in my case, too.

Doesn't seem to work with screens that have a rotation.
Setup:

Actual display of a notification:

(note where it is, when it's set to "bottom right":

broulik accepted this revision.May 13 2019, 12:14 PM

Thanks

lbeltrame accepted this revision.May 13 2019, 12:15 PM

It needs D21152 applied as well to work properly in my scenario.

This revision was automatically updated to reflect the committed changes.