MCPcopy Create free account
hub / github.com/Snapchat/Valdi / lock

Method lock

snap_drawing/src/snap_drawing/cpp/Text/FontManager.cpp:419–421  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

417void FontManager::registerTypeface(const String& fontFamilyName,
418 FontStyle fontStyle,
419 bool canUseAsFallback,
420 const Ref<LoadableTypeface>& loadableTypeface) {
421 auto guard = lock(/* shouldInitIfNeeded */ false, nullptr);
422 _typefaceRegistry.registerTypeface(fontFamilyName, fontStyle, canUseAsFallback, loadableTypeface);
423 // Clear fallback font family cache, so that we can pickup our new typeface
424 _fallbackFontFamilies.clear();

Callers 8

doDisposeMethod · 0.45
clearQueueUpToSizeMethod · 0.45
getLayerMethod · 0.45
onDidDrawMethod · 0.45
requestLayoutMethod · 0.45
getParentMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected