Project: chromium Issues People Development process History Sign in
New issue
Advanced search Search tips
Starred by 2 users
Status: Fixed
Owner:
Closed: Oct 2016
Cc:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 2
Type: Bug



Sign in to add a comment
Fake adding/removing displays with mash on Oxygen
Project Member Reported by kylec...@chromium.org, May 12 2016 Back to list
If we can somehow add/remove "displays" with mash running on Oxygen then it could be used to test out the display configuration code related to displays without using a device.

This will require some way to tell the mash process that it should add or remove X windows. Ideas include a separate X window, keyboard shortcuts, listening on a pipe, etc.
 
Another idea that came up is having the add/remove displays be part of the mus_ws DisplayController(?) interface. That way a small mojo app could hook into it and provide buttons or some other method to add/remove displays.
Labels: tadpole
proposal: mus::display::Configurator final name.

But yes: I concur with the idea: musws exposes a mus::display::Configurator interface and it provides an entry point to create/remove a display. The entry point does not necessarily succeed: some implementations may not implement the interface.


Labels: -Pri-3 Pri-2
Labels: screen
Owner: kylec...@chromium.org
Status: ass
Status: Assigned
Project Member Comment 7 by bugdroid1@chromium.org, Jul 27 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/bb8c2fedfb2bc06d3fb3666147e4d16781d9ebc5

commit bb8c2fedfb2bc06d3fb3666147e4d16781d9ebc5
Author: kylechar <kylechar@chromium.org>
Date: Wed Jul 27 18:14:53 2016

Add flag to launch two displays for mus+ash.

Add --multi-display flag to launch two displays when running mus+ash
under Ozone X11. This creates two 800x800 displays that are side by
side. The displays should appear fine but event targeting (and other
things) are broken. This patch is intended to allow testing and fix bugs
related to multiple displays.

Ideally, mash should use the same flags to setup multiple displays for
testing that ash contains right now. The code to parse the flag contents
is being refactored out of ash but cannot be used in //services/ui yet.

This patch also changes ViewportMetrics to store display bound instead
of just display size.

BUG= 611475 

