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

Issue 1753473003: A window should not get activated or get input focus if it's behind the lock screen. (Closed)

Created:
4 years, 9 months ago by xdai1
Modified:
4 years, 9 months ago
Reviewers:
sky
CC:
chromium-reviews, tfarina
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

A window should not get activated or get input focus if it's behind the lock screen. BUG=515594 Committed: https://crrev.com/8692d6358f0fab7c1b85054fc6edc37371d9b1aa Cr-Commit-Position: refs/heads/master@{#380724}

Patch Set 1 #

Patch Set 2 : Add test. #

Total comments: 5

Patch Set 3 : Address sky@'s comments #

Total comments: 9

Patch Set 4 : Address sky@'s comments #

Patch Set 5 : Address sky@'s comment. #

Total comments: 2

Patch Set 6 : Use IsActive() instead. #

Total comments: 2

Patch Set 7 : Don't use scoped ptr in the test. #

Patch Set 8 : Fix failed try jobs #

Patch Set 9 : Fix the failed try jobs #

Total comments: 7

Patch Set 10 : sorry, focus_manager_ is a scoped_ptr. #

Patch Set 11 : Modify the test to use NativeWidgetAura when initializing widget. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+126 lines, -28 lines) Patch
M ash/wm/ash_focus_rules_unittest.cc View 1 2 3 4 5 6 7 9 10 2 chunks +19 lines, -0 lines 0 comments Download
M ui/views/test/widget_test.h View 1 2 3 1 chunk +18 lines, -0 lines 0 comments Download
M ui/views/test/widget_test.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +18 lines, -0 lines 0 comments Download
M ui/views/widget/native_widget_aura.cc View 1 2 3 4 5 1 chunk +4 lines, -1 line 0 comments Download
M ui/views/widget/native_widget_aura_unittest.cc View 1 2 3 4 5 6 8 9 10 3 chunks +66 lines, -1 line 0 comments Download
M ui/views/widget/widget.cc View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -1 line 0 comments Download
M ui/views/widget/widget_interactive_uitest.cc View 1 1 chunk +0 lines, -25 lines 0 comments Download

Messages

