/// <summary> /// Builds the settings for a TreeNode and adds them to the Tag as SectionDetails. /// </summary> private void BuildSettings(TreeNode node) { if (node.Tag == null || !(node.Tag is SectionDetails)) { return; } SectionDetails sectionTag = (SectionDetails)node.Tag; sectionTag.RightToLeft = _rightToLeft; sectionTag.Width = _panelSectionSettings.Width; // Create controls FormDesigner designer = new FormDesigner(GetSectionPath(node)); designer.Help = _help; designer.ConfigChangedHandler = UpdateConfigItem; designer.YesNoChange = YesNoChange; designer.MultiSelectionListChange = MultiSelectionListChange; designer.SingleSelectionListChange = SingleSelectionListChange; designer.ListBoxSelectionChange = ListSelectionChanged; designer.ButtonClick = ButtonClicked; designer.EntryLeave = EntryChange; designer.NumUpDownChanged = NumUpDownChanged; sectionTag.Control = designer.BuildToPanel(_rightToLeft, _panelSectionSettings.Width); sectionTag.Designed = true; node.Tag = sectionTag; }
/// <summary> /// Builds the settings for a TreeNode and adds them to the Tag as SectionDetails. /// </summary> private void BuildSettings(TreeNode node) { if (node.Tag == null || !(node.Tag is SectionDetails)) return; SectionDetails sectionTag = (SectionDetails)node.Tag; sectionTag.RightToLeft = _rightToLeft; sectionTag.Width = _panelSectionSettings.Width; // Create controls FormDesigner designer = new FormDesigner(GetSectionPath(node)); designer.Help = _help; designer.ConfigChangedHandler = UpdateConfigItem; designer.YesNoChange = YesNoChange; designer.MultiSelectionListChange = MultiSelectionListChange; designer.SingleSelectionListChange = SingleSelectionListChange; designer.ListBoxSelectionChange = ListSelectionChanged; designer.ButtonClick = ButtonClicked; designer.EntryLeave = EntryChange; designer.NumUpDownChanged = NumUpDownChanged; sectionTag.Control = designer.BuildToPanel(_rightToLeft, _panelSectionSettings.Width); sectionTag.Designed = true; node.Tag = sectionTag; }