Пример #1
0
        /// ------------------------------------------------------------------------------------
        public SessionsListScreen(ElementListViewModel <Session> presentationModel,
                                  NewSessionsFromFileDlgViewModel.Factory newSessionsFromFileDlgViewModel,
                                  SessionsGrid.Factory sessionGridFactory)
            : base(presentationModel)
        {
            Logger.WriteEvent("PersonListScreen constructor");

            _elementsGrid      = sessionGridFactory();
            _elementsGrid.Name = "SessionsGrid";
            _newSessionsFromFileDlgViewModel = newSessionsFromFileDlgViewModel;
            InitializeComponent();

            if (DesignMode)
            {
                return;
            }

            Initialize(_componentsSplitter.Panel2, _sessionComponentFileGrid, _sessionsListPanel);
            _sessionComponentFileGrid.InitializeGrid("SessionScreen");

            _elementsListPanel.InsertButton(1, _buttonNewFromFiles);
            _elementsListPanel.InsertButton(2, _buttonNewFromRecording);

            InitializeMenus();

            if (_componentsSplitter.Panel2.Controls.Count > 1)
            {
                _labelClickNewHelpPrompt.Visible = false;
            }
            else
            {
                _componentsSplitter.Panel2.ControlAdded += HandleFirstSetOfComponentEditorsAdded;
            }

            _componentsSplitter.Panel2.ControlRemoved += HandleLastSetOfComponentEditorsRemoved;

            _elementsListPanel.ButtonPanelBackColor1     = Settings.Default.SessionEditorsButtonBackgroundColor1;
            _elementsListPanel.ButtonPanelBackColor2     = Settings.Default.SessionEditorsButtonBackgroundColor2;
            _elementsListPanel.ButtonPanelTopBorderColor = Settings.Default.SessionEditorsBorderColor;

            _elementsListPanel.HeaderPanelBackColor1        = Settings.Default.SessionEditorsButtonBackgroundColor2;
            _elementsListPanel.HeaderPanelBackColor2        = Settings.Default.SessionEditorsButtonBackgroundColor1;
            _elementsListPanel.HeaderPanelBottomBorderColor = Settings.Default.SessionEditorsBorderColor;
        }
Пример #2
0
        /// ------------------------------------------------------------------------------------
        public PersonListScreen(ElementListViewModel <Person> presentationModel,
                                PersonGrid.Factory personGridFactory) : base(presentationModel)
        {
            Logger.WriteEvent("PersonListScreen constructor");

            _elementsGrid      = personGridFactory();
            _elementsGrid.Name = "PersonGrid";
            InitializeComponent();

            if (DesignMode)
            {
                return;
            }

            Initialize(_componentsSplitter.Panel2, _personComponentFileGrid, _peopleListPanel);
            _personComponentFileGrid.InitializeGrid("PersonScreen");

            InitializeMenus();

            if (_componentsSplitter.Panel2.Controls.Count > 1)
            {
                _labelClickNewHelpPrompt.Visible = false;
            }
            else
            {
                _componentsSplitter.Panel2.ControlAdded += HandleFirstSetOfComponentEditorsAdded;
            }

            _componentsSplitter.Panel2.ControlRemoved += HandleLastSetOfComponentEditorsRemoved;

            _elementsListPanel.ButtonPanelBackColor1     = Settings.Default.PersonEditorsButtonBackgroundColor1;
            _elementsListPanel.ButtonPanelBackColor2     = Settings.Default.PersonEditorsButtonBackgroundColor2;
            _elementsListPanel.ButtonPanelTopBorderColor = Settings.Default.PersonEditorsBorderColor;

            _elementsListPanel.HeaderPanelBackColor1        = Settings.Default.PersonEditorsButtonBackgroundColor2;
            _elementsListPanel.HeaderPanelBackColor2        = Settings.Default.PersonEditorsButtonBackgroundColor1;
            _elementsListPanel.HeaderPanelBottomBorderColor = Settings.Default.PersonEditorsBorderColor;
        }
Пример #3
0
 public ConcretePersonListScreen(ElementListViewModel <Person> presentationModel)
     : base(presentationModel)
 {
 }
Пример #4
0
 /// ------------------------------------------------------------------------------------
 public ElementListScreen(ElementListViewModel <T> presentationModel)
 {
     _model       = presentationModel;
     MainMenuItem = new ToolStripMenuItem();
 }
Пример #5
0
 public ConcreteSessionScreen(ElementListViewModel <Session> presentationModel)
     : base(presentationModel)
 {
 }