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

Issue 2766053002: [refactor] Fix autofill features for payments when the form is inside an OOPIF (Closed)

Created:
3 years, 9 months ago by EhsanK
Modified:
3 years, 8 months ago
CC:
chromium-reviews, mlamouri+watch-content_chromium.org, jam, creis+watch_chromium.org, rouslan+autofill_chromium.org, rogerm+autofillwatch_chromium.org, sebsg+autofillwatch_chromium.org, nasko+codewatch_chromium.org, browser-components-watch_chromium.org, mathp+autofillwatch_chromium.org, darin-cc_chromium.org, vabr+watchlistautofill_chromium.org, estade+watch_chromium.org, kolos1, site-isolation-reviews_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

[refactor] Fix autofill features for payments when the form is inside an OOPIF Currently, clicking into a credit card information <input> field inside an OOPIF does not pop up the autofill window. The root cause is simply because the call to RenderWidget::FocusChangeComplete() is dropped for OOPIFs. Moreover, for the main frame, this call is forwarded throught RenderViewObserver calls to the corresponding PageClickTracker. On the other hand, both PageClickTracker and AutofillAgent use a internal Legacy class to observe RenderView for updates in element focus and mouse down down inside a node. This is unfortunate given that the actual classes are RenderFrameObservers. This CL will make the following changes: A) FocusChangeComplete: This call is now forwarded to the observers of the RenderWidget which are RenderFrames. They will then notify their own observers, e.g., AutofillAgent and PageClickTracker. In line with this, the Legacy classes inside these classes will be removed. Also, there is no longer a need for RenderViewImpl::RenderWidgetFocusChangeComplete. B) MouseDown: Currently, in response to a left mouse button down or a gesture tap, ChromeClient notifies the WebViewClient (RenderViewImpl). This is solely used in PageClickTracker. This CL will remove the call from WebViewClient to the WebWidgetClient (RenderWidget) which similarly to FocusChangeComplete, will be forwarded to the observer RenderFrames and eventually the RenderFrameObservers. The change in A) will also fix a bug with credit card payment autofill in OOPIFs. BUG=712754, 703800, 583347, 433486 Review-Url: https://codereview.chromium.org/2766053002 Cr-Commit-Position: refs/heads/master@{#466078} Committed: https://chromium.googlesource.com/chromium/src/+/27ca69b1e049f9f86e15f34420eeef224335f075

Patch Set 1 : Shortest Fix - No refactoring #

Patch Set 2 : [refactor] Fix Payments Autofill Client in OOPIFs #

Patch Set 3 : Remove RenderWidgetOwnerDelegate::RenderWidgetFocusChangeComplete() #

Patch Set 4 : Move a method from WebWidgetClient to WebFrameClient #

Total comments: 7

Patch Set 5 : Using Node& instead of Node* #

Total comments: 24

Patch Set 6 : Rebased #

Patch Set 7 : Adrressing creis@'s comments #

Patch Set 8 : Adding a test #

Patch Set 9 : Rebased (post blink refactor) #

Patch Set 10 : Rebased #

Patch Set 11 : Move logic to WebAutofillClient #

Patch Set 12 : Fixing tests #

Total comments: 15

