|
|
DescriptionOnly exclude workarea from touch-exploration with active shell-surface
The previous behavior disabled touch-exploration altogether which
made the shelf un-explorable. This adds support for an exclusion
region in touch_exploration_controller. When a shell-surface is
active, that region gets set to the workarea (area above shelf and
below chromevox banner) so that the shelf remains explorable.
BUG=649524
TEST=unit-test for exclude-area support. manual for shell-surface
behavior.
Committed: https://crrev.com/998c256b3f707cdecdab750239f70b7e893747a1
Cr-Commit-Position: refs/heads/master@{#426299}
Patch Set 1 #
Total comments: 6
Patch Set 2 : CL comments #
Total comments: 5
Patch Set 3 : CL comments #
Total comments: 4
Patch Set 4 : added comment #
Total comments: 3
Patch Set 5 : cr comments #Patch Set 6 : resolved merge issues in unittest #
Messages
Total messages: 52 (31 generated)
The CQ bit was checked by erosky@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
erosky@chromium.org changed reviewers: + dmazzoni@chromium.org, oshima@chromium.org, reveman@chromium.org, sky@chromium.org
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
components/exo lgtm
https://codereview.chromium.org/2378773011/diff/1/ash/ash_touch_exploration_m... File ash/ash_touch_exploration_manager_chromeos.cc (right): https://codereview.chromium.org/2378773011/diff/1/ash/ash_touch_exploration_m... ash/ash_touch_exploration_manager_chromeos.cc:31: Shell::GetInstance()->display_manager()->AddObserver(this); Use WmShell::Get()->Add/RemoveDisplayObserver (that'll work with mash too). https://codereview.chromium.org/2378773011/diff/1/ash/ash_touch_exploration_m... ash/ash_touch_exploration_manager_chromeos.cc:100: if (ash::GetRootWindowSettings(root_window)->display_id == display.id()) { no {} https://codereview.chromium.org/2378773011/diff/1/ash/ash_touch_exploration_m... ash/ash_touch_exploration_manager_chromeos.cc:134: touch_exploration_controller_.reset(new ui::TouchExplorationController( Use MakeUnique (see threads on chromium-dev).
https://codereview.chromium.org/2378773011/diff/1/ash/ash_touch_exploration_m... File ash/ash_touch_exploration_manager_chromeos.cc (right): https://codereview.chromium.org/2378773011/diff/1/ash/ash_touch_exploration_m... ash/ash_touch_exploration_manager_chromeos.cc:31: Shell::GetInstance()->display_manager()->AddObserver(this); On 2016/09/30 15:39:58, sky wrote: > Use WmShell::Get()->Add/RemoveDisplayObserver (that'll work with mash too). WmDisplayObserver::OnDisplayConfigurationChanged takes no arguments. Is OnDisplayConfigurationChanged() called if any display changes? If so, how do I find out which display has changed? https://codereview.chromium.org/2378773011/diff/1/ash/ash_touch_exploration_m... ash/ash_touch_exploration_manager_chromeos.cc:100: if (ash::GetRootWindowSettings(root_window)->display_id == display.id()) { On 2016/09/30 15:39:58, sky wrote: > no {} Done. https://codereview.chromium.org/2378773011/diff/1/ash/ash_touch_exploration_m... ash/ash_touch_exploration_manager_chromeos.cc:134: touch_exploration_controller_.reset(new ui::TouchExplorationController( On 2016/09/30 15:39:58, sky wrote: > Use MakeUnique (see threads on chromium-dev). Done.
Patchset #2 (id:20001) has been deleted
The CQ bit was checked by erosky@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
https://codereview.chromium.org/2378773011/diff/40001/ash/ash_touch_explorati... File ash/ash_touch_exploration_manager_chromeos.h (right): https://codereview.chromium.org/2378773011/diff/40001/ash/ash_touch_explorati... ash/ash_touch_exploration_manager_chromeos.h:52: void OnDisplayConfigurationChanged() override; can you use display::DisplayObserver instead?
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
https://codereview.chromium.org/2378773011/diff/40001/ash/ash_touch_explorati... File ash/ash_touch_exploration_manager_chromeos.h (right): https://codereview.chromium.org/2378773011/diff/40001/ash/ash_touch_explorati... ash/ash_touch_exploration_manager_chromeos.h:52: void OnDisplayConfigurationChanged() override; On 2016/09/30 20:59:59, oshima wrote: > can you use display::DisplayObserver instead? I was just asked to switch from that to be forward-compatible with WmShell. What is the difference here (besides not know which display changed in this one)?
https://codereview.chromium.org/2378773011/diff/40001/ash/ash_touch_explorati... File ash/ash_touch_exploration_manager_chromeos.h (right): https://codereview.chromium.org/2378773011/diff/40001/ash/ash_touch_explorati... ash/ash_touch_exploration_manager_chromeos.h:52: void OnDisplayConfigurationChanged() override; On 2016/09/30 22:39:55, erosky wrote: > On 2016/09/30 20:59:59, oshima wrote: > > can you use display::DisplayObserver instead? > > I was just asked to switch from that to be forward-compatible with WmShell. What > is the difference here (besides not know which display changed in this one)? display::DisplayObserver is a platform independent API, while WmDisplayObserve is used to bring up ash desktop environment.
https://codereview.chromium.org/2378773011/diff/40001/ash/ash_touch_explorati... File ash/ash_touch_exploration_manager_chromeos.h (right): https://codereview.chromium.org/2378773011/diff/40001/ash/ash_touch_explorati... ash/ash_touch_exploration_manager_chromeos.h:52: void OnDisplayConfigurationChanged() override; On 2016/09/30 23:48:15, oshima wrote: > On 2016/09/30 22:39:55, erosky wrote: > > On 2016/09/30 20:59:59, oshima wrote: > > > can you use display::DisplayObserver instead? > > > > I was just asked to switch from that to be forward-compatible with WmShell. > What > > is the difference here (besides not know which display changed in this one)? > > display::DisplayObserver is a platform independent API, while WmDisplayObserve > is used to bring up ash desktop environment. Sorry I wasn't clear enough. Please use gfx::Screen::GetScreen()->Add/RemoveObserver instead of using adding/removing directly to/from DisplayManager as it's ash internal.
https://codereview.chromium.org/2378773011/diff/40001/ash/ash_touch_explorati... File ash/ash_touch_exploration_manager_chromeos.h (right): https://codereview.chromium.org/2378773011/diff/40001/ash/ash_touch_explorati... ash/ash_touch_exploration_manager_chromeos.h:52: void OnDisplayConfigurationChanged() override; On 2016/10/01 00:07:44, oshima wrote: > On 2016/09/30 23:48:15, oshima wrote: > > On 2016/09/30 22:39:55, erosky wrote: > > > On 2016/09/30 20:59:59, oshima wrote: > > > > can you use display::DisplayObserver instead? > > > > > > I was just asked to switch from that to be forward-compatible with WmShell. > > What > > > is the difference here (besides not know which display changed in this one)? > > > > display::DisplayObserver is a platform independent API, while WmDisplayObserve > > is used to bring up ash desktop environment. > > Sorry I wasn't clear enough. > > Please use gfx::Screen::GetScreen()->Add/RemoveObserver instead of using > adding/removing directly to/from DisplayManager as it's ash internal. Done.
The CQ bit was checked by erosky@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
https://codereview.chromium.org/2378773011/diff/60001/ui/chromeos/touch_explo... File ui/chromeos/touch_exploration_controller.cc (right): https://codereview.chromium.org/2378773011/diff/60001/ui/chromeos/touch_explo... ui/chromeos/touch_exploration_controller.cc:81: root_window_->GetHost()->ConvertPointFromNativeScreen(&location); This looks wrong. Does this work when you rotate the screen (ctrl-alt-reload)? Does this event have a target? If so, you should be able to convert using Window::ConvertPointToTarget(event_target, root_window_, &location); https://codereview.chromium.org/2378773011/diff/60001/ui/chromeos/touch_explo... File ui/chromeos/touch_exploration_controller.h (right): https://codereview.chromium.org/2378773011/diff/60001/ui/chromeos/touch_explo... ui/chromeos/touch_exploration_controller.h:192: void SetExcludeBounds(const gfx::Rect& bounds); please document that this is in screen coordinates.
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: linux_chromium_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_...)
On 2016/09/30 22:39:56, erosky wrote: > https://codereview.chromium.org/2378773011/diff/40001/ash/ash_touch_explorati... > File ash/ash_touch_exploration_manager_chromeos.h (right): > > https://codereview.chromium.org/2378773011/diff/40001/ash/ash_touch_explorati... > ash/ash_touch_exploration_manager_chromeos.h:52: void > OnDisplayConfigurationChanged() override; > On 2016/09/30 20:59:59, oshima wrote: > > can you use display::DisplayObserver instead? > > I was just asked to switch from that to be forward-compatible with WmShell. What > is the difference here (besides not know which display changed in this one)? As Oshima commented, using DisplayObserver is fine as well.
https://codereview.chromium.org/2378773011/diff/60001/ui/chromeos/touch_explo... File ui/chromeos/touch_exploration_controller.cc (right): https://codereview.chromium.org/2378773011/diff/60001/ui/chromeos/touch_explo... ui/chromeos/touch_exploration_controller.cc:81: root_window_->GetHost()->ConvertPointFromNativeScreen(&location); On 2016/10/01 01:15:14, oshima wrote: > This looks wrong. Does this work when you rotate the screen (ctrl-alt-reload)? > > Does this event have a target? If so, you should be able to convert > using > > Window::ConvertPointToTarget(event_target, > root_window_, > &location); No target yet here. This conversion is specifically to handle those changes and it works when I try it. Would you prefer it if we make event_bounds_ native and then convert from in callers or is it ok as is? https://codereview.chromium.org/2378773011/diff/60001/ui/chromeos/touch_explo... File ui/chromeos/touch_exploration_controller.h (right): https://codereview.chromium.org/2378773011/diff/60001/ui/chromeos/touch_explo... ui/chromeos/touch_exploration_controller.h:192: void SetExcludeBounds(const gfx::Rect& bounds); On 2016/10/01 01:15:15, oshima wrote: > please document that this is in screen coordinates. Done.
The CQ bit was checked by erosky@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
lgtm Nice job on the tests and explaining the logic for continuing to process cancel and release events. https://codereview.chromium.org/2378773011/diff/80001/ui/chromeos/touch_explo... File ui/chromeos/touch_exploration_controller.cc (right): https://codereview.chromium.org/2378773011/diff/80001/ui/chromeos/touch_explo... ui/chromeos/touch_exploration_controller.cc:130: // or if an additional press occurred within the exclusion bounds. Thanks for updating this comment. Good catch.
https://codereview.chromium.org/2378773011/diff/80001/ash/ash_touch_explorati... File ash/ash_touch_exploration_manager_chromeos.cc (right): https://codereview.chromium.org/2378773011/diff/80001/ash/ash_touch_explorati... ash/ash_touch_exploration_manager_chromeos.cc:140: const gfx::Rect& work_area = ash::Shell::GetInstance() root_window_controller_->wm_root_window_controller()->GetRootWindow()->GetDisplayNearestWindow().work_area(); The reason for doing this vs display_manager() is this code needs to be ported to ash/common, and ash/common can't use display_manager.
The CQ bit was checked by erosky@chromium.org to run a CQ dry run
https://codereview.chromium.org/2378773011/diff/80001/ash/ash_touch_explorati... File ash/ash_touch_exploration_manager_chromeos.cc (right): https://codereview.chromium.org/2378773011/diff/80001/ash/ash_touch_explorati... ash/ash_touch_exploration_manager_chromeos.cc:140: const gfx::Rect& work_area = ash::Shell::GetInstance() On 2016/10/06 15:56:19, sky wrote: > root_window_controller_->wm_root_window_controller()->GetRootWindow()->GetDisplayNearestWindow().work_area(); > > The reason for doing this vs display_manager() is this code needs to be ported > to ash/common, and ash/common can't use display_manager. Done. Thanks for explaining!
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: linux_chromium_chromeos_compile_dbg_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_...)
The CQ bit was checked by erosky@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
LGTM
The CQ bit was checked by erosky@chromium.org
The patchset sent to the CQ was uploaded after l-g-t-m from reveman@chromium.org, dmazzoni@chromium.org Link to the patchset: https://codereview.chromium.org/2378773011/#ps120001 (title: "resolved merge issues in unittest")
The CQ bit was unchecked by erosky@chromium.org
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was checked by erosky@chromium.org
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Message was sent while issue was closed.
Committed patchset #6 (id:120001)
Message was sent while issue was closed.
Description was changed from ========== Only exclude workarea from touch-exploration with active shell-surface The previous behavior disabled touch-exploration altogether which made the shelf un-explorable. This adds support for an exclusion region in touch_exploration_controller. When a shell-surface is active, that region gets set to the workarea (area above shelf and below chromevox banner) so that the shelf remains explorable. BUG=649524 TEST=unit-test for exclude-area support. manual for shell-surface behavior. ========== to ========== Only exclude workarea from touch-exploration with active shell-surface The previous behavior disabled touch-exploration altogether which made the shelf un-explorable. This adds support for an exclusion region in touch_exploration_controller. When a shell-surface is active, that region gets set to the workarea (area above shelf and below chromevox banner) so that the shelf remains explorable. BUG=649524 TEST=unit-test for exclude-area support. manual for shell-surface behavior. Committed: https://crrev.com/998c256b3f707cdecdab750239f70b7e893747a1 Cr-Commit-Position: refs/heads/master@{#426299} ==========
Message was sent while issue was closed.
Patchset 6 (id:??) landed as https://crrev.com/998c256b3f707cdecdab750239f70b7e893747a1 Cr-Commit-Position: refs/heads/master@{#426299} |