OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 CHROME_BROWSER_BOOKMARKS_BOOKMARK_MODEL_H_ | 5 #ifndef CHROME_BROWSER_BOOKMARKS_BOOKMARK_MODEL_H_ |
6 #define CHROME_BROWSER_BOOKMARKS_BOOKMARK_MODEL_H_ | 6 #define CHROME_BROWSER_BOOKMARKS_BOOKMARK_MODEL_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <set> | 9 #include <set> |
10 #include <vector> | 10 #include <vector> |
(...skipping 412 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
423 const content::NotificationDetails& details) OVERRIDE; | 423 const content::NotificationDetails& details) OVERRIDE; |
424 | 424 |
425 // Generates and returns the next node ID. | 425 // Generates and returns the next node ID. |
426 int64 generate_next_node_id(); | 426 int64 generate_next_node_id(); |
427 | 427 |
428 // Sets the maximum node ID to the given value. | 428 // Sets the maximum node ID to the given value. |
429 // This is used by BookmarkCodec to report the maximum ID after it's done | 429 // This is used by BookmarkCodec to report the maximum ID after it's done |
430 // decoding since during decoding codec assigns node IDs. | 430 // decoding since during decoding codec assigns node IDs. |
431 void set_next_node_id(int64 id) { next_node_id_ = id; } | 431 void set_next_node_id(int64 id) { next_node_id_ = id; } |
432 | 432 |
433 // Records that the bookmarks file was changed externally. | |
434 void SetFileChanged(); | |
435 | |
436 // Creates and returns a new BookmarkLoadDetails. It's up to the caller to | 433 // Creates and returns a new BookmarkLoadDetails. It's up to the caller to |
437 // delete the returned object. | 434 // delete the returned object. |
438 BookmarkLoadDetails* CreateLoadDetails(); | 435 BookmarkLoadDetails* CreateLoadDetails(); |
439 | 436 |
440 content::NotificationRegistrar registrar_; | 437 content::NotificationRegistrar registrar_; |
441 | 438 |
442 Profile* profile_; | 439 Profile* profile_; |
443 | 440 |
444 // Whether the initial set of data has been loaded. | 441 // Whether the initial set of data has been loaded. |
445 bool loaded_; | 442 bool loaded_; |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
479 scoped_ptr<BookmarkIndex> index_; | 476 scoped_ptr<BookmarkIndex> index_; |
480 | 477 |
481 base::WaitableEvent loaded_signal_; | 478 base::WaitableEvent loaded_signal_; |
482 | 479 |
483 scoped_ptr<BookmarkExpandedStateTracker> expanded_state_tracker_; | 480 scoped_ptr<BookmarkExpandedStateTracker> expanded_state_tracker_; |
484 | 481 |
485 DISALLOW_COPY_AND_ASSIGN(BookmarkModel); | 482 DISALLOW_COPY_AND_ASSIGN(BookmarkModel); |
486 }; | 483 }; |
487 | 484 |
488 #endif // CHROME_BROWSER_BOOKMARKS_BOOKMARK_MODEL_H_ | 485 #endif // CHROME_BROWSER_BOOKMARKS_BOOKMARK_MODEL_H_ |
OLD | NEW |