Commit 8f1c1ed6 authored by Alex Newcomer's avatar Alex Newcomer Committed by Commit Bot

cros: Don't process events on app icons while the shelf is hidden.

2 bug fixes.
1. Fix swiping up on the auto-hidden shelf from interacting with
   ShelfButtons.
2. Prevent users from accidentally activating ShelfButtons by tapping
   the bottom of the screen while the shelf is autohidden.

Bug: 872854
Change-Id: I5376eac2b7090b6109ad28cb0e9dfc4a748343e6
Reviewed-on: https://chromium-review.googlesource.com/1198522
Commit-Queue: Alex Newcomer <newcomer@chromium.org>
Reviewed-by: default avatarSammie Quon <sammiequon@chromium.org>
Reviewed-by: default avatarXiyuan Xia <xiyuan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#588101}
parent 2ea45c06
......@@ -404,6 +404,13 @@ bool ShelfLayoutManager::ProcessGestureEvent(
if (gesture_drag_status_ != GESTURE_DRAG_IN_PROGRESS &&
gesture_drag_status_ != GESTURE_DRAG_APPLIST_IN_PROGRESS) {
if ((shelf_->GetVisibilityState() == SHELF_AUTO_HIDE &&
shelf_->GetAutoHideState() == SHELF_AUTO_HIDE_HIDDEN) ||
shelf_->GetVisibilityState() == SHELF_HIDDEN) {
// Do not allow children to handle events while the shelf is hidden.
return true;
}
return false;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment