Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(686)

Unified Diff: ios/chrome/browser/ui/external_file_remover.mm

Issue 2804703002: [ObjC ARC] Converts ios/chrome/browser/ui:ui_internal_arc to ARC. (Closed)
Patch Set: comments Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ios/chrome/browser/ui/external_file_remover.h ('k') | ios/chrome/browser/ui/fade_truncated_label.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/chrome/browser/ui/external_file_remover.mm
diff --git a/ios/chrome/browser/ui/external_file_remover.mm b/ios/chrome/browser/ui/external_file_remover.mm
index b81a45474a71496ffb116933d9b946ed7c28e1ab..90c8efbeea5e8c152171dd22bd5e4cb3ba6df89b 100644
--- a/ios/chrome/browser/ui/external_file_remover.mm
+++ b/ios/chrome/browser/ui/external_file_remover.mm
@@ -13,6 +13,10 @@
#import "ios/chrome/browser/ui/external_file_controller.h"
#include "ios/web/public/web_thread.h"
+#if !defined(__has_feature) || !__has_feature(objc_arc)
+#error "This file requires ARC support."
+#endif
+
ExternalFileRemover::ExternalFileRemover(BrowserViewController* bvc)
: tabRestoreService_(NULL), bvc_(bvc), weak_ptr_factory_(this) {}
@@ -68,7 +72,7 @@ void ExternalFileRemover::RemoveFiles(bool all_files,
callback_wrapper = base::Bind(&base::DoNothing);
}
web::WebThread::PostBlockingPoolTaskAndReply(
- FROM_HERE, base::BindBlock(^{
+ FROM_HERE, base::BindBlockArc(^{
[ExternalFileController removeFilesExcluding:referencedFiles
olderThan:ageInDays];
}),
@@ -84,7 +88,7 @@ void ExternalFileRemover::RemoveAfterDelay(const base::TimeDelta& delay,
// make sure a method on |this| is not called when the object has gone away.
base::WeakPtr<ExternalFileRemover> weak_this = weak_ptr_factory_.GetWeakPtr();
web::WebThread::PostDelayedTask(
- web::WebThread::UI, FROM_HERE, base::BindBlock(^{
+ web::WebThread::UI, FROM_HERE, base::BindBlockArc(^{
if (weak_this) {
weak_this->Remove(remove_all_files, callback_copy);
} else if (!callback_copy.is_null()) {
« no previous file with comments | « ios/chrome/browser/ui/external_file_remover.h ('k') | ios/chrome/browser/ui/fade_truncated_label.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698