A cross-platform UI framework for .NET
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

17 lines
484 B

namespace Perspex.Xaml.Desktop
{
using System;
using System.IO;
using System.Reflection;
using HighLevel;
public class WindowsResourceProvider : IResourceProvider
{
public Stream GetStream(Uri uri)
{
var absoluteUri = new Uri(Assembly.GetExecutingAssembly().Location, UriKind.Absolute);
var finalUri = new Uri(absoluteUri, uri);
return new FileStream(finalUri.LocalPath, FileMode.Open);
}
}
}