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

Unified Diff: content/common/navigation_params.cc

Issue 2499313003: 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
« no previous file with comments | « content/common/navigation_params.h ('k') | content/public/browser/navigation_handle.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/navigation_params.cc
diff --git a/content/common/navigation_params.cc b/content/common/navigation_params.cc
index d6d1eb1abaafe537f722ff4ff2a496ea0fdc7030..f1a7fb5f191d786e11e362f89795bac3f3810520 100644
--- a/content/common/navigation_params.cc
+++ b/content/common/navigation_params.cc
@@ -30,6 +30,7 @@ bool ShouldMakeNetworkRequestForURL(const GURL& url) {
CommonNavigationParams::CommonNavigationParams()
: transition(ui::PAGE_TRANSITION_LINK),
navigation_type(FrameMsg_Navigate_Type::NORMAL),
+ gesture(NavigationGestureUnknown),
allow_download(true),
should_replace_current_entry(false),
report_type(FrameMsg_UILoadMetricsReportType::NO_REPORT),
@@ -42,6 +43,7 @@ CommonNavigationParams::CommonNavigationParams(
const Referrer& referrer,
ui::PageTransition transition,
FrameMsg_Navigate_Type::Value navigation_type,
+ NavigationGesture gesture,
bool allow_download,
bool should_replace_current_entry,
base::TimeTicks ui_timestamp,
@@ -56,6 +58,7 @@ CommonNavigationParams::CommonNavigationParams(
referrer(referrer),
transition(transition),
navigation_type(navigation_type),
+ gesture(gesture),
allow_download(allow_download),
should_replace_current_entry(should_replace_current_entry),
ui_timestamp(ui_timestamp),
@@ -81,19 +84,16 @@ CommonNavigationParams::~CommonNavigationParams() {
BeginNavigationParams::BeginNavigationParams()
: load_flags(0),
- has_user_gesture(false),
skip_service_worker(false),
request_context_type(REQUEST_CONTEXT_TYPE_LOCATION) {}
BeginNavigationParams::BeginNavigationParams(
std::string headers,
int load_flags,
- bool has_user_gesture,
bool skip_service_worker,
RequestContextType request_context_type)
: headers(headers),
load_flags(load_flags),
- has_user_gesture(has_user_gesture),
skip_service_worker(skip_service_worker),
request_context_type(request_context_type) {}
@@ -134,8 +134,7 @@ RequestNavigationParams::RequestNavigationParams()
is_view_source(false),
should_clear_history_list(false),
should_create_service_worker(false),
- service_worker_provider_id(kInvalidServiceWorkerProviderId),
- has_user_gesture(false) {}
+ service_worker_provider_id(kInvalidServiceWorkerProviderId) {}
RequestNavigationParams::RequestNavigationParams(
bool is_overriding_user_agent,
@@ -152,8 +151,7 @@ RequestNavigationParams::RequestNavigationParams(
int current_history_list_offset,
int current_history_list_length,
bool is_view_source,
- bool should_clear_history_list,
- bool has_user_gesture)
+ bool should_clear_history_list)
: is_overriding_user_agent(is_overriding_user_agent),
redirects(redirects),
can_load_local_resources(can_load_local_resources),
@@ -170,8 +168,7 @@ RequestNavigationParams::RequestNavigationParams(
is_view_source(is_view_source),
should_clear_history_list(should_clear_history_list),
should_create_service_worker(false),
- service_worker_provider_id(kInvalidServiceWorkerProviderId),
- has_user_gesture(has_user_gesture) {}
+ service_worker_provider_id(kInvalidServiceWorkerProviderId) {}
RequestNavigationParams::RequestNavigationParams(
const RequestNavigationParams& other) = default;
« no previous file with comments | « content/common/navigation_params.h ('k') | content/public/browser/navigation_handle.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698