/// <summary> /// Constructor /// </summary> /// <param name="theChatWindow">The chat window to print info to</param> /// <param name="thePipeMessageSender">The PipeMessage sending interface</param> public PipeGameBaseForm(IClientChatWindow theChatWindow, IPipeMessageSender thePipeMessageSender) { ChatWindow = theChatWindow; PipeSender = thePipeMessageSender; // Create the handle so we can make changes to the form before it is shown CreateHandle(); this.FormClosing += OnFormClosing; }
/// <summary> /// Constructor /// </summary> public FormClient(IPipeMessageSender thePipeMessageSender) { PipeSender = thePipeMessageSender; InitializeComponent(); this.FormClosing += FormClient_FormClosing; // Initialize the pipe connection object itsInputTextBox.KeyDown += ItsInput_KeyDown; //Initialize the User List form itsUserListForm = new UserListForm(this, PipeSender); itsUserListForm.FormClosing += ItsUserListForm_FormClosing; // Initialize the Image Sharing form itsImageShareForm = new ImageSharingForm(this, PipeSender); itsImageShareForm.FormClosing += ItsImageShareForm_FormClosing; // Initialize the Number Game form itsNumberGameForm = new NumberGameForm(this, PipeSender); itsNumberGameForm.FormClosing += ItsNumberGameForm_FormClosing; }
/// <summary> /// Constructor /// </summary> /// <param name="theChatWindow">The chat window to print info to</param> /// <param name="thePipeMessageSender">The PipeMessage sending interface</param> public UserListForm(IClientChatWindow theChatWindow, IPipeMessageSender thePipeMessageSender) : base(theChatWindow, thePipeMessageSender) { InitializeComponent(); }
/// <summary> /// Constructor /// </summary> /// <param name="theChatWindow">The chat window to print info to</param> /// <param name="thePipeMessageSender">The PipeMessage sending interface</param> public ImageSharingForm(IClientChatWindow theChatWindow, IPipeMessageSender thePipeMessageSender) : base(theChatWindow, thePipeMessageSender) { InitializeComponent(); this.itsLabelFileName.Text = string.Empty; this.itsLabelSenderName.Text = string.Empty; }
/// <summary> /// Constructor /// </summary> /// <param name="theChatWindow">The chat window to print info to</param> /// <param name="thePipeMessageSender">The PipeMessage sending interface</param> public NumberGameForm(IClientChatWindow theChatWindow, IPipeMessageSender thePipeMessageSender) : base(theChatWindow, thePipeMessageSender) { InitializeComponent(); }
public void Start(IPipeMessageSender thePipeMessageSender) { itsFormClient = new FormClient(thePipeMessageSender); itsFormClient.Show(); itsFormClient.FormClosing += FormClient_FormClosing; }