private void InitializeSecurityOptionsView(string ServerDirectory, SecurityOptionsView securityOptionsView, SecurityOptionsPresenter securityOptionsPresenter) { if (!string.IsNullOrEmpty(ServerDirectory)) { AdvancedSettings settings = AdvancedSettings.Open(ServerDirectory); securityOptionsPresenter.RunView(securityOptionsView, settings); } else { securityOptionsPresenter.RunView(securityOptionsView, null); } }
private void InitializeSecurityOptionsView(SecurityOptionsView securityOptionsView, SecurityOptionsPresenter securityOptionsPresenter) { if (ServerState.Instance.ServerService != null) { AdvancedSettings settings = AdvancedSettings.Open(ServerState.Instance.ServerService.ServiceDirectory); securityOptionsPresenter.RunView(securityOptionsView, settings); } else { securityOptionsPresenter.RunView(securityOptionsView, null); } __SecurityOptionsPresenter = securityOptionsPresenter; }
private void Init() { try { _client = new ClientConfiguration(); _servers = new DICOMServers(); _securityOptionsView = new SecurityOptionsView(); _securityOptionsPresenter = new SecurityOptionsPresenter(); _securityOptionsPresenter.WriteSecurityOptionsEvent += _securityOptionsPresenter_WriteSecurityOptionsEvent; _securityOptionsPresenter.ReadSecurityOptionsEvent += _securityOptionsPresenter_ReadSecurityOptionsEvent; _securityOptionsPresenter.SettingsChanged += _securityOptionsPresenter_SettingsChanged; _securityOptionsPresenter.RunView(_securityOptionsView); CanViewPACSConfig = true; ConfigurationTabControl.TabPages[0].Controls.Add(_client); ConfigurationTabControl.TabPages[1].Controls.Add(_servers); _client.Dock = DockStyle.Fill; _servers.Dock = DockStyle.Fill; _securityOptionsView.Dock = DockStyle.Top; WorkstationToolStrip.CausesValidation = true; this.Load += new EventHandler(WorkstationConfiguration_Load); } catch (Exception exception) { System.Diagnostics.Debug.Assert(false, exception.Message); throw exception; } }