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

Unified Diff: src/gpu/GrTextStrike_impl.h

Issue 43383006: Clean up the GrTHashTable API. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: boo, default template arguments on a function are C++11... Created 7 years, 2 months 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 | « src/gpu/GrTextStrike.cpp ('k') | tests/HashCacheTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrTextStrike_impl.h
diff --git a/src/gpu/GrTextStrike_impl.h b/src/gpu/GrTextStrike_impl.h
index 7f087fe05d18d07ef43b7e7979019bb895e1a1cc..130509c5d8bc5c3d3f3456a3972f3cb88b409f6b 100644
--- a/src/gpu/GrTextStrike_impl.h
+++ b/src/gpu/GrTextStrike_impl.h
@@ -13,8 +13,8 @@
class GrFontCache::Key {
public:
- Key(GrFontScaler* scaler) {
- fFontScalerKey = scaler->getKey();
+ explicit Key(const GrKey* fontScalarKey) {
+ fFontScalerKey = fontScalarKey;
}
intptr_t getHash() const { return fFontScalerKey->getHash(); }
@@ -51,7 +51,7 @@ void GrFontCache::detachStrikeFromList(GrTextStrike* strike) {
GrTextStrike* GrFontCache::getStrike(GrFontScaler* scaler) {
this->validate();
- Key key(scaler);
+ const Key key(scaler->getKey());
GrTextStrike* strike = fCache.find(key);
if (NULL == strike) {
strike = this->generateStrike(scaler, key);
« no previous file with comments | « src/gpu/GrTextStrike.cpp ('k') | tests/HashCacheTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698