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

Issue 2705553002: Cleanups for DialogClientView, DialogClientViewTest. (Closed)

Created:
3 years, 10 months ago by tapted
Modified:
3 years, 10 months ago
Reviewers:
sky
CC:
chromium-reviews, tfarina, chrome-apps-syd-reviews_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Cleanups for DialogClientView, DialogClientViewTest. This is a precursor for http://crrev.com/2706423002 with some orthogonal stuff to make review there easier. We want to use a LayoutManager for DialogClientView. This requires DCV to know about, and manage, all of its direct child views. Start by consolidating "CreateExtraView()" and other view creation into a "SetupViews()" method, and add a DCHECK to ensure client code isn't inserting random views. But. Currently a test inserts a random view to test focus traversal. To properly test focus, it needs a FocusManager, but the test harness doesn't use a Widget, so it doesn't have a FocusManager. So add a Widget to the test harness. Turns out we don't actually need a `TestDialogClientView`, or any of the protected methods in DialogClientView it was using: make them all private. BUG=671820 Review-Url: https://codereview.chromium.org/2705553002 Cr-Commit-Position: refs/heads/master@{#452321} Committed: https://chromium.googlesource.com/chromium/src/+/d9c220fe3846b32984b6f4b9ca7c43cd62edd98f

Patch Set 1 #

Patch Set 2 : squish examples - clang_format makes this poop #

Patch Set 3 : DialogExample - TODO: Move content dep #

Patch Set 4 : Cleanup example code before split #

Patch Set 5 : Just the cleanups - rest moved to crrev/2706423002 #

Patch Set 6 : Friendship, TestDialogClientView not needed #

Patch Set 7 : Better comments, clearer diff #

Total comments: 2

Patch Set 8 : Fixes Windows DWM and Linux. Not ChromeOS or Windows RDP. #

Patch Set 9 : More sensible checks #

Total comments: 6

Patch Set 10 : Remove unncessary child check #

Unified diffs Side-by-side diffs Delta from patch set Stats (+158 lines, -133 lines) Patch
M ui/views/window/dialog_client_view.h View 1 2 3 4 5 6 2 chunks +11 lines, -11 lines 0 comments Download
M ui/views/window/dialog_client_view.cc View 1 2 3 4 5 6 7 8 9 7 chunks +65 lines, -61 lines 0 comments Download
M ui/views/window/dialog_client_view_unittest.cc View 1 2 3 4 5 6 7 8 7 chunks +82 lines, -61 lines 0 comments Download

Dependent Patchsets:

Messages

Total messages: 54 (48 generated)
tapted
Hi sky, please take a look. (Note this was split from http://crrev.com/2706423002 "Use GridLayout in ...
3 years, 10 months ago (2017-02-22 05:56:11 UTC) #32
tapted
hm - some bots didn't like me (see notes below). I think I've found the ...
3 years, 10 months ago (2017-02-22 11:01:17 UTC) #44
sky
LGTM https://codereview.chromium.org/2705553002/diff/160002/ui/views/window/dialog_client_view.cc File ui/views/window/dialog_client_view.cc (right): https://codereview.chromium.org/2705553002/diff/160002/ui/views/window/dialog_client_view.cc#newcode125 ui/views/window/dialog_client_view.cc:125: (ok_button_ ? ok_button_->GetPreferredSize().width() : 0) + IMO this ...
3 years, 10 months ago (2017-02-22 17:29:48 UTC) #47
tapted
https://codereview.chromium.org/2705553002/diff/160002/ui/views/window/dialog_client_view.cc File ui/views/window/dialog_client_view.cc (right): https://codereview.chromium.org/2705553002/diff/160002/ui/views/window/dialog_client_view.cc#newcode125 ui/views/window/dialog_client_view.cc:125: (ok_button_ ? ok_button_->GetPreferredSize().width() : 0) + On 2017/02/22 17:29:48, ...
3 years, 10 months ago (2017-02-22 23:20:44 UTC) #48
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/2705553002/330001
3 years, 10 months ago (2017-02-22 23:22:39 UTC) #51
commit-bot: I haz the power
3 years, 10 months ago (2017-02-23 01:00:56 UTC) #54
Message was sent while issue was closed.
Committed patchset #10 (id:330001) as
https://chromium.googlesource.com/chromium/src/+/d9c220fe3846b32984b6f4b9ca7c...

Powered by Google App Engine
This is Rietveld 408576698