| OLD | NEW |
| 1 // Copyright (c) 2014 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 IOS_CHROME_BROWSER_UI_BOOKMARKS_BOOKMARK_UTILS_IOS_H_ | 5 #ifndef IOS_CHROME_BROWSER_UI_BOOKMARKS_BOOKMARK_UTILS_IOS_H_ |
| 6 #define IOS_CHROME_BROWSER_UI_BOOKMARKS_BOOKMARK_UTILS_IOS_H_ | 6 #define IOS_CHROME_BROWSER_UI_BOOKMARKS_BOOKMARK_UTILS_IOS_H_ |
| 7 | 7 |
| 8 #import <UIKit/UIKit.h> | 8 #import <UIKit/UIKit.h> |
| 9 | 9 |
| 10 #include <memory> | 10 #include <memory> |
| (...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 178 const NodeVector& vector2); | 178 const NodeVector& vector2); |
| 179 | 179 |
| 180 #pragma mark - Cache position in collection view. | 180 #pragma mark - Cache position in collection view. |
| 181 | 181 |
| 182 // Caches the active menu item, and the position in the collection view. | 182 // Caches the active menu item, and the position in the collection view. |
| 183 void CachePosition(CGFloat position, BookmarkMenuItem* item); | 183 void CachePosition(CGFloat position, BookmarkMenuItem* item); |
| 184 // Returns YES if a valid cache exists. | 184 // Returns YES if a valid cache exists. |
| 185 // |model| must be loaded. | 185 // |model| must be loaded. |
| 186 // |item| and |position| are out variables, only populated if the return is YES. | 186 // |item| and |position| are out variables, only populated if the return is YES. |
| 187 BOOL GetPositionCache(bookmarks::BookmarkModel* model, | 187 BOOL GetPositionCache(bookmarks::BookmarkModel* model, |
| 188 BookmarkMenuItem** item, | 188 BookmarkMenuItem* __autoreleasing* item, |
| 189 CGFloat* position); | 189 CGFloat* position); |
| 190 // Method exists for testing. | 190 // Method exists for testing. |
| 191 void ClearPositionCache(); | 191 void ClearPositionCache(); |
| 192 | 192 |
| 193 } // namespace bookmark_utils_ios | 193 } // namespace bookmark_utils_ios |
| 194 | 194 |
| 195 #endif // IOS_CHROME_BROWSER_UI_BOOKMARKS_BOOKMARK_UTILS_IOS_H_ | 195 #endif // IOS_CHROME_BROWSER_UI_BOOKMARKS_BOOKMARK_UTILS_IOS_H_ |
| OLD | NEW |