| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2008 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2007 Nicholas Shanks <webkit@nickshanks.com> | 3 * Copyright (C) 2007 Nicholas Shanks <webkit@nickshanks.com> |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
| 7 * are met: | 7 * are met: |
| 8 * | 8 * |
| 9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 290 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 301 invalidateFontCache = true; | 301 invalidateFontCache = true; |
| 302 return clients; | 302 return clients; |
| 303 } | 303 } |
| 304 | 304 |
| 305 void FontCache::addClient(FontCacheClient* client) | 305 void FontCache::addClient(FontCacheClient* client) |
| 306 { | 306 { |
| 307 ASSERT(!fontCacheClients().contains(client)); | 307 ASSERT(!fontCacheClients().contains(client)); |
| 308 fontCacheClients().add(client); | 308 fontCacheClients().add(client); |
| 309 } | 309 } |
| 310 | 310 |
| 311 #if !ENABLE(OILPAN) | |
| 312 void FontCache::removeClient(FontCacheClient* client) | |
| 313 { | |
| 314 ASSERT(fontCacheClients().contains(client)); | |
| 315 fontCacheClients().remove(client); | |
| 316 } | |
| 317 #endif | |
| 318 | |
| 319 static unsigned short gGeneration = 0; | 311 static unsigned short gGeneration = 0; |
| 320 | 312 |
| 321 unsigned short FontCache::generation() | 313 unsigned short FontCache::generation() |
| 322 { | 314 { |
| 323 return gGeneration; | 315 return gGeneration; |
| 324 } | 316 } |
| 325 | 317 |
| 326 void FontCache::invalidate() | 318 void FontCache::invalidate() |
| 327 { | 319 { |
| 328 if (!invalidateFontCache) { | 320 if (!invalidateFontCache) { |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 377 iter != gFallbackListShaperCache->end(); | 369 iter != gFallbackListShaperCache->end(); |
| 378 ++iter) { | 370 ++iter) { |
| 379 shapeResultCacheSize += iter->value->byteSize(); | 371 shapeResultCacheSize += iter->value->byteSize(); |
| 380 } | 372 } |
| 381 dump->addScalar("size", "bytes", shapeResultCacheSize); | 373 dump->addScalar("size", "bytes", shapeResultCacheSize); |
| 382 memoryDump->addSuballocation(dump->guid(), String(WTF::Partitions::kAllocate
dObjectPoolName)); | 374 memoryDump->addSuballocation(dump->guid(), String(WTF::Partitions::kAllocate
dObjectPoolName)); |
| 383 } | 375 } |
| 384 | 376 |
| 385 | 377 |
| 386 } // namespace blink | 378 } // namespace blink |
| OLD | NEW |