This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<title>3D Viewer: ACME Site</title> | |
</head> | |
<body style="margin: 0px;"> | |
<iframe style="border: none; outline: none; overflow: hidden;" width="100%" height="100%" src="https://viewer.ctech.com/envirofaux.html?title=3D%20Viewer%3A%20ACME%20Site&logo=https%3A%2F%2Fenvirofaux.com%2FACME-EnviroFaux.png" allow="fullscreen"></iframe> | |
</body> | |
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12/17/2020 | 1928 | Child in snow | |
---|---|---|---|
12/17/2020 | 1929 | Child grabbing snow | |
12/17/2020 | 1930 | Snowball being formed | |
12/17/2020 | 1931 | Snowball flinging towards tree | |
12/17/2020 | 1932 | Tree gets hit | |
12/17/2020 | 1933 | Tree vibrates | |
12/17/2020 | 1934 | Snow falls off branches | |
12/17/2020 | 1935 | Snow lands on child and dog | |
12/17/2020 | 1936 | The dog wimpers, then says "Woof" | |
12/17/2020 | 1937 | The child hugs dog |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Seq.fold : ('State -> 'T -> 'State) -> 'State -> seq<'T> -> 'State |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[<STAThread>] | |
[<EntryPoint>] | |
let main _ = | |
let app () = | |
AppBuilder.Configure<App>().UsePlatformDetect().LogToDebug().SetupWithoutStarting().Instance | |
let nav = Gjallarhorn.Avalonia.Navigation.singleView app MainWindow | |
let app' = Program.application nav.Navigate | |
Gjallarhorn.Avalonia.Framework.RunApplication<Forest,unit,ForestMessage> (nav, app') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let application nav = | |
// Start pruning "loop" via Executor type | |
let prune = new Executor<_,_>(pruneHandler) | |
prune.Start() | |
// Start our application, and attach the executor so messages dispatch to the application | |
Framework.application Forest.empty Forest.update forestComponent nav | |
|> Framework.withDispatcher prune |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void Main() | |
{ | |
IMsg test = new S2("foo", "bar"); | |
switch (test) | |
{ | |
// How do I simplify this??? I'd like to "match and deconstruct" as a oneliner if possible | |
case S1 s1: | |
{ | |
int foo = s1.Data; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let application = | |
// Create our forest, wrapped in a mutable with an atomic update function | |
let forest = new AsyncMutable<_>(Forest.empty) | |
// Create our 3 functions for the application framework | |
// Start with the function to create our model (as an ISignal<'a>) | |
let createModel () : ISignal<_> = forest :> _ | |
// Create a function that updates our state given a message |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type ForestUpdate = | |
| Add of Tree * Forest | |
| Decorate of Tree * Forest | |
type ForestUpdateResult = | |
| Success of Forest | |
| Pruned of Forest | |
| Error of string | |
module ForestManager = |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// <summary> | |
/// An <see cref="ICommand"/> whose delegates do not take any parameters for <see cref="Execute"/> and <see cref="CanExecute"/>. | |
/// </summary> | |
public class ActionCommand : DelegateCommandBase | |
{ | |
/// <summary> | |
/// Initializes a new instance of the <see cref="ActionCommand"/> class with the <see cref="Action"/> to invoke on execution. | |
/// </summary> | |
/// <param name="executeMethod">The execute method.</param> | |
/// <param name="useCommandManager">if set to <c>true</c> use the command manager instead of our own event process for CanExecuteChanged Tracking.</param> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Threading; | |
public sealed class RwLock : IDisposable | |
{ | |
private readonly ReaderWriterLockSlim _innerLock = new ReaderWriterLockSlim(); | |
private bool _disposed = false; | |
public IDisposable Read() | |
{ |
NewerOlder