Rename FontCollection to FlutterFontCollection (flutter/engine#40395)

Rename FontCollection to FlutterFontCollection
This commit is contained in:
Jason Simmons
2023-03-20 14:12:05 -07:00
committed by GitHub
parent f016a17df7
commit 31aa0c80a1
6 changed files with 6 additions and 6 deletions

View File

@@ -24,7 +24,7 @@ const String _robotoUrl =
'https://fonts.gstatic.com/s/roboto/v20/KFOmCnqEu92Fr1Me5WZLCzYlKw.ttf';
/// Manages the fonts used in the Skia-based backend.
class SkiaFontCollection implements FontCollection {
class SkiaFontCollection implements FlutterFontCollection {
final Set<String> _downloadedFontFamilies = <String>{};
/// Fonts that started the download process, but are not yet registered.

View File

@@ -7,7 +7,7 @@ import 'dart:typed_data';
import 'assets.dart';
abstract class FontCollection {
abstract class FlutterFontCollection {
/// Fonts loaded with [loadFontFromList] do not need to be registered
/// with [registerDownloadedFonts]. Fonts are both downloaded and registered

View File

@@ -47,7 +47,7 @@ abstract class Renderer {
}
String get rendererTag;
FontCollection get fontCollection;
FlutterFontCollection get fontCollection;
FutureOr<void> initialize();
void reset(FlutterViewEmbedder embedder);

View File

@@ -155,7 +155,7 @@ class SkwasmRenderer implements Renderer {
}
@override
FontCollection get fontCollection => throw UnimplementedError('fontCollection not yet implemented');
FlutterFontCollection get fontCollection => throw UnimplementedError('fontCollection not yet implemented');
@override
FutureOr<void> initialize() {

View File

@@ -135,7 +135,7 @@ class SkwasmRenderer implements Renderer {
}
@override
FontCollection get fontCollection => throw UnimplementedError('Skwasm not implemented on this platform.');
FlutterFontCollection get fontCollection => throw UnimplementedError('Skwasm not implemented on this platform.');
@override
FutureOr<void> initialize() {

View File

@@ -20,7 +20,7 @@ import 'layout_service.dart';
/// [downloadAssetFonts] with it to register fonts declared in the
/// font manifest. If test fonts are enabled, then call
/// [debugDownloadTestFonts] as well.
class HtmlFontCollection implements FontCollection {
class HtmlFontCollection implements FlutterFontCollection {
FontManager? _assetFontManager;
FontManager? _testFontManager;