return the prev value from SetFontCacheLimit

git-svn-id: http://skia.googlecode.com/svn/trunk@2622 2bbb7eff-a529-9590-31e7-b0007b416f81
This commit is contained in:
reed@google.com 2011-11-08 13:55:36 +00:00
parent 77407ca019
commit 6c99633f73

View File

@ -149,6 +149,8 @@ size_t SkGraphics::GetFontCacheLimit() {
}
size_t SkGraphics::SetFontCacheLimit(size_t bytes) {
size_t prev = gFontCacheLimit;
if (bytes < SK_MIN_FONT_CACHE_LIMIT) {
bytes = SK_MIN_FONT_CACHE_LIMIT;
}
@ -158,5 +160,6 @@ size_t SkGraphics::SetFontCacheLimit(size_t bytes) {
if (bytes < GetFontCacheUsed()) {
SetFontCacheUsed(bytes);
}
return prev;
}