| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 397 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 408 // Returns true if the parent and index are valid. | 408 // Returns true if the parent and index are valid. |
| 409 bool IsValidIndex(const BookmarkNode* parent, int index, bool allow_end); | 409 bool IsValidIndex(const BookmarkNode* parent, int index, bool allow_end); |
| 410 | 410 |
| 411 // Creates one of the possible permanent nodes (bookmark bar node, other node | 411 // Creates one of the possible permanent nodes (bookmark bar node, other node |
| 412 // and mobile node) from |type|. | 412 // and mobile node) from |type|. |
| 413 BookmarkPermanentNode* CreatePermanentNode(BookmarkNode::Type type); | 413 BookmarkPermanentNode* CreatePermanentNode(BookmarkNode::Type type); |
| 414 | 414 |
| 415 // Notification that a favicon has finished loading. If we can decode the | 415 // Notification that a favicon has finished loading. If we can decode the |
| 416 // favicon, FaviconLoaded is invoked. | 416 // favicon, FaviconLoaded is invoked. |
| 417 void OnFaviconDataAvailable(FaviconService::Handle handle, | 417 void OnFaviconDataAvailable(FaviconService::Handle handle, |
| 418 history::FaviconData favicon); | 418 history::FaviconData favicon_data, |
| 419 std::vector<GURL> icon_urls_in_db); |
| 419 | 420 |
| 420 // Invoked from the node to load the favicon. Requests the favicon from the | 421 // Invoked from the node to load the favicon. Requests the favicon from the |
| 421 // favicon service. | 422 // favicon service. |
| 422 void LoadFavicon(BookmarkNode* node); | 423 void LoadFavicon(BookmarkNode* node); |
| 423 | 424 |
| 424 // Called to notify the observers that the favicon has been loaded. | 425 // Called to notify the observers that the favicon has been loaded. |
| 425 void FaviconLoaded(const BookmarkNode* node); | 426 void FaviconLoaded(const BookmarkNode* node); |
| 426 | 427 |
| 427 // If we're waiting on a favicon for node, the load request is canceled. | 428 // If we're waiting on a favicon for node, the load request is canceled. |
| 428 void CancelPendingFaviconLoadRequests(BookmarkNode* node); | 429 void CancelPendingFaviconLoadRequests(BookmarkNode* node); |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 489 | 490 |
| 490 // See description of IsDoingExtensiveChanges above. | 491 // See description of IsDoingExtensiveChanges above. |
| 491 int extensive_changes_; | 492 int extensive_changes_; |
| 492 | 493 |
| 493 scoped_ptr<BookmarkExpandedStateTracker> expanded_state_tracker_; | 494 scoped_ptr<BookmarkExpandedStateTracker> expanded_state_tracker_; |
| 494 | 495 |
| 495 DISALLOW_COPY_AND_ASSIGN(BookmarkModel); | 496 DISALLOW_COPY_AND_ASSIGN(BookmarkModel); |
| 496 }; | 497 }; |
| 497 | 498 |
| 498 #endif // CHROME_BROWSER_BOOKMARKS_BOOKMARK_MODEL_H_ | 499 #endif // CHROME_BROWSER_BOOKMARKS_BOOKMARK_MODEL_H_ |
| OLD | NEW |