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_HTML_WRITER_H_ | 5 #ifndef CHROME_BROWSER_BOOKMARKS_BOOKMARK_HTML_WRITER_H_ |
6 #define CHROME_BROWSER_BOOKMARKS_BOOKMARK_HTML_WRITER_H_ | 6 #define CHROME_BROWSER_BOOKMARKS_BOOKMARK_HTML_WRITER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <list> | 9 #include <list> |
10 #include <map> | 10 #include <map> |
(...skipping 29 matching lines...) Expand all Loading... |
40 | 40 |
41 BookmarkFaviconFetcher(Profile* profile, | 41 BookmarkFaviconFetcher(Profile* profile, |
42 const FilePath& path, | 42 const FilePath& path, |
43 BookmarksExportObserver* observer); | 43 BookmarksExportObserver* observer); |
44 virtual ~BookmarkFaviconFetcher(); | 44 virtual ~BookmarkFaviconFetcher(); |
45 | 45 |
46 // Executes bookmark export process. | 46 // Executes bookmark export process. |
47 void ExportBookmarks(); | 47 void ExportBookmarks(); |
48 | 48 |
49 // NotificationObserver implementation. | 49 // NotificationObserver implementation. |
50 virtual void Observe(NotificationType type, | 50 virtual void Observe(int type, |
51 const NotificationSource& source, | 51 const NotificationSource& source, |
52 const NotificationDetails& details); | 52 const NotificationDetails& details); |
53 | 53 |
54 private: | 54 private: |
55 // Recursively extracts URLs from bookmarks. | 55 // Recursively extracts URLs from bookmarks. |
56 void ExtractUrls(const BookmarkNode* node); | 56 void ExtractUrls(const BookmarkNode* node); |
57 | 57 |
58 // Executes Writer task that writes bookmarks data to html file. | 58 // Executes Writer task that writes bookmarks data to html file. |
59 void ExecuteWriter(); | 59 void ExecuteWriter(); |
60 | 60 |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
98 // thread is used. | 98 // thread is used. |
99 // Before writing to the file favicons are fetched on the main thread. | 99 // Before writing to the file favicons are fetched on the main thread. |
100 // TODO(sky): need a callback on failure. | 100 // TODO(sky): need a callback on failure. |
101 void WriteBookmarks(Profile* profile, | 101 void WriteBookmarks(Profile* profile, |
102 const FilePath& path, | 102 const FilePath& path, |
103 BookmarksExportObserver* observer); | 103 BookmarksExportObserver* observer); |
104 | 104 |
105 } // namespace bookmark_html_writer | 105 } // namespace bookmark_html_writer |
106 | 106 |
107 #endif // CHROME_BROWSER_BOOKMARKS_BOOKMARK_HTML_WRITER_H_ | 107 #endif // CHROME_BROWSER_BOOKMARKS_BOOKMARK_HTML_WRITER_H_ |
OLD | NEW |