Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(175)

Issue 368323002: Virtual Keyboard: Update insets on change to window bounds. (Closed)

Created:
6 years, 5 months ago by kevers
Modified:
6 years, 5 months ago
Reviewers:
bshe
CC:
chromium-reviews
Project:
chromium
Visibility:
Public.

Description

Update insets on change to window bounds. In overscroll mode, any window with web contents that overlaps the virtual keyboard has insets in order to facilitate scrolling to the bottom of the document. These insets are updated whenever the keyboard is shown or hidden. This patch adds another update in the event that a window moves while the keyboard is visible. This case can occur after a screen rotation while the keyboard is shown. BUG=391337 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=283873

Patch Set 1 #

Patch Set 2 : #

Total comments: 8

Patch Set 3 : Fix nits. #

Patch Set 4 : Address feedback. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+88 lines, -4 lines) Patch
M ui/keyboard/keyboard_controller.h View 3 chunks +12 lines, -0 lines 0 comments Download
M ui/keyboard/keyboard_controller.cc View 1 2 3 8 chunks +76 lines, -4 lines 0 comments Download

Messages

Total messages: 6 (0 generated)
kevers
Hi Biao, Can you please take a look at this CL.
6 years, 5 months ago (2014-07-03 20:55:31 UTC) #1
bshe
lgtm I am not familiar with RWHV related code. It looks right to me but ...
6 years, 5 months ago (2014-07-04 13:03:57 UTC) #2
kevers
The CQ bit was checked by kevers@chromium.org
6 years, 5 months ago (2014-07-17 20:04:15 UTC) #3
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/kevers@chromium.org/368323002/60001
6 years, 5 months ago (2014-07-17 20:06:17 UTC) #4
commit-bot: I haz the power
Change committed as 283873
6 years, 5 months ago (2014-07-17 21:12:45 UTC) #5
kevers
6 years, 5 months ago (2014-07-18 14:06:23 UTC) #6
Message was sent while issue was closed.
Whoops.  Neglected to submit my earlier comments.

https://codereview.chromium.org/368323002/diff/20001/ui/keyboard/keyboard_con...
File ui/keyboard/keyboard_controller.cc (right):

https://codereview.chromium.org/368323002/diff/20001/ui/keyboard/keyboard_con...
ui/keyboard/keyboard_controller.cc:409: proxy_->HasKeyboardWindow() &&
proxy_->GetKeyboardWindow()->IsVisible();
On 2014/07/04 13:03:57, bshe wrote:
> nit: Do you need HasKeyboardWindow? It should always be true after you call
> GetKeyboardWindow above.

Done.

https://codereview.chromium.org/368323002/diff/20001/ui/keyboard/keyboard_con...
ui/keyboard/keyboard_controller.cc:423: view->SetInsets(gfx::Insets(0, 0, 0,
0));
On 2014/07/04 13:03:57, bshe wrote:
> nit: probably gfx::Insets()?

Done.

https://codereview.chromium.org/368323002/diff/20001/ui/keyboard/keyboard_con...
ui/keyboard/keyboard_controller.cc:529: while(window->parent() &&
window->parent()->id() < 0) {
On 2014/07/04 13:03:57, bshe wrote:
> nit: do you mind to add a comment on why do we check "id < 0"? Or maybe add an
> anonymous function since this while loop doesn't depend on KeyboardController
> and is used in more than one place.

Done.

https://codereview.chromium.org/368323002/diff/20001/ui/keyboard/keyboard_con...
ui/keyboard/keyboard_controller.cc:540: if (window &&
window->HasObserver(window_bounds_observer_.get()))
On 2014/07/04 13:03:57, bshe wrote:
> nit: you probably dont need to check if window is null in this if check or you
> should probably check it before the while loop.

Done.

Powered by Google App Engine
This is Rietveld 408576698