Patch Set 13 : Addressing vabr@'s comments #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+148 lines, -198 lines) Patch
M chrome/browser/autofill/autofill_interactive_uitest.cc View 1 2 3 4 5 6 7 8 9 1 chunk +36 lines, -0 lines 0 comments Download
M chrome/renderer/autofill/page_click_tracker_browsertest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +8 lines, -6 lines 0 comments Download
M components/autofill/content/renderer/autofill_agent.h View 1 2 3 4 5 6 7 8 9 10 11 12 7 chunks +11 lines, -31 lines 0 comments Download
M components/autofill/content/renderer/autofill_agent.cc View 1 2 3 4 5 6 7 8 9 10 11 12 7 chunks +28 lines, -52 lines 0 comments Download
M components/autofill/content/renderer/page_click_tracker.h View 1 2 3 4 5 6 7 8 9 10 11 3 chunks +13 lines, -29 lines 0 comments Download
M components/autofill/content/renderer/page_click_tracker.cc View 1 2 3 4 5 6 7 8 9 10 5 chunks +13 lines, -38 lines 0 comments Download
M content/public/renderer/render_view_observer.h View 1 2 3 4 5 6 1 chunk +0 lines, -7 lines 0 comments Download
M content/renderer/render_view_impl.h View 1 2 3 4 5 6 7 8 2 chunks +0 lines, -2 lines 0 comments Download
M content/renderer/render_view_impl.cc View 1 2 3 4 5 6 7 8 9 10 6 chunks +13 lines, -14 lines 0 comments Download
M content/renderer/render_widget.cc View 1 2 3 4 5 6 7 8 9 10 2 chunks +10 lines, -2 lines 1 comment Download
M content/renderer/render_widget_owner_delegate.h View 1 2 1 chunk +1 line, -2 lines 0 comments Download
M third_party/WebKit/Source/core/input/EventHandler.cpp View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/input/GestureManager.cpp View 1 2 3 4 5 6 7 8 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/page/ChromeClient.h View 1 2 3 4 5 6 7 8 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/web/ChromeClientImpl.h View 1 2 3 4 5 6 7 8 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/web/ChromeClientImpl.cpp View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +7 lines, -3 lines 0 comments Download
M third_party/WebKit/public/web/WebAutofillClient.h View 1 2 3 4 5 6 7 8 9 10 2 chunks +4 lines, -0 lines 0 comments Download
M third_party/WebKit/public/web/WebViewClient.h View 1 2 3 4 5 6 7 8 1 chunk +0 lines, -8 lines 0 comments Download

Messages

