public ChannelTreeNode(ChannelForm channelWindow) { ChannelWindow = channelWindow; Text = channelWindow.Channel.Name; channelWindow.FormClosed += channelWindow_FormClosed; ContextMenuStrip = new ChannelNodeContextMenu(); ((ChannelNodeContextMenu)ContextMenuStrip).LeaveClick += delegate { ChannelWindow.Close(); }; }