internal ItemGroupElement(ItemGroup parentGroup, string text, object userObject, int nestingLevel) { _text = text; _parentGroup = parentGroup; _iconVisible = _visible = true; UserObject = userObject; NestingLevel = nestingLevel; IconCursor = Cursors.Default; Elements = new ItemGroupElementsList(ParentGroup, this, NestingLevel + 1); }
internal ItemGroup(ItemGroupsList parentGroupsList, string caption, ImageList imageList, int iconIndex) { _caption = caption; _iconVisible = _visible = true; _parentGroupsList = parentGroupsList; if (imageList != null && iconIndex >= 0 && iconIndex < imageList.Images.Count) { Icon = new Bitmap(imageList.Images[iconIndex]); } Elements = new ItemGroupElementsList(this, null, 0); }