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

Issue 2561253002: [ash-md] Adds support for Z-order iteration in views::View (Closed)

Created:
4 years ago by varkha
Modified:
3 years, 11 months ago
Reviewers:
sadrul, sky
CC:
chromium-reviews, sadrul, hashimoto+watch_chromium.org, tfarina, oshima+watch_chromium.org, kalyank, stevenjb+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[ash-md] Adds support for Z-order iteration in views::View This CL is a demonstration of an alternative to https://codereview.chromium.org/2557333003/ . This alternative shows how we could add a custom iterator over children to views::View. Benefits: - Avoids need to override all of those: View::GetTooltipHandlerForPoint View::PaintChildren View::ReorderChildLayers ViewTargeterDelegate::TargetForRect just for the sake of implementing Z-order. We may still need to override them to add custom painting and such but not to mess with the Z-order. - Keeps the iterations in views::View base class implementation BUG=664244 Committed: https://crrev.com/321f8fbf1e90199a9d8bbbe14f5a99db92e85246 Cr-Commit-Position: refs/heads/master@{#441247}

Patch Set 1 #

Patch Set 2 : [ash-md] Adds support for Z-order iteration in views::View (fixed separators) #

Patch Set 3 : [ash-md] Adds support for Z-order iteration in views::View (using GetChildrenOrderedByVisualOrder) #

Total comments: 10

Patch Set 4 : [ash-md] Adds support for Z-order iteration in views::View (rebased) #

Patch Set 5 : [ash-md] Adds support for Z-order iteration in views::View (test) #

Patch Set 6 : [ash-md] Adds support for Z-order iteration in views::View (test) #

Patch Set 7 : [ash-md] Adds support for Z-order iteration in views::View (rebased) #

Patch Set 8 : [ash-md] Adds support for Z-order iteration in views::View (rebased) #

Patch Set 9 : [ash-md] Adds support for Z-order iteration in views::View (rebased) #

Total comments: 2

Patch Set 10 : [ash-md] Adds support for Z-order iteration in views::View (nit) #

Unified diffs Side-by-side diffs Delta from patch set Stats (+105 lines, -70 lines) Patch
M ash/common/system/tray/tray_details_view.cc View 1 2 3 4 5 6 7 8 6 chunks +17 lines, -61 lines 0 comments Download
M ui/views/view.h View 1 2 3 4 5 6 7 8 2 chunks +10 lines, -0 lines 0 comments Download
M ui/views/view.cc View 1 2 3 4 5 6 7 8 4 chunks +13 lines, -6 lines 0 comments Download
M ui/views/view_targeter_delegate.cc View 1 2 3 4 5 6 2 chunks +4 lines, -3 lines 0 comments Download
M ui/views/view_unittest.cc View 1 2 3 4 5 6 7 8 9 1 chunk +61 lines, -0 lines 0 comments Download

Messages

