OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef COMPONENTS_BOOKMARKS_TEST_TEST_BOOKMARK_CLIENT_H_ | 5 #ifndef COMPONENTS_BOOKMARKS_TEST_TEST_BOOKMARK_CLIENT_H_ |
6 #define COMPONENTS_BOOKMARKS_TEST_TEST_BOOKMARK_CLIENT_H_ | 6 #define COMPONENTS_BOOKMARKS_TEST_TEST_BOOKMARK_CLIENT_H_ |
7 | 7 |
8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
9 #include "components/bookmarks/browser/bookmark_client.h" | 9 #include "components/bookmarks/browser/bookmark_client.h" |
10 | 10 |
(...skipping 21 matching lines...) Expand all Loading... |
32 | 32 |
33 // Returns true if |node| is one of the |extra_nodes_|. | 33 // Returns true if |node| is one of the |extra_nodes_|. |
34 bool IsExtraNodeRoot(const BookmarkNode* node); | 34 bool IsExtraNodeRoot(const BookmarkNode* node); |
35 | 35 |
36 // Returns true if |node| belongs to the tree of one of the |extra_nodes_|. | 36 // Returns true if |node| belongs to the tree of one of the |extra_nodes_|. |
37 bool IsAnExtraNode(const BookmarkNode* node); | 37 bool IsAnExtraNode(const BookmarkNode* node); |
38 | 38 |
39 private: | 39 private: |
40 // BookmarkClient: | 40 // BookmarkClient: |
41 virtual bool IsPermanentNodeVisible( | 41 virtual bool IsPermanentNodeVisible( |
42 const BookmarkPermanentNode* node) OVERRIDE; | 42 const BookmarkPermanentNode* node) override; |
43 virtual void RecordAction(const base::UserMetricsAction& action) OVERRIDE; | 43 virtual void RecordAction(const base::UserMetricsAction& action) override; |
44 virtual LoadExtraCallback GetLoadExtraNodesCallback() OVERRIDE; | 44 virtual LoadExtraCallback GetLoadExtraNodesCallback() override; |
45 virtual bool CanSetPermanentNodeTitle( | 45 virtual bool CanSetPermanentNodeTitle( |
46 const BookmarkNode* permanent_node) OVERRIDE; | 46 const BookmarkNode* permanent_node) override; |
47 virtual bool CanSyncNode(const BookmarkNode* node) OVERRIDE; | 47 virtual bool CanSyncNode(const BookmarkNode* node) override; |
48 virtual bool CanBeEditedByUser(const BookmarkNode* node) OVERRIDE; | 48 virtual bool CanBeEditedByUser(const BookmarkNode* node) override; |
49 | 49 |
50 // Helpers for GetLoadExtraNodesCallback(). | 50 // Helpers for GetLoadExtraNodesCallback(). |
51 static BookmarkPermanentNodeList LoadExtraNodes( | 51 static BookmarkPermanentNodeList LoadExtraNodes( |
52 BookmarkPermanentNodeList extra_nodes, | 52 BookmarkPermanentNodeList extra_nodes, |
53 int64* next_id); | 53 int64* next_id); |
54 | 54 |
55 BookmarkPermanentNodeList extra_nodes_to_load_; | 55 BookmarkPermanentNodeList extra_nodes_to_load_; |
56 std::vector<BookmarkPermanentNode*> extra_nodes_; | 56 std::vector<BookmarkPermanentNode*> extra_nodes_; |
57 | 57 |
58 DISALLOW_COPY_AND_ASSIGN(TestBookmarkClient); | 58 DISALLOW_COPY_AND_ASSIGN(TestBookmarkClient); |
59 }; | 59 }; |
60 | 60 |
61 } // namespace bookmarks | 61 } // namespace bookmarks |
62 | 62 |
63 #endif // COMPONENTS_BOOKMARKS_TEST_TEST_BOOKMARK_CLIENT_H_ | 63 #endif // COMPONENTS_BOOKMARKS_TEST_TEST_BOOKMARK_CLIENT_H_ |
OLD | NEW |