Index: content/browser/file_system/file_system_browsertest.cc |
diff --git a/content/browser/file_system/file_system_browsertest.cc b/content/browser/file_system/file_system_browsertest.cc |
index dfa9245cc0bcf87a4f9ecd58898d536bd6b32703..9c20d1135ded65d20bdc2f2797afef82677f6509 100644 |
--- a/content/browser/file_system/file_system_browsertest.cc |
+++ b/content/browser/file_system/file_system_browsertest.cc |
@@ -2,6 +2,7 @@ |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
+#include "base/bind.h" |
#include "base/command_line.h" |
#include "base/file_path.h" |
#include "base/memory/ref_counted.h" |
@@ -63,18 +64,11 @@ class FileSystemBrowserTestWithLowQuota : public FileSystemBrowserTest { |
kTemporaryStorageQuotaMaxSize, browser()->profile()->GetQuotaManager()); |
} |
- class SetTempQuotaCallback : public quota::QuotaCallback { |
- public: |
- void Run(quota::QuotaStatusCode, quota::StorageType, int64) { |
- DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); |
- } |
- |
- void RunWithParams(const Tuple3<quota::QuotaStatusCode, |
- quota::StorageType, |
- int64>& params) { |
- Run(params.a, params.b, params.c); |
- } |
- }; |
+ static void DidSetTempQuota(quota::QuotaStatusCode status, |
+ quota::StorageType type, |
+ int64 quota) { |
+ DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); |
+ } |
static void SetTempQuota(int64 bytes, scoped_refptr<QuotaManager> qm) { |
if (!BrowserThread::CurrentlyOn(BrowserThread::IO)) { |
@@ -84,7 +78,9 @@ class FileSystemBrowserTestWithLowQuota : public FileSystemBrowserTest { |
return; |
} |
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); |
- qm->SetTemporaryGlobalQuota(bytes, new SetTempQuotaCallback); |
+ qm->SetTemporaryGlobalQuota( |
+ bytes, |
+ base::Bind(&FileSystemBrowserTestWithLowQuota::DidSetTempQuota)); |
// Don't return until the quota has been set. |
scoped_refptr<base::ThreadTestHelper> helper( |
new base::ThreadTestHelper( |