| 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 #include "chrome/browser/bookmarks/bookmark_extension_api.h" | 5 #include "chrome/browser/bookmarks/bookmark_extension_api.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/file_path.h" | 8 #include "base/file_path.h" |
| 9 #include "base/i18n/file_util_icu.h" | 9 #include "base/i18n/file_util_icu.h" |
| 10 #include "base/i18n/time_formatting.h" | 10 #include "base/i18n/time_formatting.h" |
| (...skipping 23 matching lines...) Expand all Loading... |
| 34 #include "chrome/common/chrome_notification_types.h" | 34 #include "chrome/common/chrome_notification_types.h" |
| 35 #include "chrome/common/chrome_paths.h" | 35 #include "chrome/common/chrome_paths.h" |
| 36 #include "chrome/common/pref_names.h" | 36 #include "chrome/common/pref_names.h" |
| 37 #include "content/public/browser/notification_service.h" | 37 #include "content/public/browser/notification_service.h" |
| 38 #include "grit/generated_resources.h" | 38 #include "grit/generated_resources.h" |
| 39 #include "ui/base/l10n/l10n_util.h" | 39 #include "ui/base/l10n/l10n_util.h" |
| 40 | 40 |
| 41 namespace keys = bookmark_extension_api_constants; | 41 namespace keys = bookmark_extension_api_constants; |
| 42 | 42 |
| 43 using base::TimeDelta; | 43 using base::TimeDelta; |
| 44 using content::BrowserThread; |
| 44 typedef QuotaLimitHeuristic::Bucket Bucket; | 45 typedef QuotaLimitHeuristic::Bucket Bucket; |
| 45 typedef QuotaLimitHeuristic::Config Config; | 46 typedef QuotaLimitHeuristic::Config Config; |
| 46 typedef QuotaLimitHeuristic::BucketList BucketList; | 47 typedef QuotaLimitHeuristic::BucketList BucketList; |
| 47 typedef ExtensionsQuotaService::TimedLimit TimedLimit; | 48 typedef ExtensionsQuotaService::TimedLimit TimedLimit; |
| 48 typedef ExtensionsQuotaService::SustainedLimit SustainedLimit; | 49 typedef ExtensionsQuotaService::SustainedLimit SustainedLimit; |
| 49 typedef QuotaLimitHeuristic::BucketMapper BucketMapper; | 50 typedef QuotaLimitHeuristic::BucketMapper BucketMapper; |
| 50 | 51 |
| 51 namespace { | 52 namespace { |
| 52 | 53 |
| 53 // Generates a default path (including a default filename) that will be | 54 // Generates a default path (including a default filename) that will be |
| (...skipping 880 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 934 SelectFile(SelectFileDialog::SELECT_SAVEAS_FILE); | 935 SelectFile(SelectFileDialog::SELECT_SAVEAS_FILE); |
| 935 return true; | 936 return true; |
| 936 } | 937 } |
| 937 | 938 |
| 938 void ExportBookmarksFunction::FileSelected(const FilePath& path, | 939 void ExportBookmarksFunction::FileSelected(const FilePath& path, |
| 939 int index, | 940 int index, |
| 940 void* params) { | 941 void* params) { |
| 941 bookmark_html_writer::WriteBookmarks(profile(), path, NULL); | 942 bookmark_html_writer::WriteBookmarks(profile(), path, NULL); |
| 942 Release(); // Balanced in BookmarksIOFunction::SelectFile() | 943 Release(); // Balanced in BookmarksIOFunction::SelectFile() |
| 943 } | 944 } |
| OLD | NEW |