OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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 "content/browser/appcache/appcache_storage.h" | 5 #include "content/browser/appcache/appcache_storage.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/bind_helpers.h" | 8 #include "base/bind_helpers.h" |
9 #include "base/stl_util.h" | 9 #include "base/stl_util.h" |
10 #include "content/browser/appcache/appcache_response.h" | 10 #include "content/browser/appcache/appcache_response.h" |
11 #include "content/browser/appcache/appcache_service_impl.h" | 11 #include "content/browser/appcache/appcache_service_impl.h" |
12 #include "webkit/browser/quota/quota_client.h" | 12 #include "storage/browser/quota/quota_client.h" |
13 #include "webkit/browser/quota/quota_manager_proxy.h" | 13 #include "storage/browser/quota/quota_manager_proxy.h" |
14 | 14 |
15 namespace content { | 15 namespace content { |
16 | 16 |
17 // static | 17 // static |
18 const int64 AppCacheStorage::kUnitializedId = -1; | 18 const int64 AppCacheStorage::kUnitializedId = -1; |
19 | 19 |
20 AppCacheStorage::AppCacheStorage(AppCacheServiceImpl* service) | 20 AppCacheStorage::AppCacheStorage(AppCacheServiceImpl* service) |
21 : last_cache_id_(kUnitializedId), last_group_id_(kUnitializedId), | 21 : last_cache_id_(kUnitializedId), last_group_id_(kUnitializedId), |
22 last_response_id_(kUnitializedId), service_(service) { | 22 last_response_id_(kUnitializedId), service_(service) { |
23 } | 23 } |
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
127 void AppCacheStorage::NotifyStorageAccessed(const GURL& origin) { | 127 void AppCacheStorage::NotifyStorageAccessed(const GURL& origin) { |
128 if (service()->quota_manager_proxy() && | 128 if (service()->quota_manager_proxy() && |
129 usage_map_.find(origin) != usage_map_.end()) | 129 usage_map_.find(origin) != usage_map_.end()) |
130 service()->quota_manager_proxy()->NotifyStorageAccessed( | 130 service()->quota_manager_proxy()->NotifyStorageAccessed( |
131 quota::QuotaClient::kAppcache, | 131 quota::QuotaClient::kAppcache, |
132 origin, quota::kStorageTypeTemporary); | 132 origin, quota::kStorageTypeTemporary); |
133 } | 133 } |
134 | 134 |
135 } // namespace content | 135 } // namespace content |
136 | 136 |
OLD | NEW |