Exemple #1
0
        private void load(SeeSharpStorage storage)
        {
            var image = Image.Load(Path.Combine(storage.GetStorageForDirectory("pages").GetFullPath(string.Empty), _page.Value.Name));

            FillAspectRatio = (float)image.Width / (float)image.Height;

            foreach (var bar in _page.Value.Bars)
            {
                AddInternal(new ScanLine((float)bar)
                {
                    OnRemove = removeLine
                });
            }
        }
Exemple #2
0
        public static void Main()
        {
            using (GameHost host = Host.GetSuitableHost(@"SeeSharp"))
                using (Game game = new SeeSharp())
                //using (Game game = new SeeSharpTestRunner())
                {
                    var storage      = new SeeSharpStorage(string.Empty, (DesktopGameHost)host);
                    var pageStorage  = storage.GetStorageForDirectory("pages");
                    var textureStore = new LargeTextureStore(new TextureLoaderStore(new StorageBackedResourceStore(pageStorage)));

                    host.Dependencies.Cache(storage);
                    host.Dependencies.Cache(textureStore);

                    host.Run(game);
                }
        }
Exemple #3
0
 protected override bool OnClick(ClickEvent e)
 {
     _storage.GetStorageForDirectory("pages").OpenInNativeExplorer();
     return(true);
 }