Пример #1
0
 public EditMovie(MovieName movie)
 {
     DataContext = this;
     _oldMovie   = movie;
     Movie       = new MovieName(movie);
     InitializeComponent();
 }
Пример #2
0
        public void CopyProperties(MovieName movie)
        {
            this.Name = movie.Name;

            this.Director    = movie.Director;
            this.GenrePick   = movie.GenrePick;
            this.ReleaseDate = movie.ReleaseDate;
        }
Пример #3
0
        public AddMovie()
        {
            OkCommand     = new DelegateCommand(Ok);
            CancelCommand = new DelegateCommand(Cancel);

            AddMovieName = new MovieName();

            InitializeComponent();
        }
        public AddorEdit(MovieName movie)
        {
            DataContext = this;
            _oldMovie   = movie;

            if (movie == null)
            {
                Movie = new MovieName();
            }
            else
            {
                Movie = new MovieName(movie);
            }

            InitializeComponent();
        }
Пример #5
0
 public MovieName(MovieName newMovie)
 {
     CopyProperties(newMovie);
 }