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

Unified Diff: chrome/browser/bookmarks/bookmark_codec.h

Issue 6931018: Initial implementation of "Synced Bookmarks" folder. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Merge Created 9 years, 7 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 | « chrome/app/generated_resources.grd ('k') | chrome/browser/bookmarks/bookmark_codec.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/bookmarks/bookmark_codec.h
diff --git a/chrome/browser/bookmarks/bookmark_codec.h b/chrome/browser/bookmarks/bookmark_codec.h
index fe57d1fe6ae0a322e7d91c2a02618ee7f477392a..2d29df84c3a21c28229efe0ad1899c1825e072bc 100644
--- a/chrome/browser/bookmarks/bookmark_codec.h
+++ b/chrome/browser/bookmarks/bookmark_codec.h
@@ -1,4 +1,4 @@
-// Copyright (c) 2010 The Chromium Authors. All rights reserved.
+// Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -46,7 +46,8 @@ class BookmarkCodec {
// This method is public for use by StarredURLDatabase in migrating the
// bookmarks out of the database.
Value* Encode(const BookmarkNode* bookmark_bar_node,
- const BookmarkNode* other_folder_node);
+ const BookmarkNode* other_folder_node,
+ const BookmarkNode* synced_folder_node);
// Decodes the previously encoded value to the specified nodes as well as
// setting |max_node_id| to the greatest node id. Returns true on success,
@@ -55,6 +56,7 @@ class BookmarkCodec {
// |max_node_id| is set to the max id of the nodes.
bool Decode(BookmarkNode* bb_node,
BookmarkNode* other_folder_node,
+ BookmarkNode* synced_folder_node,
int64* max_node_id,
const Value& value);
@@ -76,6 +78,7 @@ class BookmarkCodec {
static const char* kRootsKey;
static const char* kRootFolderNameKey;
static const char* kOtherBookmarkFolderNameKey;
+ static const char* kSyncedBookmarkFolderNameKey;
static const char* kVersionKey;
static const char* kChecksumKey;
static const char* kIdKey;
@@ -98,6 +101,7 @@ class BookmarkCodec {
// Helper to perform decoding.
bool DecodeHelper(BookmarkNode* bb_node,
BookmarkNode* other_folder_node,
+ BookmarkNode* synced_folder_node,
const Value& value);
// Decodes the children of the specified node. Returns true on success.
@@ -105,7 +109,9 @@ class BookmarkCodec {
BookmarkNode* parent);
// Reassigns bookmark IDs for all nodes.
- void ReassignIDs(BookmarkNode* bb_node, BookmarkNode* other_node);
+ void ReassignIDs(BookmarkNode* bb_node,
+ BookmarkNode* other_node,
+ BookmarkNode* synced_node);
// Helper to recursively reassign IDs.
void ReassignIDsHelper(BookmarkNode* node);
« no previous file with comments | « chrome/app/generated_resources.grd ('k') | chrome/browser/bookmarks/bookmark_codec.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698