diff options
author | gab@chromium.org <gab@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-05-09 11:57:31 +0000 |
---|---|---|
committer | gab@chromium.org <gab@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-05-09 11:57:31 +0000 |
commit | 16d3e3de030b8f8fd15056f8eacab657ea5be73d (patch) | |
tree | 3d594836da8bd7acdcda713e9853e013748a3bd3 /base/critical_closure_internal_ios.mm | |
parent | d24692452eaf11b69a3c93d3002261e70d4c6ac6 (diff) | |
download | chromium_src-16d3e3de030b8f8fd15056f8eacab657ea5be73d.zip chromium_src-16d3e3de030b8f8fd15056f8eacab657ea5be73d.tar.gz chromium_src-16d3e3de030b8f8fd15056f8eacab657ea5be73d.tar.bz2 |
Allow MakeCriticalClosure to enclose closures with non-void return types.
This is required in order to allow ImportantFileWriter::WriteFileAtomically() to report its bool result to the calling thread via PostTaskAndReplyWithResult() in https://codereview.chromium.org/257003007/
BUG=365769
R=stuartmorgan@chromium.org, thakis@chromium.org
Review URL: https://codereview.chromium.org/274773003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@269238 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/critical_closure_internal_ios.mm')
-rw-r--r-- | base/critical_closure_internal_ios.mm | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/base/critical_closure_internal_ios.mm b/base/critical_closure_internal_ios.mm new file mode 100644 index 0000000..b8fec14 --- /dev/null +++ b/base/critical_closure_internal_ios.mm @@ -0,0 +1,17 @@ +// Copyright 2014 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#include "base/critical_closure.h" + +#import <UIKit/UIKit.h> + +namespace base { +namespace internal { + +bool IsMultiTaskingSupported() { + return [[UIDevice currentDevice] isMultitaskingSupported]; +} + +} // namespace internal +} // namespace base |