Total messages: 54 (18 generated)
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1753473003/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1753473003/1
4 years, 9 months ago (2016-03-01 00:37:22 UTC) #2
xdai1
sky@, could you help review this CL please? Thanks!
4 years, 9 months ago (2016-03-01 01:28:39 UTC) #4
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 9 months ago (2016-03-01 01:53:44 UTC) #6
sky
How about some test coverage.
4 years, 9 months ago (2016-03-01 03:53:14 UTC) #7
xdai1
On 2016/03/01 03:53:14, sky wrote: > How about some test coverage. sky@, I've added the ...
4 years, 9 months ago (2016-03-02 00:20:12 UTC) #10
sky
https://codereview.chromium.org/1753473003/diff/60001/ash/wm/ash_focus_rules_unittest.cc File ash/wm/ash_focus_rules_unittest.cc (right): https://codereview.chromium.org/1753473003/diff/60001/ash/wm/ash_focus_rules_unittest.cc#newcode192 ash/wm/ash_focus_rules_unittest.cc:192: TEST_F(LockScreenAshFocusRulesTest, PreventFocusChangeWithLockScreenPresent) { Please add a test close to ...
4 years, 9 months ago (2016-03-02 03:41:02 UTC) #11
xdai1
sky@, please take another look, thanks for your help. https://codereview.chromium.org/1753473003/diff/60001/ash/wm/ash_focus_rules_unittest.cc File ash/wm/ash_focus_rules_unittest.cc (right): https://codereview.chromium.org/1753473003/diff/60001/ash/wm/ash_focus_rules_unittest.cc#newcode192 ash/wm/ash_focus_rules_unittest.cc:192: ...
4 years, 9 months ago (2016-03-02 21:15:55 UTC) #12
sky
https://codereview.chromium.org/1753473003/diff/60001/ash/wm/ash_focus_rules_unittest.cc File ash/wm/ash_focus_rules_unittest.cc (right): https://codereview.chromium.org/1753473003/diff/60001/ash/wm/ash_focus_rules_unittest.cc#newcode192 ash/wm/ash_focus_rules_unittest.cc:192: TEST_F(LockScreenAshFocusRulesTest, PreventFocusChangeWithLockScreenPresent) { On 2016/03/02 21:15:55, xdai1 wrote: > ...
4 years, 9 months ago (2016-03-02 22:09:09 UTC) #13
xdai1
On 2016/03/02 22:09:09, sky wrote: > https://codereview.chromium.org/1753473003/diff/60001/ash/wm/ash_focus_rules_unittest.cc > File ash/wm/ash_focus_rules_unittest.cc (right): > > https://codereview.chromium.org/1753473003/diff/60001/ash/wm/ash_focus_rules_unittest.cc#newcode192 > ...
4 years, 9 months ago (2016-03-03 00:59:40 UTC) #15
sky
https://codereview.chromium.org/1753473003/diff/100001/ui/views/test/widget_test.h File ui/views/test/widget_test.h (right): https://codereview.chromium.org/1753473003/diff/100001/ui/views/test/widget_test.h#newcode155 ui/views/test/widget_test.h:155: // should be initially focused. 'should be' ->is the ...
4 years, 9 months ago (2016-03-03 20:22:47 UTC) #16
xdai1
sky@, I've addressed your comments. Please take another look, thanks for your review. https://codereview.chromium.org/1753473003/diff/100001/ui/views/test/widget_test.h File ...
4 years, 9 months ago (2016-03-03 22:01:31 UTC) #17
sky
https://codereview.chromium.org/1753473003/diff/100001/ui/views/widget/native_widget_aura.cc File ui/views/widget/native_widget_aura.cc (right): https://codereview.chromium.org/1753473003/diff/100001/ui/views/widget/native_widget_aura.cc#newcode492 ui/views/widget/native_widget_aura.cc:492: if (delegate_->CanActivate() && wm::CanActivateWindow(window_)) { On 2016/03/03 22:01:31, xdai1 ...
4 years, 9 months ago (2016-03-03 23:39:33 UTC) #18
xdai1
On 2016/03/03 23:39:33, sky wrote: > https://codereview.chromium.org/1753473003/diff/100001/ui/views/widget/native_widget_aura.cc > File ui/views/widget/native_widget_aura.cc (right): > > https://codereview.chromium.org/1753473003/diff/100001/ui/views/widget/native_widget_aura.cc#newcode492 > ...
4 years, 9 months ago (2016-03-04 00:00:38 UTC) #19
sky
I think it's valid to fix this like I outlined, but I also think IME ...
4 years, 9 months ago (2016-03-04 00:13:58 UTC) #20
xdai1
Please take another look at the new patch. I guess that's what you suggest? Thanks ...
4 years, 9 months ago (2016-03-04 00:47:23 UTC) #23
sky
https://codereview.chromium.org/1753473003/diff/180001/ui/views/widget/native_widget_aura.cc File ui/views/widget/native_widget_aura.cc (right): https://codereview.chromium.org/1753473003/diff/180001/ui/views/widget/native_widget_aura.cc#newcode494 ui/views/widget/native_widget_aura.cc:494: Activate(); I was thinking that in this branch you ...
4 years, 9 months ago (2016-03-04 16:32:55 UTC) #24
xdai1
sky@, please take another look, thanks for your review. https://codereview.chromium.org/1753473003/diff/180001/ui/views/widget/native_widget_aura.cc File ui/views/widget/native_widget_aura.cc (right): https://codereview.chromium.org/1753473003/diff/180001/ui/views/widget/native_widget_aura.cc#newcode494 ui/views/widget/native_widget_aura.cc:494: ...
4 years, 9 months ago (2016-03-04 22:27:28 UTC) #25
sky
How about calling IsActive() right after the activate to determine if it really got activated? ...
4 years, 9 months ago (2016-03-04 23:01:53 UTC) #26
xdai1
On 2016/03/04 23:01:53, sky wrote: > How about calling IsActive() right after the activate to ...
4 years, 9 months ago (2016-03-04 23:30:31 UTC) #27
sky
LGTM https://codereview.chromium.org/1753473003/diff/200001/ui/views/widget/native_widget_aura_unittest.cc File ui/views/widget/native_widget_aura_unittest.cc (right): https://codereview.chromium.org/1753473003/diff/200001/ui/views/widget/native_widget_aura_unittest.cc#newcode527 ui/views/widget/native_widget_aura_unittest.cc:527: scoped_ptr<views::Widget> w1(new views::Widget); You don't need a scoped_ptr ...
4 years, 9 months ago (2016-03-07 16:05:15 UTC) #28
xdai1
On 2016/03/07 16:05:15, sky wrote: > LGTM > > https://codereview.chromium.org/1753473003/diff/200001/ui/views/widget/native_widget_aura_unittest.cc > File ui/views/widget/native_widget_aura_unittest.cc (right): > ...
4 years, 9 months ago (2016-03-07 17:20:05 UTC) #29
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1753473003/220001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1753473003/220001
4 years, 9 months ago (2016-03-07 17:20:38 UTC) #32
commit-bot: I haz the power
Try jobs failed on following builders: win8_chromium_ng on tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win8_chromium_ng/builds/113764)
4 years, 9 months ago (2016-03-07 17:56:43 UTC) #34
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1753473003/240001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1753473003/240001
4 years, 9 months ago (2016-03-07 19:47:00 UTC) #36
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: win_chromium_rel_ng on tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_ng/builds/185115)
4 years, 9 months ago (2016-03-07 20:38:43 UTC) #38
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1753473003/260001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1753473003/260001
4 years, 9 months ago (2016-03-08 02:14:17 UTC) #41
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: win_chromium_x64_rel_ng on tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_x64_rel_ng/builds/179209)
4 years, 9 months ago (2016-03-08 02:52:43 UTC) #43
xdai1
sky@, could you take a look at this CL to see if it's still looks ...
4 years, 9 months ago (2016-03-08 18:30:17 UTC) #44
sky
https://codereview.chromium.org/1753473003/diff/280001/ui/views/widget/native_widget_aura_unittest.cc File ui/views/widget/native_widget_aura_unittest.cc (right): https://codereview.chromium.org/1753473003/diff/280001/ui/views/widget/native_widget_aura_unittest.cc#newcode522 ui/views/widget/native_widget_aura_unittest.cc:522: #if defined(OS_CHROMEOS) On 2016/03/08 18:30:17, xdai1 wrote: > I ...
4 years, 9 months ago (2016-03-08 22:42:04 UTC) #45
xdai1
sky@, please take another look. Thanks for your help. https://codereview.chromium.org/1753473003/diff/280001/ui/views/widget/native_widget_aura_unittest.cc File ui/views/widget/native_widget_aura_unittest.cc (right): https://codereview.chromium.org/1753473003/diff/280001/ui/views/widget/native_widget_aura_unittest.cc#newcode522 ui/views/widget/native_widget_aura_unittest.cc:522: ...
4 years, 9 months ago (2016-03-10 01:12:57 UTC) #46
sky
https://codereview.chromium.org/1753473003/diff/280001/ui/views/widget/native_widget_aura_unittest.cc File ui/views/widget/native_widget_aura_unittest.cc (right): https://codereview.chromium.org/1753473003/diff/280001/ui/views/widget/native_widget_aura_unittest.cc#newcode522 ui/views/widget/native_widget_aura_unittest.cc:522: #if defined(OS_CHROMEOS) On 2016/03/10 01:12:57, xdai1 wrote: > On ...
4 years, 9 months ago (2016-03-10 17:09:39 UTC) #47
xdai1
On 2016/03/10 17:09:39, sky wrote: > > The NativeWidgetType is based on many factors. On ...
4 years, 9 months ago (2016-03-11 19:51:05 UTC) #48
sky
LGTM
4 years, 9 months ago (2016-03-11 20:48:01 UTC) #49
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1753473003/320001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1753473003/320001
4 years, 9 months ago (2016-03-11 20:55:55 UTC) #51
commit-bot: I haz the power
Committed patchset #11 (id:320001)
4 years, 9 months ago (2016-03-11 21:03:36 UTC) #52
commit-bot: I haz the power
4 years, 9 months ago (2016-03-11 21:05:57 UTC) #54
Message was sent while issue was closed.
Patchset 11 (id:??) landed as
https://crrev.com/8692d6358f0fab7c1b85054fc6edc37371d9b1aa
Cr-Commit-Position: refs/heads/master@{#380724}

Powered by Google App Engine
This is Rietveld 408576698