OLD | NEW |
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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 #include "chrome/browser/bookmark_storage.h" | 5 #include "chrome/browser/bookmarks/bookmark_storage.h" |
6 | 6 |
7 #include "base/file_util.h" | 7 #include "base/file_util.h" |
8 #include "base/json_writer.h" | 8 #include "base/json_writer.h" |
9 #include "base/message_loop.h" | 9 #include "base/message_loop.h" |
10 #include "chrome/browser/bookmark_bar_model.h" | 10 #include "chrome/browser/bookmarks/bookmark_bar_model.h" |
11 #include "chrome/browser/bookmark_codec.h" | 11 #include "chrome/browser/bookmarks/bookmark_codec.h" |
12 #include "chrome/browser/profile.h" | 12 #include "chrome/browser/profile.h" |
13 #include "chrome/common/chrome_constants.h" | 13 #include "chrome/common/chrome_constants.h" |
14 #include "chrome/common/json_value_serializer.h" | 14 #include "chrome/common/json_value_serializer.h" |
15 | 15 |
16 namespace { | 16 namespace { |
17 | 17 |
18 // Extension used for backup files (copy of main file created during startup). | 18 // Extension used for backup files (copy of main file created during startup). |
19 const wchar_t* const kBackupExtension = L"bak"; | 19 const wchar_t* const kBackupExtension = L"bak"; |
20 | 20 |
21 // Extension for the temporary file. We write to the temp file than move to | 21 // Extension for the temporary file. We write to the temp file than move to |
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
166 | 166 |
167 // BookmarkStorage takes ownership of root. | 167 // BookmarkStorage takes ownership of root. |
168 if (message_loop) { | 168 if (message_loop) { |
169 message_loop->PostTask(FROM_HERE, NewRunnableMethod( | 169 message_loop->PostTask(FROM_HERE, NewRunnableMethod( |
170 service.get(), &BookmarkStorage::LoadedBookmarks, root, | 170 service.get(), &BookmarkStorage::LoadedBookmarks, root, |
171 bookmark_file_exists, load_from_history)); | 171 bookmark_file_exists, load_from_history)); |
172 } else { | 172 } else { |
173 service->LoadedBookmarks(root, bookmark_file_exists, load_from_history); | 173 service->LoadedBookmarks(root, bookmark_file_exists, load_from_history); |
174 } | 174 } |
175 } | 175 } |
OLD | NEW |