Total messages: 67 (42 generated)
EhsanK
creis@chromium.org: Please review changes in content/ vabr@chromium.org: Please review changes in components/ dcheng@chromium.org: Please review ...
3 years, 8 months ago (2017-03-28 20:08:16 UTC) #9
dcheng
Since this is just calling through to RenderFrame, should we just be plumbing this through ...
3 years, 8 months ago (2017-03-28 21:35:11 UTC) #10
EhsanK
On 2017/03/28 21:35:11, dcheng wrote: > Since this is just calling through to RenderFrame, should ...
3 years, 8 months ago (2017-03-28 21:53:14 UTC) #11
vabr (Chromium)
> mailto:vabr@chromium.org: Please review changes in components/ components/* LGTM, thank you for removing the legacy ...
3 years, 8 months ago (2017-03-29 08:16:05 UTC) #12
dcheng
On 2017/03/28 21:53:14, EhsanK wrote: > On 2017/03/28 21:35:11, dcheng wrote: > > Since this ...
3 years, 8 months ago (2017-03-30 04:07:50 UTC) #13
vabr (Chromium)
> +vabr, do you know if there's any plans around this area, especially given the ...
3 years, 8 months ago (2017-03-30 06:25:51 UTC) #14
EhsanK
Thank you all, PTAL.
3 years, 8 months ago (2017-03-31 15:29:25 UTC) #15
dcheng
https://codereview.chromium.org/2766053002/diff/60001/third_party/WebKit/Source/web/ChromeClientImpl.cpp File third_party/WebKit/Source/web/ChromeClientImpl.cpp (right): https://codereview.chromium.org/2766053002/diff/60001/third_party/WebKit/Source/web/ChromeClientImpl.cpp#newcode1089 third_party/WebKit/Source/web/ChromeClientImpl.cpp:1089: if (!mouseDownNode) Can this actually be null? https://codereview.chromium.org/2766053002/diff/60001/third_party/WebKit/Source/web/ChromeClientImpl.cpp#newcode1103 third_party/WebKit/Source/web/ChromeClientImpl.cpp:1103: ...
3 years, 8 months ago (2017-04-03 19:17:04 UTC) #16
EhsanK
Thanks Daniel. PTAL. https://codereview.chromium.org/2766053002/diff/60001/third_party/WebKit/Source/web/ChromeClientImpl.cpp File third_party/WebKit/Source/web/ChromeClientImpl.cpp (right): https://codereview.chromium.org/2766053002/diff/60001/third_party/WebKit/Source/web/ChromeClientImpl.cpp#newcode1089 third_party/WebKit/Source/web/ChromeClientImpl.cpp:1089: if (!mouseDownNode) On 2017/04/03 19:17:04, dcheng ...
3 years, 8 months ago (2017-04-04 18:01:49 UTC) #17
dcheng
https://codereview.chromium.org/2766053002/diff/60001/third_party/WebKit/Source/web/ChromeClientImpl.cpp File third_party/WebKit/Source/web/ChromeClientImpl.cpp (right): https://codereview.chromium.org/2766053002/diff/60001/third_party/WebKit/Source/web/ChromeClientImpl.cpp#newcode1103 third_party/WebKit/Source/web/ChromeClientImpl.cpp:1103: webframe->autofillClient()->textFieldDidReceiveKeyDown( On 2017/04/04 18:01:49, EhsanK wrote: > On 2017/04/03 ...
3 years, 8 months ago (2017-04-05 16:59:33 UTC) #18
Charlie Reis
Sorry for the delay! I think we do need tests for this, since there appears ...
3 years, 8 months ago (2017-04-05 20:13:44 UTC) #19
EhsanK
Thanks Charlie. PTAL. We are waiting to decide whether moving the logic to WebAutofillClient in ...
3 years, 8 months ago (2017-04-06 21:31:28 UTC) #22
Charlie Reis
[+kenrb] Thanks. One question for Daniel and Ken about tracking focus in RenderWidget. Let me ...
3 years, 8 months ago (2017-04-10 06:22:32 UTC) #26
vabr (Chromium)
Hi, and sorry I missed the question for me last week; my answer is below. ...
3 years, 8 months ago (2017-04-10 06:48:27 UTC) #27
EhsanK
Thank you all! PTAL. vabr@: Could you please review the latest patch? Note: I moved ...
3 years, 8 months ago (2017-04-13 20:00:59 UTC) #49
vabr (Chromium)
Thanks for the changes! The current CL LGTM, with some comments below. You plan to ...
3 years, 8 months ago (2017-04-14 06:44:24 UTC) #50
dcheng
Curious if you have any thoughts about my comment. Maybe it can't be helped for ...
3 years, 8 months ago (2017-04-18 04:41:50 UTC) #51
vabr (Chromium)
I'm not sure who you were asking, dcheng@, but here is my response just in ...
3 years, 8 months ago (2017-04-18 07:17:02 UTC) #52
EhsanK
Thanks Vaclav! I will investigate the tests next to see how they can be converted. ...
3 years, 8 months ago (2017-04-18 17:55:19 UTC) #53
dcheng
On 2017/04/18 07:17:02, vabr (Chromium) wrote: > I'm not sure who you were asking, dcheng@, ...
3 years, 8 months ago (2017-04-18 18:53:06 UTC) #54
vabr (Chromium)
Thanks for the replies, they LGTM. However, it seems like the newest patch set was ...
3 years, 8 months ago (2017-04-19 06:59:20 UTC) #55
Charlie Reis
content/ LGTM assuming it's basically the same in the latest (missing) patchset. I appreciate that ...
3 years, 8 months ago (2017-04-19 20:39:29 UTC) #56
EhsanK
Thank you all! Sorry I missed the actual upload part for the last patch. I ...
3 years, 8 months ago (2017-04-20 14:17:45 UTC) #58
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2766053002/260001
3 years, 8 months ago (2017-04-20 15:23:50 UTC) #64
commit-bot: I haz the power
3 years, 8 months ago (2017-04-20 18:34:50 UTC) #67
Message was sent while issue was closed.
Committed patchset #13 (id:260001) as
https://chromium.googlesource.com/chromium/src/+/27ca69b1e049f9f86e15f34420ee...

Powered by Google App Engine
This is Rietveld 408576698