Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(85)

Issue 2078773003: Realign message center popups when displays are added or removed (Closed)

Created:
4 years, 6 months ago by osandov
Modified:
4 years, 5 months ago
Reviewers:
stevenjb, Jun Mukai, dewittj
CC:
chromium-reviews, Peter Beverloo, mlamouri+watch-notifications_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Realign message center popups when displays are added or removed When switching between displays with different resolutions (e.g., plugging in an external monitor to a laptop), there is no "DisplayMetricsChanged" event on Linux. This causes notifications to appear in the wrong position. Handle this by checking if the primary display has changed whenever a display is added or removed. BUG=621010 Committed: https://crrev.com/86453717f7fe8a57bb407cadcf337aab80fd7e22 Cr-Commit-Position: refs/heads/master@{#405036}

Patch Set 1 #

Total comments: 14

Patch Set 2 : Realign message center popups when displays are added or removed #

Total comments: 2

Patch Set 3 : Realign message center popups when displays are added or removed #

Patch Set 4 : Realign message center popups when displays are added or removed #

Unified diffs Side-by-side diffs Delta from patch set Stats (+33 lines, -9 lines) Patch
M AUTHORS View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M ui/message_center/views/desktop_popup_alignment_delegate.h View 1 2 2 chunks +3 lines, -1 line 0 comments Download
M ui/message_center/views/desktop_popup_alignment_delegate.cc View 1 2 3 3 chunks +29 lines, -8 lines 0 comments Download

Messages