Review-Url: https://codereview.chromium.org/2190633002
Cr-Commit-Position: refs/heads/master@{#408183}

[modify] https://crrev.com/bb8c2fedfb2bc06d3fb3666147e4d16781d9ebc5/services/ui/display/platform_screen_impl_ozone.cc
[modify] https://crrev.com/bb8c2fedfb2bc06d3fb3666147e4d16781d9ebc5/services/ui/ws/display.cc
[modify] https://crrev.com/bb8c2fedfb2bc06d3fb3666147e4d16781d9ebc5/services/ui/ws/frame_generator.cc
[modify] https://crrev.com/bb8c2fedfb2bc06d3fb3666147e4d16781d9ebc5/services/ui/ws/frame_generator_delegate.h
[modify] https://crrev.com/bb8c2fedfb2bc06d3fb3666147e4d16781d9ebc5/services/ui/ws/platform_display.cc
[modify] https://crrev.com/bb8c2fedfb2bc06d3fb3666147e4d16781d9ebc5/services/ui/ws/platform_display.h
[modify] https://crrev.com/bb8c2fedfb2bc06d3fb3666147e4d16781d9ebc5/services/ui/ws/test_utils.cc

Components: -MUS
Labels: -mus -tadpole -screen Proj-Mustash-Mus
Components: MUS
Project Member Comment 10 by bugdroid1@chromium.org, Sep 9 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/b39238a88385b5f0d7e93ff1195c9909e4d6c414

commit b39238a88385b5f0d7e93ff1195c9909e4d6c414
Author: kylechar <kylechar@chromium.org>
Date: Fri Sep 09 14:06:58 2016

Add mojom::DisplayController.

Add a new mojo interface mojom::DisplayController to allow privileged
clients to make changes to the display state. The initial interface
contains methods needed by mash to provide display state related
keyboard accelerators that exist in cash currently.

Have PlatformScreenOzone implement this new interface and provide mostly
stub implementations. Right now the interface isn't wired up so that
will happen in a subsequent CL.

Also adds PlatformScreen::GetInstance() so PlatformScreen doesn't need
to be passed so many places.

BUG= 611475 

Review-Url: https://codereview.chromium.org/2310133002
Cr-Commit-Position: refs/heads/master@{#417578}

[modify] https://crrev.com/b39238a88385b5f0d7e93ff1195c9909e4d6c414/services/ui/display/BUILD.gn
[add] https://crrev.com/b39238a88385b5f0d7e93ff1195c9909e4d6c414/services/ui/display/platform_screen.cc
[modify] https://crrev.com/b39238a88385b5f0d7e93ff1195c9909e4d6c414/services/ui/display/platform_screen.h
[modify] https://crrev.com/b39238a88385b5f0d7e93ff1195c9909e4d6c414/services/ui/display/platform_screen_delegate.h
[modify] https://crrev.com/b39238a88385b5f0d7e93ff1195c9909e4d6c414/services/ui/display/platform_screen_ozone.cc
[modify] https://crrev.com/b39238a88385b5f0d7e93ff1195c9909e4d6c414/services/ui/display/platform_screen_ozone.h
[modify] https://crrev.com/b39238a88385b5f0d7e93ff1195c9909e4d6c414/services/ui/display/platform_screen_ozone_unittests.cc
[modify] https://crrev.com/b39238a88385b5f0d7e93ff1195c9909e4d6c414/services/ui/display/platform_screen_stub.cc
[modify] https://crrev.com/b39238a88385b5f0d7e93ff1195c9909e4d6c414/services/ui/public/interfaces/display/BUILD.gn
[add] https://crrev.com/b39238a88385b5f0d7e93ff1195c9909e4d6c414/services/ui/public/interfaces/display/display_controller.mojom
[modify] https://crrev.com/b39238a88385b5f0d7e93ff1195c9909e4d6c414/services/ui/ws/display_manager.cc
[modify] https://crrev.com/b39238a88385b5f0d7e93ff1195c9909e4d6c414/services/ui/ws/display_manager.h
[modify] https://crrev.com/b39238a88385b5f0d7e93ff1195c9909e4d6c414/services/ui/ws/platform_display.cc
[modify] https://crrev.com/b39238a88385b5f0d7e93ff1195c9909e4d6c414/services/ui/ws/platform_display.h
[modify] https://crrev.com/b39238a88385b5f0d7e93ff1195c9909e4d6c414/services/ui/ws/platform_display_init_params.h
[modify] https://crrev.com/b39238a88385b5f0d7e93ff1195c9909e4d6c414/services/ui/ws/window_manager_state.cc

Project Member Comment 11 by bugdroid1@chromium.org, Sep 13 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/80cc8b1af214a4caba50a0a8794622b2103a2129

commit 80cc8b1af214a4caba50a0a8794622b2103a2129
Author: kylechar <kylechar@chromium.org>
Date: Tue Sep 13 15:21:00 2016

Connect mojom::DisplayController from ash to ui.

Connect mojom::DisplayController and the debug keyboard accelerator to
add or remove a display. The accelerator is triggered in mojo:ash and
the display change happens in mojo:ui. Remove the IPC response as it's
unneeded.

The actual adding/removing of a display isn't fully working yet but the
accelerator and Mojo IPC works as intended.

BUG= 611475 

Review-Url: https://codereview.chromium.org/2323393003
Cr-Commit-Position: refs/heads/master@{#418254}

[modify] https://crrev.com/80cc8b1af214a4caba50a0a8794622b2103a2129/ash/mus/BUILD.gn
[modify] https://crrev.com/80cc8b1af214a4caba50a0a8794622b2103a2129/ash/mus/accelerators/accelerator_controller_delegate_mus.cc
[modify] https://crrev.com/80cc8b1af214a4caba50a0a8794622b2103a2129/ash/mus/manifest.json
[modify] https://crrev.com/80cc8b1af214a4caba50a0a8794622b2103a2129/services/ui/display/BUILD.gn
[modify] https://crrev.com/80cc8b1af214a4caba50a0a8794622b2103a2129/services/ui/display/platform_screen.h
[modify] https://crrev.com/80cc8b1af214a4caba50a0a8794622b2103a2129/services/ui/display/platform_screen_ozone.cc
[modify] https://crrev.com/80cc8b1af214a4caba50a0a8794622b2103a2129/services/ui/display/platform_screen_ozone.h
[modify] https://crrev.com/80cc8b1af214a4caba50a0a8794622b2103a2129/services/ui/display/platform_screen_stub.cc
[modify] https://crrev.com/80cc8b1af214a4caba50a0a8794622b2103a2129/services/ui/display/platform_screen_stub.h
[modify] https://crrev.com/80cc8b1af214a4caba50a0a8794622b2103a2129/services/ui/public/interfaces/display/display_controller.mojom
[modify] https://crrev.com/80cc8b1af214a4caba50a0a8794622b2103a2129/services/ui/service.cc
[modify] https://crrev.com/80cc8b1af214a4caba50a0a8794622b2103a2129/services/ui/service.h

Components: -MUS
Labels: mustash-display
Project Member Comment 13 by bugdroid1@chromium.org, Sep 19 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/b77b33d434ddf9fbb31193c559d9907df2020db1

commit b77b33d434ddf9fbb31193c559d9907df2020db1
Author: kylechar <kylechar@chromium.org>
Date: Mon Sep 19 18:12:04 2016

Add FakeDisplayDelegate for off device usage.

Add a NativeDisplayDelegate implementation that handles fake displays.
Fake displays mimic physical displays when running off device. Allow
user the specify initial display state with command line flag and
provide API to programatically change display state at runtime.

Except for changing the attached displays other NativeDisplayDelegate
functionality is a noop.

Add FakeDisplaySnapshot to store the fake display state. For now it's
very simple but I intend to add a builder to make it easy to construct
more complex displays.

Add FakeDisplayController interface and method on NativeDisplayDelegate
to get one. This interface will allow changing display state at runtime
if implemented. Only FakeDisplayDelegate will implement it for now.

Fake isn't the best term to describe "not real" displays but there are
already virtual displays implemented for casting.

BUG= 611475 

Review-Url: https://codereview.chromium.org/2324163002
Cr-Commit-Position: refs/heads/master@{#419505}

[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/services/ui/display/platform_screen_ozone.cc
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/services/ui/display/platform_screen_ozone.h
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/services/ui/display/platform_screen_ozone_unittests.cc
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/display/BUILD.gn
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/display/chromeos/test/test_native_display_delegate.cc
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/display/chromeos/test/test_native_display_delegate.h
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/display/chromeos/x11/native_display_delegate_x11.cc
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/display/chromeos/x11/native_display_delegate_x11.h
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/display/display_switches.cc
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/display/display_switches.h
[add] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/display/fake_display_delegate.cc
[add] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/display/fake_display_delegate.h
[add] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/display/fake_display_snapshot.cc
[add] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/display/fake_display_snapshot.h
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/display/types/BUILD.gn
[add] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/display/types/fake_display_controller.h
[add] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/display/types/native_display_delegate.cc
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/display/types/native_display_delegate.h
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/ozone/DEPS
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/ozone/common/native_display_delegate_ozone.cc
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/ozone/common/native_display_delegate_ozone.h
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/ozone/platform/drm/host/drm_native_display_delegate.cc
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/ozone/platform/drm/host/drm_native_display_delegate.h
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/ozone/platform/headless/BUILD.gn
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/ozone/platform/headless/ozone_platform_headless.cc
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/ozone/platform/x11/BUILD.gn
[delete] https://crrev.com/6956f50782b54ec41b189d3fd1fbda5212a1b443/ui/ozone/platform/x11/native_display_delegate_ozone_x11.cc
[delete] https://crrev.com/6956f50782b54ec41b189d3fd1fbda5212a1b443/ui/ozone/platform/x11/native_display_delegate_ozone_x11.h
[modify] https://crrev.com/b77b33d434ddf9fbb31193c559d9907df2020db1/ui/ozone/platform/x11/ozone_platform_x11.cc

Project Member Comment 14 by bugdroid1@chromium.org, Sep 20 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/e1436a91ec2c8c557936dbabc3e594b8402c8b97

commit e1436a91ec2c8c557936dbabc3e594b8402c8b97
Author: kylechar <kylechar@chromium.org>
Date: Tue Sep 20 23:04:09 2016

Add FakeDisplaySnapshot builder and related changes.

Adds a builder for FakeDisplaySnapshot to allow us to easily construct
the display snapshots. Will update more tests to use this functionality
in a follow up CL.

Update platform_screen_ozone_unittests.cc to use FakeDisplaySnapshot
instead of DisplaySnapshotVirtual.

Update --screen-config to take display DPI and able to start without any
initial displays.

BUG= 611475 

Review-Url: https://codereview.chromium.org/2340383002
Cr-Commit-Position: refs/heads/master@{#419885}

[modify] https://crrev.com/e1436a91ec2c8c557936dbabc3e594b8402c8b97/services/ui/display/platform_screen_ozone_unittests.cc
[modify] https://crrev.com/e1436a91ec2c8c557936dbabc3e594b8402c8b97/ui/display/fake_display_delegate.cc
[modify] https://crrev.com/e1436a91ec2c8c557936dbabc3e594b8402c8b97/ui/display/fake_display_delegate.h
[modify] https://crrev.com/e1436a91ec2c8c557936dbabc3e594b8402c8b97/ui/display/fake_display_snapshot.cc
[modify] https://crrev.com/e1436a91ec2c8c557936dbabc3e594b8402c8b97/ui/display/fake_display_snapshot.h
[modify] https://crrev.com/e1436a91ec2c8c557936dbabc3e594b8402c8b97/ui/display/types/fake_display_controller.h

Project Member Comment 15 by bugdroid1@chromium.org, Oct 5 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/170de2963d3e977eb340fc5e496b3624047018e9

commit 170de2963d3e977eb340fc5e496b3624047018e9
Author: tonikitoo <tonikitoo@igalia.com>
Date: Wed Oct 05 19:39:41 2016

[ozone/wayland] Use FakeDisplayDelegate in order to make "off device" launch work

[1] introduced the "fake display" concept, updating OzonePlatformHeadless
and OzonePlatformX11 to use it, but not OzonePlatformWayland.
As a result, "chrome --mash --ozone-platform=wayland" fails to launch.

This CL fixes it by returning a FakeDisplayDelegate instance
in OzonePlatformWayland::CreateNativeDisplayDelegate, similarly
to other off-device capable ozone platforms.

[1] https://codereview.chromium.org/2324163002

BUG= 611475 

Review-Url: https://codereview.chromium.org/2389053003
Cr-Commit-Position: refs/heads/master@{#423254}

[modify] https://crrev.com/170de2963d3e977eb340fc5e496b3624047018e9/ui/ozone/platform/wayland/ozone_platform_wayland.cc

Project Member Comment 16 by bugdroid1@chromium.org, Oct 13 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/3cabb1432a49769f618d868b218ad119709560d7

commit 3cabb1432a49769f618d868b218ad119709560d7
Author: kylechar <kylechar@chromium.org>
Date: Thu Oct 13 18:03:32 2016

Add more options to --screen-config flag.

Allow the user to specify more options for each DisplaySnapshot created
by FakeDisplayDelegate. Alternate resolutions, different refresh rates
and various option toggles are added.

Add tests for FakeDisplaySnapshot that verify the display specification
string parsing.

BUG= 611475 

Review-Url: https://codereview.chromium.org/2395873002
Cr-Commit-Position: refs/heads/master@{#425084}

[modify] https://crrev.com/3cabb1432a49769f618d868b218ad119709560d7/ui/display/BUILD.gn
[modify] https://crrev.com/3cabb1432a49769f618d868b218ad119709560d7/ui/display/DEPS
[modify] https://crrev.com/3cabb1432a49769f618d868b218ad119709560d7/ui/display/fake_display_delegate.cc
[modify] https://crrev.com/3cabb1432a49769f618d868b218ad119709560d7/ui/display/fake_display_delegate.h
[modify] https://crrev.com/3cabb1432a49769f618d868b218ad119709560d7/ui/display/fake_display_snapshot.cc
[modify] https://crrev.com/3cabb1432a49769f618d868b218ad119709560d7/ui/display/fake_display_snapshot.h
[add] https://crrev.com/3cabb1432a49769f618d868b218ad119709560d7/ui/display/fake_display_snapshot_unittests.cc
[add] https://crrev.com/3cabb1432a49769f618d868b218ad119709560d7/ui/display/test/display_matchers.cc
[add] https://crrev.com/3cabb1432a49769f618d868b218ad119709560d7/ui/display/test/display_matchers.h
[modify] https://crrev.com/3cabb1432a49769f618d868b218ad119709560d7/ui/display/types/display_mode.cc
[modify] https://crrev.com/3cabb1432a49769f618d868b218ad119709560d7/ui/display/types/display_mode.h
[modify] https://crrev.com/3cabb1432a49769f618d868b218ad119709560d7/ui/display/types/display_snapshot.cc
[modify] https://crrev.com/3cabb1432a49769f618d868b218ad119709560d7/ui/display/types/display_snapshot.h

Status: Fixed
Project Member Comment 18 by bugdroid1@chromium.org, Oct 27 2016
Labels: merge-merged-2840
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/170de2963d3e977eb340fc5e496b3624047018e9

commit 170de2963d3e977eb340fc5e496b3624047018e9
Author: tonikitoo <tonikitoo@igalia.com>
Date: Wed Oct 05 19:39:41 2016

[ozone/wayland] Use FakeDisplayDelegate in order to make "off device" launch work

[1] introduced the "fake display" concept, updating OzonePlatformHeadless
and OzonePlatformX11 to use it, but not OzonePlatformWayland.
As a result, "chrome --mash --ozone-platform=wayland" fails to launch.

This CL fixes it by returning a FakeDisplayDelegate instance
in OzonePlatformWayland::CreateNativeDisplayDelegate, similarly
to other off-device capable ozone platforms.

[1] https://codereview.chromium.org/2324163002

BUG= 611475 

Review-Url: https://codereview.chromium.org/2389053003
Cr-Commit-Position: refs/heads/master@{#423254}

[modify] https://crrev.com/170de2963d3e977eb340fc5e496b3624047018e9/ui/ozone/platform/wayland/ozone_platform_wayland.cc

Comment 19 by dimu@google.com, Nov 4 2016
Labels: -merge-merged-2840
[Automated comment] removing mislabelled merge-merged-2840
Sign in to add a comment