Esempio n. 1
0
        public MainWindow()
        {
            InitializeComponent();

            //  We have declared the view model instance declaratively in the xaml.
            //  Get the reference to it here, so we can use it in the button click event.
            _viewModel = (SongViewModel)base.DataContext;
        }
Esempio n. 2
0
        public MainWindow()
        {
            InitializeComponent();

            //  We have declared the view model instance declaratively in the xaml.
            //  Get the reference to it here, so we can use it in the button click event.
            _viewModel = (SongViewModel)base.DataContext;
        }
Esempio n. 3
0
 public MainWindow()
 {
     InitializeComponent();
     _viewModel = base.DataContext as SongViewModel;
 }