Beispiel #1
0
        public Form3(int id, List <Logic.View> views)
        {
            InitializeComponent();
            _views = views;
            var v = _views.FirstOrDefault(x => x.ID == id);

            if (v == null)
            {
                _view = new Logic.View();
                _views.Add(_view);
            }
            else
            {
                _view = v;
            }

            _view.ID = id;

            if (!string.IsNullOrWhiteSpace(_view.Text))
            {
                richTextBox1.Text = _view.Text;
            }

            if (!string.IsNullOrWhiteSpace(_view.Text))
            {
                pictureBox1.Image = Image.FromFile(_view.PhotoPath) ?? Image.FromFile("");
            }
        }
Beispiel #2
0
        public Form4(Logic.View view)
        {
            InitializeComponent();
            _view = view;

            BatFiles = _view.BatFiles;
        }
Beispiel #3
0
        public Form5(Logic.View view)
        {
            InitializeComponent();

            _view = view;
        }