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

Unified Diff: content/browser/frame_host/navigation_entry_impl.cc

Issue 2557233002: Revert of Set user_gesture bit at NavigationHandle creation time. (Closed)
Patch Set: rebase Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/browser/frame_host/navigation_entry_impl.cc
diff --git a/content/browser/frame_host/navigation_entry_impl.cc b/content/browser/frame_host/navigation_entry_impl.cc
index e7736ca298bfffa2df1c14f3e9ed4ee828d72695..336e06131aa70937e23e6180f00c73d52bfa063a 100644
--- a/content/browser/frame_host/navigation_entry_impl.cc
+++ b/content/browser/frame_host/navigation_entry_impl.cc
@@ -691,12 +691,8 @@ CommonNavigationParams NavigationEntryImpl::ConstructCommonNavigationParams(
else
method = (post_body.get() || GetHasPostData()) ? "POST" : "GET";
- NavigationGesture gesture = NavigationGestureAuto;
-#if defined(OS_ANDROID)
- gesture = has_user_gesture() ? NavigationGestureUser : NavigationGestureAuto;
-#endif
return CommonNavigationParams(
- dest_url, dest_referrer, GetTransitionType(), navigation_type, gesture,
+ dest_url, dest_referrer, GetTransitionType(), navigation_type,
!IsViewSourceMode(), should_replace_entry(), ui_timestamp, report_type,
GetBaseURLForDataURL(), GetHistoryURLForDataURL(), lofi_state,
navigation_start, method, post_body ? post_body : post_data_);
@@ -738,13 +734,17 @@ RequestNavigationParams NavigationEntryImpl::ConstructRequestNavigationParams(
current_length_to_send = 0;
}
+ bool user_gesture = false;
+#if defined(OS_ANDROID)
+ user_gesture = has_user_gesture();
+#endif
RequestNavigationParams request_params(
GetIsOverridingUserAgent(), redirects, GetCanLoadLocalResources(),
frame_entry.page_state(), GetUniqueID(), is_same_document_history_load,
is_history_navigation_in_new_child, subframe_unique_names,
has_committed_real_load, intended_as_new_entry, pending_offset_to_send,
current_offset_to_send, current_length_to_send, IsViewSourceMode(),
- should_clear_history_list());
+ should_clear_history_list(), user_gesture);
#if defined(OS_ANDROID)
if (GetDataURLAsString() &&
GetDataURLAsString()->size() <= kMaxLengthOfDataURLString) {
« no previous file with comments | « content/browser/frame_host/navigation_controller_impl_unittest.cc ('k') | content/browser/frame_host/navigation_handle_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698