public void Show(string ipAddress, int port, int leaguesID, int roundsID, IProfileRepository profileRepository, IErrorMessagesPresenter errorPresenter, IConnectionRelayer connectionRelayer, IGameMatch gameMatch) { if (connectionDialog != null) { connectionDialog.Close(); } connectionDialog = new ConnectionDialog(ipAddress, port, leaguesID, roundsID, ProfileRepository.Instance, consolePane, this, null); connectionDialog.Owner = this; connectionDialog.Closing += new System.ComponentModel.CancelEventHandler(modalWindow_Closing); connectionDialog.Show(); }
public InitConnection(int leaguesID, int roundsID, IProfileRepository profileRepository, IErrorMessagesPresenter errorPresenter, IConnectionRelayer connectionRelayer, IGameMatch gameMatch) { InitializeComponent(); this.DataContext = this; IpAddress = "Automatic"; this.leaguesID = leaguesID; this.roundsID = roundsID; this.profile = profileRepository; this.errorPresenter = errorPresenter; this.connectionRelayer = connectionRelayer; this.gameMatch = gameMatch; auth = new Authentication(profileRepository.Username, profileRepository.IPAddress); }
public ConnectionDialog(string ipAddress, int port, int leaguesID, int roundsID, IProfileRepository profileRepository, IErrorMessagesPresenter errorPresenter, IConnectionRelayer connectionRelayer, IGameMatch gameMatch) { InitializeComponent(); this.DataContext = this; this.leaguesID = leaguesID; this.roundsID = roundsID; this.profile = profileRepository; this.errorPresenter = errorPresenter; this.connectionRelayer = connectionRelayer; this.port = port; this.ipAddress = ipAddress; this.gameMatch = gameMatch; endTheThread = 0; auth = new Authentication(profileRepository.Username, profileRepository.IPAddress); }
public void Initialize(IErrorMessagesPresenter errorPresenter, IProfileRepository profileRepository, IConnectionRelayer connectionRelayer, IConnectionDialogPresenter connectionDialogPresenter) { this.profile = profileRepository; this.profileRepository = profileRepository; this.errorPresenter = errorPresenter; this.connectionRelayer = connectionRelayer; this.connectionDialogPresenter = connectionDialogPresenter; this.Refresh(); }