Commit 5c6ed9e6 authored by Darren Shen's avatar Darren Shen Committed by Commit Bot

[VK] Simplify KeyboardController::SetDraggableArea.

|SetDraggableArea| returns checks if the container behavior is null,
but KeyboardController always has a container behavior (initialised in
the constructor).

This patch removes the container behavior null check.

Bug: 845780
Change-Id: Iaa21bd8179a7fb88a0dd277f4888ae778c624d99
Reviewed-on: https://chromium-review.googlesource.com/1069950
Commit-Queue: Darren Shen <shend@chromium.org>
Reviewed-by: default avatarYuichiro Hanada <yhanada@chromium.org>
Cr-Commit-Position: refs/heads/master@{#560995}
parent 56a6e88e
......@@ -848,10 +848,7 @@ void KeyboardController::SetContainerType(
}
bool KeyboardController::SetDraggableArea(const gfx::Rect& rect) {
if (container_behavior_) {
return container_behavior_->SetDraggableArea(rect);
}
return false;
return container_behavior_->SetDraggableArea(rect);
}
bool KeyboardController::DisplayVirtualKeyboard() {
......
......@@ -190,7 +190,7 @@ class KEYBOARD_EXPORT KeyboardController
base::Optional<gfx::Rect> target_bounds,
base::OnceCallback<void(bool)> callback);
// Sets floating keyboard drggable rect.
// Sets floating keyboard draggable rect.
bool SetDraggableArea(const gfx::Rect& rect);
void MoveToDisplayWithTransition(display::Display display,
......
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