Ejemplo n.º 1
0
 public FadeAnimation(MainWindow window, double to, double duration, Action onFadeEnded = null)
 {
     To = to;
     Duration = new Duration(TimeSpan.FromSeconds(duration));
     if (onFadeEnded != null)
     {
         Completed += (s, e) => onFadeEnded();
     }
 }
Ejemplo n.º 2
0
        private void OnStartup(object sender, StartupEventArgs e)
        {
            MainWindow window = null;
            if ( e.Args.Length == 0 )
            {
                window = new MainWindow();
            }
            else
            {
                var adventureFilePath = e.Args[0];
                window = new MainWindow(adventureFilePath);
            }

            window.Show();
        }