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

Issue 2087703002: tabing inconsistencies between trays in status area (Closed)

Created:
4 years, 6 months ago by Qiang(Joe) Xu
Modified:
4 years, 6 months ago
Reviewers:
falken, James Cook, jennyz
CC:
chromium-reviews, kalyank, sadrul
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Detailed reproduce steps are in comment 2 in crbug.com/468969 There are several bugs in the status area tray focus advancing. (1) there is a invisible focus between system tray and web notification tray. This is because there is a focus traversal in web notification tray's child. Solution is to disable it. When virtual keyboard is enabled, we should also disable its child view traversal. (2) TAB will be trapped in system tray. Web notification tray is async painted. The initialization sibling relation may not be ready. Add a setnextfocusibleview call will fix that. BUG=468969 TEST=tested on device, both tabing and shift-tabing works well on status area. There is still a bug in crbug.com/468969 comment 7. It happens in login screen only. When logged in, it works fine. Committed: https://crrev.com/133c792af9dfe8c82561bee7015efcc0b5dba22d Committed: https://crrev.com/ab543ef12f3b412b9e008fce7e78f4456de82822 Cr-Original-Commit-Position: refs/heads/master@{#401765} Cr-Commit-Position: refs/heads/master@{#401810}

Patch Set 1 #

Patch Set 2 : merge #

Patch Set 3 : virtual keyboard tray also works well on logged in status #

Patch Set 4 : rebase and fix conflict #

Patch Set 5 : land mine first #

Unified diffs Side-by-side diffs Delta from patch set Stats (+4 lines, -0 lines) Patch
M ash/system/chromeos/virtual_keyboard/virtual_keyboard_tray.cc View 1 4 1 chunk +1 line, -0 lines 0 comments Download
M ash/system/web_notification/web_notification_tray.cc View 1 2 4 2 chunks +3 lines, -0 lines 0 comments Download

Messages

