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

Unified Diff: chrome/browser/bookmarks/bookmark_model.cc

Issue 11090083: Makes sync code persist the date the node was added. I'm hoping this covers (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix test Created 8 years, 2 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
« no previous file with comments | « no previous file | chrome/browser/sync/glue/bookmark_change_processor.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/bookmarks/bookmark_model.cc
diff --git a/chrome/browser/bookmarks/bookmark_model.cc b/chrome/browser/bookmarks/bookmark_model.cc
index 84b41c66575b007279075df67024539ccf887224..94d32a05dcf64a10e5c179bb0e185499760a0a5e 100644
--- a/chrome/browser/bookmarks/bookmark_model.cc
+++ b/chrome/browser/bookmarks/bookmark_model.cc
@@ -468,7 +468,9 @@ const BookmarkNode* BookmarkModel::AddURLWithCreationTime(
bool was_bookmarked = IsBookmarked(url);
- SetDateFolderModified(parent, creation_time);
+ // Syncing may result in dates older than the last modified date.
+ if (creation_time > parent->date_folder_modified())
+ SetDateFolderModified(parent, creation_time);
BookmarkNode* new_node = new BookmarkNode(generate_next_node_id(), url);
new_node->SetTitle(title);
« no previous file with comments | « no previous file | chrome/browser/sync/glue/bookmark_change_processor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698