Commit 3bc3d4a5 authored by xster's avatar xster Committed by GitHub

Remove various roboto font logic (#8350)

parent 41edc1ac
......@@ -329,7 +329,6 @@ class FlutterTask extends DefaultTask {
args "--kernel", kernelFile.absolutePath
}
args "--output-file", "${intermediateDir}/app.flx"
args "--no-include-roboto-fonts"
if (buildMode != "debug") {
args "--precompiled"
} else {
......
......@@ -23,7 +23,6 @@ class AssetBundle {
static const String _kAssetManifestJson = 'AssetManifest.json';
static const String _kFontManifestJson = 'FontManifest.json';
static const String _kFontSetMaterial = 'material';
static const String _kFontSetRoboto = 'roboto';
static const String _kLICENSE = 'LICENSE';
bool _fixed = false;
......@@ -69,7 +68,6 @@ class AssetBundle {
String workingDirPath,
String packagesPath,
bool includeDefaultFonts: true,
bool includeRobotoFonts: true,
bool reportLicensedPackages: false
}) async {
workingDirPath ??= getAssetBuildDirectory();
......@@ -126,8 +124,6 @@ class AssetBundle {
final List<_Asset> materialAssets = <_Asset>[];
if (usesMaterialDesign && includeDefaultFonts) {
materialAssets.addAll(_getMaterialAssets(_kFontSetMaterial));
if (includeRobotoFonts)
materialAssets.addAll(_getMaterialAssets(_kFontSetRoboto));
}
for (_Asset asset in materialAssets) {
assert(asset.assetFileExists);
......@@ -137,7 +133,7 @@ class AssetBundle {
entries[_kAssetManifestJson] = _createAssetManifest(assetVariants);
final DevFSContent fontManifest =
_createFontManifest(manifestDescriptor, usesMaterialDesign, includeDefaultFonts, includeRobotoFonts);
_createFontManifest(manifestDescriptor, usesMaterialDesign, includeDefaultFonts);
if (fontManifest != null)
entries[_kFontManifestJson] = fontManifest;
......@@ -305,13 +301,10 @@ DevFSContent _createAssetManifest(Map<_Asset, List<_Asset>> assetVariants) {
DevFSContent _createFontManifest(Map<String, dynamic> manifestDescriptor,
bool usesMaterialDesign,
bool includeDefaultFonts,
bool includeRobotoFonts) {
bool includeDefaultFonts) {
final List<Map<String, dynamic>> fonts = <Map<String, dynamic>>[];
if (usesMaterialDesign && includeDefaultFonts) {
fonts.addAll(_getMaterialFonts(AssetBundle._kFontSetMaterial));
if (includeRobotoFonts)
fonts.addAll(_getMaterialFonts(AssetBundle._kFontSetRoboto));
}
if (manifestDescriptor != null && manifestDescriptor.containsKey('fonts'))
fonts.addAll(manifestDescriptor['fonts']);
......
......@@ -22,7 +22,6 @@ class BuildFlxCommand extends BuildSubCommand {
argParser.addOption('depfile', defaultsTo: defaultDepfilePath);
argParser.addOption('kernel');
argParser.addOption('working-dir', defaultsTo: getAssetBuildDirectory());
argParser.addFlag('include-roboto-fonts', defaultsTo: true);
argParser.addFlag('report-licensed-packages', help: 'Whether to report the names of all the packages that are included in the application\'s LICENSE file.', defaultsTo: false);
usesPubOption();
}
......@@ -52,7 +51,6 @@ class BuildFlxCommand extends BuildSubCommand {
workingDirPath: argResults['working-dir'],
kernelPath: argResults['kernel'],
precompiledSnapshot: argResults['precompiled'],
includeRobotoFonts: argResults['include-roboto-fonts'],
reportLicensedPackages: argResults['report-licensed-packages']
);
}
......
......@@ -66,7 +66,6 @@ Future<Null> build({
String packagesPath,
String kernelPath,
bool precompiledSnapshot: false,
bool includeRobotoFonts: true,
bool reportLicensedPackages: false
}) async {
outputPath ??= defaultFlxOutputPath;
......@@ -105,7 +104,6 @@ Future<Null> build({
privateKeyPath: privateKeyPath,
workingDirPath: workingDirPath,
packagesPath: packagesPath,
includeRobotoFonts: includeRobotoFonts,
reportLicensedPackages: reportLicensedPackages
).then((_) => null);
}
......@@ -119,7 +117,6 @@ Future<List<String>> assemble({
String workingDirPath,
String packagesPath,
bool includeDefaultFonts: true,
bool includeRobotoFonts: true,
bool reportLicensedPackages: false
}) async {
outputPath ??= defaultFlxOutputPath;
......@@ -134,7 +131,6 @@ Future<List<String>> assemble({
workingDirPath: workingDirPath,
packagesPath: packagesPath,
includeDefaultFonts: includeDefaultFonts,
includeRobotoFonts: includeRobotoFonts,
reportLicensedPackages: reportLicensedPackages
);
if (result != 0)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment