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

Unified Diff: third_party/WebKit/Source/web/WebCache.cpp

Issue 2435603002: [WeakMemoryCache] Remove dead/live distinction of Resource outside core/fetch (Closed)
Patch Set: Rebase Created 4 years, 1 month 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 | « components/web_cache/renderer/web_cache_impl.cc ('k') | third_party/WebKit/public/web/WebCache.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/web/WebCache.cpp
diff --git a/third_party/WebKit/Source/web/WebCache.cpp b/third_party/WebKit/Source/web/WebCache.cpp
index 92fc2d8f287ab32d73d90272f17c071500cf9a22..40ed9b9dd864288f7d12c6e5a10c0be858efc2ad 100644
--- a/third_party/WebKit/Source/web/WebCache.cpp
+++ b/third_party/WebKit/Source/web/WebCache.cpp
@@ -40,13 +40,10 @@ static void ToResourceTypeStat(const MemoryCache::TypeStatistic& from,
WebCache::ResourceTypeStat& to) {
to.count = from.count;
to.size = from.size;
- // TODO(hiroshige): remove |liveSize| as it is no longer meaningful.
- to.liveSize = from.size;
to.decodedSize = from.decodedSize;
}
-// TODO(hiroshige): remove parameters that are no longer meaningful.
-void WebCache::setCapacities(size_t, size_t, size_t capacity) {
+void WebCache::setCapacity(size_t capacity) {
MemoryCache* cache = memoryCache();
if (cache)
cache->setCapacity(static_cast<unsigned>(capacity));
@@ -63,12 +60,8 @@ void WebCache::getUsageStats(UsageStats* result) {
MemoryCache* cache = memoryCache();
if (cache) {
- // TODO(hiroshige): remove members that are no longer meaningful.
- result->minDeadCapacity = 0;
- result->maxDeadCapacity = 0;
result->capacity = cache->capacity();
- result->liveSize = cache->size();
- result->deadSize = 0;
+ result->size = cache->size();
} else
memset(result, 0, sizeof(UsageStats));
}
« no previous file with comments | « components/web_cache/renderer/web_cache_impl.cc ('k') | third_party/WebKit/public/web/WebCache.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698