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

Issue 431573003: Fix views::WebView focus for Print Preview and other web dialogs. (Closed)

Created:
6 years, 4 months ago by msw
Modified:
6 years, 4 months ago
CC:
chromium-reviews, creis+watch_chromium.org, tfarina, nasko+codewatch_chromium.org, jam, darin-cc_chromium.org, miu+watch_chromium.org
Visibility:
Public.

Description

Fix views::WebView focus for Print Preview and other web dialogs. Focus the dialog's WebView when its WebContents is focused. Use a FocusChangeObserver to assist with this task. BrowserView does this for its WebViews by overriding: WebContentsDelegate::WebContentsFocused TODO: Cleanup the WebView/WebContents/etc. focus pattern... (See Ben's WebView::OnWebContentsFocused TODO) BUG=368691 TEST=Focusing between the omnibox and print preview dialogs works correctly (the omnibox loses focus, closes any dropdowns, doesn't show cursor/selection). R=ben@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=287082

Patch Set 1 #

Patch Set 2 : Focus the WebContents in WebContentsViewAura instead of WebDialogWebContentsDelegate. #

Patch Set 3 : Use a FocusChangeObserver to assist constrained web dialogs. #

Total comments: 2

Patch Set 4 : Use aura::Window* instead of gfx::NativeView. #

Patch Set 5 : Add missing OVERRIDE keyword. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+54 lines, -0 lines) Patch
M chrome/browser/ui/views/constrained_web_dialog_delegate_views.cc View 1 2 3 4 4 chunks +54 lines, -0 lines 0 comments Download

Messages

Total messages: 16 (0 generated)
msw
Hey Ben, please take a look, thanks! I addressed your earlier comments from: https://codereview.chromium.org/418093005/#msg9 You ...
6 years, 4 months ago (2014-07-31 16:42:43 UTC) #1
Ben Goodger (Google)
This is probably fine for this instance. If you wanted to make it more generic ...
6 years, 4 months ago (2014-07-31 18:20:15 UTC) #2
Ben Goodger (Google)
lgtm
6 years, 4 months ago (2014-07-31 18:20:20 UTC) #3
msw
I'll leave generalization for follow-up; landing! https://codereview.chromium.org/431573003/diff/80001/chrome/browser/ui/views/constrained_web_dialog_delegate_views.cc File chrome/browser/ui/views/constrained_web_dialog_delegate_views.cc (right): https://codereview.chromium.org/431573003/diff/80001/chrome/browser/ui/views/constrained_web_dialog_delegate_views.cc#newcode100 chrome/browser/ui/views/constrained_web_dialog_delegate_views.cc:100: gfx::NativeView native_view_; On ...
6 years, 4 months ago (2014-07-31 18:35:14 UTC) #4
msw
The CQ bit was checked by msw@chromium.org
6 years, 4 months ago (2014-07-31 18:35:23 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/msw@chromium.org/431573003/100001
6 years, 4 months ago (2014-07-31 18:36:07 UTC) #6
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: linux_gpu on tryserver.chromium.gpu ...
6 years, 4 months ago (2014-07-31 22:38:55 UTC) #7
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 4 months ago (2014-07-31 22:48:51 UTC) #8
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_chromeos_rel on tryserver.chromium.linux (http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_chromeos_rel/builds/2047) linux_chromium_rel_swarming on tryserver.chromium.linux (http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_rel_swarming/builds/2022)
6 years, 4 months ago (2014-07-31 22:48:52 UTC) #9
msw
The CQ bit was checked by msw@chromium.org
6 years, 4 months ago (2014-08-01 00:15:08 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/msw@chromium.org/431573003/120001
6 years, 4 months ago (2014-08-01 00:16:51 UTC) #11
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: win_chromium_x64_rel on tryserver.chromium.win ...
6 years, 4 months ago (2014-08-01 14:41:05 UTC) #12
miu
msw: Have you tested that this change doesn't break fullscreen focus behavior (both Flash and ...
6 years, 4 months ago (2014-08-01 17:58:27 UTC) #13
msw
On 2014/08/01 17:58:27, miu wrote: > msw: Have you tested that this change doesn't break ...
6 years, 4 months ago (2014-08-01 18:17:49 UTC) #14
miu
On 2014/08/01 18:17:49, msw wrote: > On 2014/08/01 17:58:27, miu wrote: > > msw: Have ...
6 years, 4 months ago (2014-08-01 18:47:22 UTC) #15
commit-bot: I haz the power
6 years, 4 months ago (2014-08-01 20:39:20 UTC) #16
Message was sent while issue was closed.
Change committed as 287082

Powered by Google App Engine
This is Rietveld 408576698