This repository was archived by the owner on Feb 25, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +17
-0
lines changed
Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -103,18 +103,34 @@ void FontCollection::SetupDefaultFontManager() {
103103
104104void FontCollection::SetDefaultFontManager (sk_sp<SkFontMgr> font_manager) {
105105 default_font_manager_ = font_manager;
106+
107+ #if FLUTTER_ENABLE_SKSHAPER
108+ skt_collection_.reset ();
109+ #endif
106110}
107111
108112void FontCollection::SetAssetFontManager (sk_sp<SkFontMgr> font_manager) {
109113 asset_font_manager_ = font_manager;
114+
115+ #if FLUTTER_ENABLE_SKSHAPER
116+ skt_collection_.reset ();
117+ #endif
110118}
111119
112120void FontCollection::SetDynamicFontManager (sk_sp<SkFontMgr> font_manager) {
113121 dynamic_font_manager_ = font_manager;
122+
123+ #if FLUTTER_ENABLE_SKSHAPER
124+ skt_collection_.reset ();
125+ #endif
114126}
115127
116128void FontCollection::SetTestFontManager (sk_sp<SkFontMgr> font_manager) {
117129 test_font_manager_ = font_manager;
130+
131+ #if FLUTTER_ENABLE_SKSHAPER
132+ skt_collection_.reset ();
133+ #endif
118134}
119135
120136// Return the available font managers in the order they should be queried.
@@ -365,6 +381,7 @@ void FontCollection::ClearFontFamilyCache() {
365381 }
366382#endif
367383}
384+
368385#if FLUTTER_ENABLE_SKSHAPER
369386
370387sk_sp<skia::textlayout::FontCollection>
You can’t perform that action at this time.
0 commit comments