Interaction logic for IntroductionView.xaml
Наследование: System.Windows.Controls.UserControl
Пример #1
0
        public MainWindow(IInstallerFactory installerFactory, Version version, Action exit, string logPath)
        {
            _installerFactory = installerFactory;
            _exit             = exit;
            _logPath          = logPath;

            InitializeComponent();
            Title      += " " + version.ToString(3) + " installer";
            DataContext = this;

            var introductionView = new IntroductionView();

            introductionView.OnInstall += (sender, args) =>
            {
                var progress = StartInstallation(installerFactory);
                InnerContent = progress;
            };

            introductionView.OnCancel += (sender, args) =>
            {
                Cancel();
            };

            InnerContent = introductionView;
        }
Пример #2
0
        public MainWindow(IInstallerFactory installerFactory, Version version, Action exit, string logPath)
        {
            _installerFactory = installerFactory;
            _exit = exit;
            _logPath = logPath;

            InitializeComponent();
            Title += " " + version.ToString(3) + " beta installer";
            DataContext = this;

            var introductionView = new IntroductionView();
            introductionView.OnInstall += (sender, args) =>
            {
                var progress = StartInstallation(installerFactory);
                InnerContent = progress;
            };

            introductionView.OnCancel += (sender, args) =>
            {
                Cancel();
            };

            InnerContent = introductionView;
        }