[email protected] | de7d61ff | 2013-08-20 11:30:41 | [diff] [blame] | 1 | // Copyright 2013 The Chromium Authors. All rights reserved. |
[email protected] | fc41b21 | 2013-03-25 16:04:23 | [diff] [blame] | 2 | // Use of this source code is governed by a BSD-style license that can be |
3 | // found in the LICENSE file. | ||||
4 | |||||
[email protected] | de7d61ff | 2013-08-20 11:30:41 | [diff] [blame] | 5 | #include "content/shell/browser/shell_quota_permission_context.h" |
[email protected] | fc41b21 | 2013-03-25 16:04:23 | [diff] [blame] | 6 | |
[email protected] | 7660ec9 | 2013-05-30 05:12:39 | [diff] [blame] | 7 | #include "webkit/common/quota/quota_types.h" |
[email protected] | fc41b21 | 2013-03-25 16:04:23 | [diff] [blame] | 8 | |
9 | namespace content { | ||||
10 | |||||
11 | ShellQuotaPermissionContext::ShellQuotaPermissionContext() {} | ||||
12 | |||||
13 | void ShellQuotaPermissionContext::RequestQuotaPermission( | ||||
[email protected] | f78aa772 | 2014-04-04 00:04:25 | [diff] [blame^] | 14 | const StorageQuotaParams& params, |
[email protected] | fc41b21 | 2013-03-25 16:04:23 | [diff] [blame] | 15 | int render_process_id, |
[email protected] | fc41b21 | 2013-03-25 16:04:23 | [diff] [blame] | 16 | const PermissionCallback& callback) { |
[email protected] | f78aa772 | 2014-04-04 00:04:25 | [diff] [blame^] | 17 | if (params.storage_type != quota::kStorageTypePersistent) { |
[email protected] | fc41b21 | 2013-03-25 16:04:23 | [diff] [blame] | 18 | // For now we only support requesting quota with this interface |
19 | // for Persistent storage type. | ||||
20 | callback.Run(QUOTA_PERMISSION_RESPONSE_DISALLOW); | ||||
21 | return; | ||||
22 | } | ||||
23 | |||||
24 | callback.Run(QUOTA_PERMISSION_RESPONSE_ALLOW); | ||||
25 | } | ||||
26 | |||||
27 | ShellQuotaPermissionContext::~ShellQuotaPermissionContext() {} | ||||
28 | |||||
29 | } // namespace content |