Total messages: 35 (17 generated)
Qiang(Joe) Xu
Hi Jenny, could you help review on this? tks
4 years, 6 months ago (2016-06-21 00:14:35 UTC) #3
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2087703002/1
4 years, 6 months ago (2016-06-21 05:05:31 UTC) #5
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 6 months ago (2016-06-21 05:46:35 UTC) #7
Qiang(Joe) Xu
Updated subject, including the case for virtual keyboard tray
4 years, 6 months ago (2016-06-23 21:14:34 UTC) #9
jennyz
lgtm
4 years, 6 months ago (2016-06-23 23:15:00 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2087703002/40001
4 years, 6 months ago (2016-06-23 23:29:09 UTC) #12
commit-bot: I haz the power
Committed patchset #3 (id:40001)
4 years, 6 months ago (2016-06-24 00:59:53 UTC) #14
commit-bot: I haz the power
Patchset 3 (id:??) landed as https://crrev.com/133c792af9dfe8c82561bee7015efcc0b5dba22d Cr-Commit-Position: refs/heads/master@{#401765}
4 years, 6 months ago (2016-06-24 01:02:34 UTC) #16
falken
On 2016/06/24 01:02:34, commit-bot: I haz the power wrote: > Patchset 3 (id:??) landed as ...
4 years, 6 months ago (2016-06-24 02:03:55 UTC) #17
falken
A revert of this CL (patchset #3 id:40001) has been created in https://codereview.chromium.org/2090353005/ by falken@chromium.org. ...
4 years, 6 months ago (2016-06-24 02:07:05 UTC) #18
Qiang(Joe) Xu
On 2016/06/24 02:07:05, falken wrote: > A revert of this CL (patchset #3 id:40001) has ...
4 years, 6 months ago (2016-06-24 02:32:45 UTC) #21
James Cook
LGTM. You might need to re-rebase, as my patch got reverted too.
4 years, 6 months ago (2016-06-24 02:48:10 UTC) #23
James Cook
lgtm again
4 years, 6 months ago (2016-06-24 02:58:30 UTC) #24
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2087703002/80001
4 years, 6 months ago (2016-06-24 03:02:17 UTC) #27
commit-bot: I haz the power
Committed patchset #5 (id:80001)
4 years, 6 months ago (2016-06-24 03:51:42 UTC) #29
commit-bot: I haz the power
Patchset 5 (id:??) landed as https://crrev.com/ab543ef12f3b412b9e008fce7e78f4456de82822 Cr-Commit-Position: refs/heads/master@{#401810}
4 years, 6 months ago (2016-06-24 03:53:23 UTC) #31
blundell
A revert of this CL (patchset #5 id:80001) has been created in https://codereview.chromium.org/2095933002/ by blundell@chromium.org. ...
4 years, 6 months ago (2016-06-24 10:33:54 UTC) #32
James Cook
4 years, 6 months ago (2016-06-24 15:49:05 UTC) #33
Message was sent while issue was closed.
On 2016/06/24 10:33:54, blundell wrote:
> A revert of this CL (patchset #5 id:80001) has been created in
> https://codereview.chromium.org/2095933002/ by mailto:blundell@chromium.org.
> 
> The reason for reverting is: Causes UaF in web_notification_tray.cc on
> focus_cycler_unittest.cc. The issue appears to be unclear lifetime assumptions
> of the system tray object: the status area widget maintains a raw pointer to
it
> (and confusingly *sometimes* owns it, i.e. when its Shutdown() method is
> called), whereas focus_cycler_unittest.cc actually owns it but doesn't clear
it
> out from the status area widget when it deletes it on TearDown(). It looks
like
> this CL just tickled a pre-existing bad situation, but the best fix is not
> obvious to me as a non-expert in this part of the codebase, so I have to
revert.
> 
> Example failure:
>
https://build.chromium.org/p/chromium.memory/builders/Linux%20Chromium%20OS%2...
> 
> Relevant snippet:
> 
> ==7090==ERROR: AddressSanitizer: heap-use-after-free on address 0x618000021608
> at pc 0x00000a32db44 bp 0x7ffdd1268ae0 sp 0x7ffdd1268ad8
> WRITE of size 8 at 0x618000021608 thread T0
>     #0 0xa32db43 in views::View::SetNextFocusableView(views::View*)
> ui/views/view.cc:1198:24
>     #1 0x964d8ba in Run base/callback.h:397:12
>     #2 0x964d8ba in base::debug::TaskAnnotator::RunTask(char const*,
> base::PendingTask const&) base/debug/task_annotator.cc:51
>     #3 0x95131cc in base::MessageLoop::RunTask(base::PendingTask const&)
> base/message_loop/message_loop.cc:493:19
>     #4 0x951401b in base::MessageLoop::DeferOrRunPendingTask(base::PendingTask
> const&) base/message_loop/message_loop.cc:502:5
>     #5 0x9514eab in base::MessageLoop::DoWork()
> base/message_loop/message_loop.cc:624:13
>     #6 0x95191f7 in base::MessagePumpGlib::Run(base::MessagePump::Delegate*)
> base/message_loop/message_pump_glib.cc:313:49
>     #7 0x956bbfb in base::RunLoop::Run() base/run_loop.cc:35:10
>     #8 0x127dc12 in ash::test::AshTestHelper::RunAllPendingInMessageLoop()
> ash/test/ash_test_helper.cc:192:12
>     #9 0x127b887 in RunAllPendingInMessageLoop
ash/test/ash_test_base.cc:287:21
>     #10 0x127b887 in ash::test::AshTestBase::TearDown()
> ash/test/ash_test_base.cc:163.

Perhaps FocusCyclerTest needs to call StatusAreaWidget::Shutdown() on the one it
creates?

Failing that, perhaps it should use the real StatusAreaWidget created by
AshTestBase.

Powered by Google App Engine
This is Rietveld 408576698