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

Issue 2378393002: Pass the user_gesture context in the IPC message FrameMsg_CommitNavigation to the renderer. (Closed)

Created:
4 years, 2 months ago by ananta
Modified:
4 years, 2 months ago
Reviewers:
jam, nasko
CC:
chromium-reviews, jam, nasko+codewatch_chromium.org, darin-cc_chromium.org, creis+watch_chromium.org, mlamouri+watch-content_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Pass the user_gesture context in the IPC message FrameMsg_CommitNavigation to the renderer. In PlzNavigate, URL navigations are handled via RenderFrameImpl::BeginNavigation. This eventually sends an IPC message FrameHostMsg_BeginNavigation to the browser. The user_gesture context flag is passed to the browser in the BeginNavigationParams structure which is passed along with this message. The user_gesture flag is scoped, i.e the value is reset once it is read. The FrameMsg_CommitNavigation is sent by the browser when the navigation is committed. We need to pass the user_request context flag back to the renderer and execute the navigation in this context. This ensures that the Password Autofill agent and other consumers get the correct value of the user context. This fixes the PasswordManagerBrowserTestBase.NoPromptIfLinkClicked test which was failing because the Password bubble was being displayed due to the user context flag not being set. BUG=576287 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_site_isolation Committed: https://crrev.com/3cfab18193ffb78dbb68f504628276865d225de6 Cr-Commit-Position: refs/heads/master@{#422206}

Patch Set 1 #

Total comments: 3

Patch Set 2 : Address review comments. Define the has_user_gesture flag in the RequestNavigationParams structure. #

Total comments: 2

Patch Set 3 : Remove the has_user_gesture flag from the StartNavigationParams structure.. #

Patch Set 4 : Remove has_user_gesture from the IPC traits for StartNavigationParams #

Patch Set 5 : Fix compile failures #

Patch Set 6 : Fix compile failures #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+31 lines, -32 lines) Patch
M content/browser/frame_host/navigation_entry_impl.cc View 1 2 3 4 2 chunks +5 lines, -4 lines 1 comment Download
M content/browser/frame_host/navigation_request.cc View 1 2 chunks +5 lines, -1 line 1 comment Download
M content/common/frame_messages.h View 1 2 3 3 chunks +2 lines, -4 lines 0 comments Download
M content/common/navigation_params.h View 1 2 4 chunks +5 lines, -8 lines 0 comments Download
M content/common/navigation_params.cc View 1 2 3 4 5 4 chunks +7 lines, -14 lines 0 comments Download
M content/renderer/render_frame_impl.cc View 1 2 2 chunks +7 lines, -1 line 0 comments Download

Messages

Total messages: 42 (28 generated)
ananta
4 years, 2 months ago (2016-09-29 03:40:32 UTC) #3
jam
looks great, just one nit also, please run the linux_chromium_browser_side_navigation_rel trybot for these changes https://codereview.chromium.org/2378393002/diff/1/content/common/frame_messages.h ...
4 years, 2 months ago (2016-09-29 19:51:38 UTC) #9
ananta
https://codereview.chromium.org/2378393002/diff/1/content/common/frame_messages.h File content/common/frame_messages.h (right): https://codereview.chromium.org/2378393002/diff/1/content/common/frame_messages.h#newcode903 content/common/frame_messages.h:903: content::RequestNavigationParams, /* request_params */ On 2016/09/29 19:51:38, jam wrote: ...
4 years, 2 months ago (2016-09-29 21:28:43 UTC) #10
jam
https://codereview.chromium.org/2378393002/diff/1/content/common/frame_messages.h File content/common/frame_messages.h (right): https://codereview.chromium.org/2378393002/diff/1/content/common/frame_messages.h#newcode903 content/common/frame_messages.h:903: content::RequestNavigationParams, /* request_params */ On 2016/09/29 21:28:43, ananta wrote: ...
4 years, 2 months ago (2016-09-29 21:38:27 UTC) #13
jam
https://codereview.chromium.org/2378393002/diff/20001/content/common/navigation_params.h File content/common/navigation_params.h (right): https://codereview.chromium.org/2378393002/diff/20001/content/common/navigation_params.h#newcode339 content/common/navigation_params.h:339: bool has_user_gesture; now this can be removed from StartNavigationParams?
4 years, 2 months ago (2016-09-29 21:40:43 UTC) #14
ananta
https://codereview.chromium.org/2378393002/diff/20001/content/common/navigation_params.h File content/common/navigation_params.h (right): https://codereview.chromium.org/2378393002/diff/20001/content/common/navigation_params.h#newcode339 content/common/navigation_params.h:339: bool has_user_gesture; On 2016/09/29 21:40:43, jam wrote: > now ...
4 years, 2 months ago (2016-09-29 22:07:37 UTC) #15
jam
lgtm
4 years, 2 months ago (2016-09-29 23:50:55 UTC) #26
ananta
On 2016/09/29 23:50:55, jam wrote: > lgtm Will land this. Will address any comments from ...
4 years, 2 months ago (2016-09-30 19:18:49 UTC) #31
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/2378393002/100001
4 years, 2 months ago (2016-09-30 19:19:38 UTC) #33
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/270914)
4 years, 2 months ago (2016-09-30 19:31:01 UTC) #35
nasko
LGTM https://codereview.chromium.org/2378393002/diff/100001/content/browser/frame_host/navigation_entry_impl.cc File content/browser/frame_host/navigation_entry_impl.cc (right): https://codereview.chromium.org/2378393002/diff/100001/content/browser/frame_host/navigation_entry_impl.cc#newcode718 content/browser/frame_host/navigation_entry_impl.cc:718: user_gesture = has_user_gesture(); I wonder why this needs ...
4 years, 2 months ago (2016-09-30 20:21:47 UTC) #36
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/2378393002/100001
4 years, 2 months ago (2016-09-30 20:23:00 UTC) #38
commit-bot: I haz the power
Committed patchset #6 (id:100001)
4 years, 2 months ago (2016-09-30 20:29:44 UTC) #40
commit-bot: I haz the power
4 years, 2 months ago (2016-09-30 20:31:42 UTC) #42
Message was sent while issue was closed.
Patchset 6 (id:??) landed as
https://crrev.com/3cfab18193ffb78dbb68f504628276865d225de6
Cr-Commit-Position: refs/heads/master@{#422206}

Powered by Google App Engine
This is Rietveld 408576698