Total messages: 40 (10 generated)
osandov
4 years, 6 months ago (2016-06-17 05:32:37 UTC) #3
Jun Mukai
I don't think this is the right place to fix. If it's the same display ...
4 years, 6 months ago (2016-06-17 07:01:11 UTC) #4
osandov
On 2016/06/17 07:01:11, Jun Mukai wrote: > I don't think this is the right place ...
4 years, 6 months ago (2016-06-17 07:16:47 UTC) #6
Jun Mukai
On 2016/06/17 07:16:47, osandov wrote: > On 2016/06/17 07:01:11, Jun Mukai wrote: > > I ...
4 years, 6 months ago (2016-06-17 08:00:52 UTC) #7
osandov
On 2016/06/17 08:00:52, Jun Mukai wrote: > On 2016/06/17 07:16:47, osandov wrote: > > On ...
4 years, 6 months ago (2016-06-17 08:18:58 UTC) #8
Jun Mukai
On 2016/06/17 08:18:58, osandov wrote: > On 2016/06/17 08:00:52, Jun Mukai wrote: > > On ...
4 years, 6 months ago (2016-06-17 17:35:08 UTC) #10
dewittj
If I remember correctly, when this was implemented we did get a DisplayMetricsChanged event if ...
4 years, 6 months ago (2016-06-17 17:40:29 UTC) #11
dewittj
ah I see you are an external contributor. If that is not plausible for you, ...
4 years, 6 months ago (2016-06-17 17:41:36 UTC) #12
osandov
On 2016/06/17 17:41:36, dewittj wrote: > ah I see you are an external contributor. If ...
4 years, 6 months ago (2016-06-17 17:49:33 UTC) #13
dewittj
https://codereview.chromium.org/2078773003/diff/1/ui/message_center/views/desktop_popup_alignment_delegate.cc File ui/message_center/views/desktop_popup_alignment_delegate.cc (right): https://codereview.chromium.org/2078773003/diff/1/ui/message_center/views/desktop_popup_alignment_delegate.cc#newcode87 ui/message_center/views/desktop_popup_alignment_delegate.cc:87: const display::Display& new_display) { rename to added_display https://codereview.chromium.org/2078773003/diff/1/ui/message_center/views/desktop_popup_alignment_delegate.cc#newcode88 ui/message_center/views/desktop_popup_alignment_delegate.cc:88: ...
4 years, 6 months ago (2016-06-20 17:06:00 UTC) #14
Jun Mukai
Hm, so that's still bad on other platforms? Considering this class is actually a singleton ...
4 years, 6 months ago (2016-06-20 20:28:54 UTC) #15
osandov
This is a slightly clearer version with the common code factored out.
4 years, 6 months ago (2016-06-21 06:01:12 UTC) #16
Jun Mukai
This is a matter of communication style, but usually you're supposed to reply on individual ...
4 years, 6 months ago (2016-06-21 06:42:37 UTC) #17
osandov
Thanks for the guidance. https://codereview.chromium.org/2078773003/diff/1/ui/message_center/views/desktop_popup_alignment_delegate.cc File ui/message_center/views/desktop_popup_alignment_delegate.cc (right): https://codereview.chromium.org/2078773003/diff/1/ui/message_center/views/desktop_popup_alignment_delegate.cc#newcode87 ui/message_center/views/desktop_popup_alignment_delegate.cc:87: const display::Display& new_display) { On ...
4 years, 6 months ago (2016-06-21 08:01:06 UTC) #18
osandov
Sorry, one more. https://codereview.chromium.org/2078773003/diff/1/ui/message_center/views/desktop_popup_alignment_delegate.cc File ui/message_center/views/desktop_popup_alignment_delegate.cc (right): https://codereview.chromium.org/2078773003/diff/1/ui/message_center/views/desktop_popup_alignment_delegate.cc#newcode109 ui/message_center/views/desktop_popup_alignment_delegate.cc:109: if (display.id() == display_id_) { On ...
4 years, 6 months ago (2016-06-21 08:02:40 UTC) #19
dewittj
I verified that the multiscreen behavior on Windows seems fine even with the patch. https://codereview.chromium.org/2078773003/diff/20001/ui/message_center/views/desktop_popup_alignment_delegate.cc ...
4 years, 5 months ago (2016-06-27 17:37:28 UTC) #20
osandov
https://codereview.chromium.org/2078773003/diff/20001/ui/message_center/views/desktop_popup_alignment_delegate.cc File ui/message_center/views/desktop_popup_alignment_delegate.cc (right): https://codereview.chromium.org/2078773003/diff/20001/ui/message_center/views/desktop_popup_alignment_delegate.cc#newcode112 ui/message_center/views/desktop_popup_alignment_delegate.cc:112: // Set to kInvalidDisplayID so the alignment is updated ...
4 years, 5 months ago (2016-06-27 19:22:52 UTC) #21
Jun Mukai
Hi -- I want to make sure what will happen on Windows without this patch. ...
4 years, 5 months ago (2016-06-27 23:18:44 UTC) #22
dewittj
Chrome Canary on windows seems to have correct behavior.
4 years, 5 months ago (2016-06-28 15:24:30 UTC) #23
osandov
On 2016/06/28 15:24:30, dewittj wrote: > Chrome Canary on windows seems to have correct behavior. ...
4 years, 5 months ago (2016-06-29 07:20:36 UTC) #24
Jun Mukai
On 2016/06/29 07:20:36, osandov wrote: > On 2016/06/28 15:24:30, dewittj wrote: > > Chrome Canary ...
4 years, 5 months ago (2016-06-29 18:29:36 UTC) #25
dewittj
This patch needs a rebase. I also did some research, it looks like if you ...
4 years, 5 months ago (2016-06-30 17:50:40 UTC) #26
osandov
Right, looks like the display abstraction behaves slightly differently on Linux and Windows, but this ...
4 years, 5 months ago (2016-07-07 02:09:50 UTC) #28
dewittj
I'll approve this patch but I'd like an explicit comment about how the behavior differs ...
4 years, 5 months ago (2016-07-11 20:59:54 UTC) #29
osandov
Thanks, updated with a comment that should hopefully make things clear for anyone else who ...
4 years, 5 months ago (2016-07-12 02:32:24 UTC) #30
dewittj
lgtm, thanks for your patience!
4 years, 5 months ago (2016-07-12 17:28:00 UTC) #31
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2078773003/60001
4 years, 5 months ago (2016-07-13 03:27:25 UTC) #35
commit-bot: I haz the power
Committed patchset #4 (id:60001)
4 years, 5 months ago (2016-07-13 05:05:25 UTC) #37
commit-bot: I haz the power
CQ bit was unchecked.
4 years, 5 months ago (2016-07-13 05:05:40 UTC) #38
commit-bot: I haz the power
4 years, 5 months ago (2016-07-13 05:08:16 UTC) #40
Message was sent while issue was closed.
Patchset 4 (id:??) landed as
https://crrev.com/86453717f7fe8a57bb407cadcf337aab80fd7e22
Cr-Commit-Position: refs/heads/master@{#405036}

Powered by Google App Engine
This is Rietveld 408576698