Total messages: 57 (27 generated)
varkha
sadrul@, can you comment on this first, I can send it to sky then for ...
4 years ago (2016-12-09 00:48:33 UTC) #2
varkha
+sky for feedback on the idea.
4 years ago (2016-12-09 18:57:26 UTC) #4
sky
I would prefer not to add more api to View that complicates an already confusing ...
4 years ago (2016-12-09 20:48:00 UTC) #5
varkha
On 2016/12/09 20:48:00, sky wrote: > I would prefer not to add more api to ...
4 years ago (2016-12-10 00:20:55 UTC) #6
sky
Good point. What are the set of views that customize paint order of children? I ...
4 years ago (2016-12-12 02:02:44 UTC) #7
varkha
On 2016/12/12 02:02:44, sky wrote: > Good point. What are the set of views that ...
4 years ago (2016-12-12 04:00:53 UTC) #8
sadrul
I think the list under 'improvements' are more of a 'requirement', as in, once we ...
4 years ago (2016-12-12 15:51:04 UTC) #9
sky
On Sun, Dec 11, 2016 at 8:00 PM, <varkha@chromium.org> wrote: > On 2016/12/12 02:02:44, sky ...
4 years ago (2016-12-12 16:12:38 UTC) #10
varkha
On 2016/12/12 16:12:38, sky wrote: > On Sun, Dec 11, 2016 at 8:00 PM, <mailto:varkha@chromium.org> ...
4 years ago (2016-12-12 17:18:20 UTC) #11
varkha
On 2016/12/12 15:51:04, sadrul wrote: > I think the list under 'improvements' are more of ...
4 years ago (2016-12-12 17:19:08 UTC) #12
sky
On 2016/12/12 17:18:20, varkha wrote: > On 2016/12/12 16:12:38, sky wrote: > > On Sun, ...
4 years ago (2016-12-12 17:57:51 UTC) #13
sadrul
What about a focus-focused API, e.g. setting something equivalent to tab-index in views.
4 years ago (2016-12-12 18:38:38 UTC) #14
varkha
> Bummer. > > I don't think you can make the new one an iterator ...
4 years ago (2016-12-12 19:03:15 UTC) #15
varkha
On 2016/12/12 18:38:38, sadrul wrote: > What about a focus-focused API, e.g. setting something equivalent ...
4 years ago (2016-12-12 22:39:20 UTC) #16
varkha
Posted an exploration using View::GetChildrenOrderedByVisualOrder().
4 years ago (2016-12-12 23:15:13 UTC) #17
sky
This sounds messy, but I could certainly be missing something. You should make sure what ...
4 years ago (2016-12-13 01:49:36 UTC) #18
varkha
On 2016/12/13 01:49:36, sky wrote: > This sounds messy, but I could certainly be missing ...
4 years ago (2016-12-13 16:53:15 UTC) #19
sky
Do you have a patch that fixes only scrollview (doesn't change view)? -Scott On Tue, ...
4 years ago (2016-12-13 18:06:42 UTC) #20
varkha
On 2016/12/13 18:06:42, sky wrote: > Do you have a patch that fixes only scrollview ...
4 years ago (2016-12-13 22:22:29 UTC) #21
sky
I would prefer not to complicate view with additional api, but I agree it's far ...
4 years ago (2016-12-13 23:40:56 UTC) #22
varkha
https://codereview.chromium.org/2561253002/diff/40001/ui/views/view.h File ui/views/view.h (right): https://codereview.chromium.org/2561253002/diff/40001/ui/views/view.h#newcode310 ui/views/view.h:310: // Get a container of |children_| arranged according to ...
4 years ago (2016-12-14 17:51:38 UTC) #23
sky
*SIGH* I guess there are reasons to keep the function public. On Wed, Dec 14, ...
4 years ago (2016-12-14 18:33:24 UTC) #24
varkha
Added a test. PTAL. https://codereview.chromium.org/2561253002/diff/40001/ui/views/view.cc File ui/views/view.cc (right): https://codereview.chromium.org/2561253002/diff/40001/ui/views/view.cc#newcode1448 ui/views/view.cc:1448: for (int i = 0, ...
4 years ago (2016-12-19 20:35:44 UTC) #25
varkha
https://codereview.chromium.org/2561253002/diff/40001/ui/views/view.cc File ui/views/view.cc (right): https://codereview.chromium.org/2561253002/diff/40001/ui/views/view.cc#newcode1448 ui/views/view.cc:1448: for (int i = 0, count = children.size(); i ...
4 years ago (2016-12-19 20:56:16 UTC) #28
varkha
Now that the refactoring in the View iterators has landed this CL is a bit ...
4 years ago (2016-12-23 00:48:23 UTC) #39
sky
LGTM https://codereview.chromium.org/2561253002/diff/180001/ui/views/view_unittest.cc File ui/views/view_unittest.cc (right): https://codereview.chromium.org/2561253002/diff/180001/ui/views/view_unittest.cc#newcode4675 ui/views/view_unittest.cc:4675: static const int VIEW_ID_RAISED = 1000; constexpr and ...
3 years, 11 months ago (2017-01-03 21:46:36 UTC) #44
varkha
https://codereview.chromium.org/2561253002/diff/180001/ui/views/view_unittest.cc File ui/views/view_unittest.cc (right): https://codereview.chromium.org/2561253002/diff/180001/ui/views/view_unittest.cc#newcode4675 ui/views/view_unittest.cc:4675: static const int VIEW_ID_RAISED = 1000; On 2017/01/03 21:46:36, ...
3 years, 11 months ago (2017-01-03 22:21:35 UTC) #46
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/2561253002/200001
3 years, 11 months ago (2017-01-03 23:16:27 UTC) #52
commit-bot: I haz the power
Committed patchset #10 (id:200001)
3 years, 11 months ago (2017-01-03 23:22:25 UTC) #55
commit-bot: I haz the power
3 years, 11 months ago (2017-01-03 23:25:27 UTC) #57
Message was sent while issue was closed.
Patchset 10 (id:??) landed as
https://crrev.com/321f8fbf1e90199a9d8bbbe14f5a99db92e85246
Cr-Commit-Position: refs/heads/master@{#441247}

Powered by Google App Engine
This is Rietveld 408576698