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

Unified Diff: components/sessions/core/serialized_navigation_entry.cc

Issue 2338703003: [NTP] Fix article suggestion clicks contributing to Most Visited tiles (Closed)
Patch Set: Add test coverage to HistoryBackend. Created 4 years, 3 months 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: components/sessions/core/serialized_navigation_entry.cc
diff --git a/components/sessions/core/serialized_navigation_entry.cc b/components/sessions/core/serialized_navigation_entry.cc
index 4f4124c598a5e7c50be2ed812a71946ec0aa6b33..cd5e2b381ff05929d9a172372bb1b6c4b849dab2 100644
--- a/components/sessions/core/serialized_navigation_entry.cc
+++ b/components/sessions/core/serialized_navigation_entry.cc
@@ -121,6 +121,8 @@ SerializedNavigationEntry SerializedNavigationEntry::FromSyncData(
transition |= ui::PAGE_TRANSITION_CHAIN_START;
if (sync_data.navigation_chain_end())
transition |= ui::PAGE_TRANSITION_CHAIN_END;
+ if (sync_data.navigation_ignore_for_ntp_tiles())
+ transition |= ui::PAGE_TRANSITION_IGNORE_FOR_NTP_TILES;
navigation.transition_type_ = static_cast<ui::PageTransition>(transition);
@@ -435,6 +437,9 @@ sync_pb::TabNavigation SerializedNavigationEntry::ToSyncData() const {
sync_data.set_navigation_chain_end(
(transition_type_ & ui::PAGE_TRANSITION_CHAIN_END) != 0);
+ if ((transition_type_ & ui::PAGE_TRANSITION_IGNORE_FOR_NTP_TILES) != 0)
+ sync_data.set_navigation_ignore_for_ntp_tiles(true);
+
sync_data.set_unique_id(unique_id_);
sync_data.set_timestamp_msec(syncer::TimeToProtoTime(timestamp_));
// The full-resolution timestamp works as a global ID.
« no previous file with comments | « components/history/core/browser/history_types.h ('k') | components/sessions/core/serialized_navigation_entry_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698