Skip to content

Commit

Permalink
Revert "chore: Wasm - incomplete"
Browse files Browse the repository at this point in the history
This reverts commit 9155c4b.
  • Loading branch information
Youssef1313 committed Jun 18, 2024
1 parent 9155c4b commit db465d3
Showing 1 changed file with 0 additions and 16 deletions.
16 changes: 0 additions & 16 deletions src/Uno.UI/UI/Xaml/FontFamily.wasm.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,9 @@
using System;
using System.ComponentModel;
using System.Diagnostics.CodeAnalysis;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Threading.Tasks;
using Uno;
using Uno.UI.Xaml.Media;
using Windows.Storage.Helpers;

namespace Microsoft.UI.Xaml.Media
Expand All @@ -16,8 +14,6 @@ public partial class FontFamily
{
private FontFamilyLoader _loader;

private static Assembly _entryAssembly = Assembly.GetEntryAssembly()!;
private static string _entryAssemblyName = _entryAssembly.GetName().Name!;

/// <summary>
/// Contains the font-face name to use in CSS.
Expand Down Expand Up @@ -70,18 +66,6 @@ private static bool TryGetExternalUri(string? source, out Uri? uri)

if (Uno.UI.Xaml.XamlFilePathHelper.TryGetMsAppxAssetPath(uri, out var path))
{
var resourceName = path.Replace('/', '.') + ".manifest";
resourceName = $"{_entryAssemblyName}.{resourceName}";
var manifestStream = _entryAssembly.GetManifestResourceStream(resourceName);
if (manifestStream is not null)
{
uri = new Uri(FontManifestHelpers.GetFamilyNameFromManifest(manifestStream, default, default, default /*weight, style, stretch*/));
if (Uno.UI.Xaml.XamlFilePathHelper.TryGetMsAppxAssetPath(uri, out var path2))
{
path = path2;
}
}

var assetUri = AssetsPathBuilder.BuildAssetUri(path);
uri = new Uri(assetUri, UriKind.RelativeOrAbsolute);
}
Expand Down

0 comments on commit db465d3

Please sign in to comment.