New issue
Advanced search Search tips

Issue 897377 link

Starred by 1 user

Issue metadata

Status: Started
Owner:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug



Sign in to add a comment

Cleanup Views Examples

Project Member Reported by robliao@chromium.org, Oct 19

Issue description

Cleanup and Make Views Examples easier to see and use.
 
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/c75ec2a2b96732fae065b2322b3c88f29b270e86

commit c75ec2a2b96732fae065b2322b3c88f29b270e86
Author: Robert Liao <robliao@chromium.org>
Date: Mon Oct 22 21:31:53 2018

Make All Combobox Models Owned By Their Respective Comboboxes

Making all combobox models owned by their respective comboboxes
simplifes lifetime management for the examples app as models are
essentially not referenced outside of construction.

In certain exceptions, when they are referenced, they occur in response
to handling a combobox event.

This also allows all of the examples apps using comboboxes to use the
normal views destruction codepath instead of having to explicitly
destroy the combobox.

BUG=897337

Change-Id: I2823517296f46a17d864936397963e1eee8bbfaa
Reviewed-on: https://chromium-review.googlesource.com/c/1294205
Commit-Queue: Robert Liao <robliao@chromium.org>
Reviewed-by: Scott Violet <sky@chromium.org>
Cr-Commit-Position: refs/heads/master@{#601730}
[modify] https://crrev.com/c75ec2a2b96732fae065b2322b3c88f29b270e86/ui/views/examples/examples_window.cc
[modify] https://crrev.com/c75ec2a2b96732fae065b2322b3c88f29b270e86/ui/views/examples/label_example.cc
[modify] https://crrev.com/c75ec2a2b96732fae065b2322b3c88f29b270e86/ui/views/examples/label_example.h
[modify] https://crrev.com/c75ec2a2b96732fae065b2322b3c88f29b270e86/ui/views/examples/text_example.cc
[modify] https://crrev.com/c75ec2a2b96732fae065b2322b3c88f29b270e86/ui/views/examples/text_example.h
Project Member

Comment 2 by bugdroid1@chromium.org, Oct 23

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/502529c19a3023f02e6a34a72c2584981796fe53

commit 502529c19a3023f02e6a34a72c2584981796fe53
Author: Robert Liao <robliao@chromium.org>
Date: Tue Oct 23 16:14:31 2018

Fix Closing Views Examples

http://crrev.com/593230 removed a call to
base::RunLoop::QuitCurrentWhenIdleDeprecated() and plumbed the quit
closure to ExamplesWindowContents.

However, when ExamplesWindowContents is created, the RunLoop driving
the main thread hasn't yet been created and as a result, the quit
closure isn't set. This means when ExamplesWindowContents closes,
the RunLoop happily continues running.

The fix here moves the RunLoop creation earlier so that the QuitClosure
can be passed through to ExamplesWindowContents.

BUG=897377

Change-Id: I1c14f090be2756dc049d7afcc857b10b31912d3e
Reviewed-on: https://chromium-review.googlesource.com/c/1292829
Reviewed-by: Scott Violet <sky@chromium.org>
Reviewed-by: Wez <wez@chromium.org>
Commit-Queue: Robert Liao <robliao@chromium.org>
Cr-Commit-Position: refs/heads/master@{#601975}
[modify] https://crrev.com/502529c19a3023f02e6a34a72c2584981796fe53/ui/views_content_client/views_content_client_main_parts.cc
[modify] https://crrev.com/502529c19a3023f02e6a34a72c2584981796fe53/ui/views_content_client/views_content_client_main_parts.h

Project Member

Comment 3 by bugdroid1@chromium.org, Oct 23

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/7ad8c0367ef9eb62e498cf9f7cea58f2859bb0d6

commit 7ad8c0367ef9eb62e498cf9f7cea58f2859bb0d6
Author: Robert Liao <robliao@chromium.org>
Date: Tue Oct 23 23:45:43 2018

Split the Combobox Example Model into Three Models

This simplifies lifetime handling for these comboboxes.

BUG=897377

Change-Id: I19e8ed25f8e6b17012669ad7e810d33aa28d8ec8
Reviewed-on: https://chromium-review.googlesource.com/c/1295589
Reviewed-by: Scott Violet <sky@chromium.org>
Commit-Queue: Robert Liao <robliao@chromium.org>
Cr-Commit-Position: refs/heads/master@{#602174}
[modify] https://crrev.com/7ad8c0367ef9eb62e498cf9f7cea58f2859bb0d6/ui/views/examples/combobox_example.cc
[modify] https://crrev.com/7ad8c0367ef9eb62e498cf9f7cea58f2859bb0d6/ui/views/examples/combobox_example.h

Project Member

Comment 4 by bugdroid1@chromium.org, Oct 23

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/7ad8c0367ef9eb62e498cf9f7cea58f2859bb0d6

commit 7ad8c0367ef9eb62e498cf9f7cea58f2859bb0d6
Author: Robert Liao <robliao@chromium.org>
Date: Tue Oct 23 23:45:43 2018

Split the Combobox Example Model into Three Models

This simplifies lifetime handling for these comboboxes.

BUG=897377

Change-Id: I19e8ed25f8e6b17012669ad7e810d33aa28d8ec8
Reviewed-on: https://chromium-review.googlesource.com/c/1295589
Reviewed-by: Scott Violet <sky@chromium.org>
Commit-Queue: Robert Liao <robliao@chromium.org>
Cr-Commit-Position: refs/heads/master@{#602174}
[modify] https://crrev.com/7ad8c0367ef9eb62e498cf9f7cea58f2859bb0d6/ui/views/examples/combobox_example.cc
[modify] https://crrev.com/7ad8c0367ef9eb62e498cf9f7cea58f2859bb0d6/ui/views/examples/combobox_example.h

Labels: Hotlist-DesktopUIConsider
Labels: Group-Platform
Labels: Hotlist-Polish
Labels: -Hotlist-DesktopUIConsider Hotlist-DesktopUITriaged
Labels: Hotlist-DesktopUIChecked Hotlist-DesktopUIValid
***UI Mass Triage***

Since work is in progress, adding appropriate labels.
Labels: M-73 Target-73

Sign in to add a comment