SimpleBox panel; //panel public TreeView(int width, int height) : base(width, height) { //panel for listview items this.panel = new SimpleBox(width, height); panel.ContentLayoutKind = BoxContentLayoutKind.VerticalStack; panel.BackColor = Color.LightGray; uiList = new UICollection(this); uiList.AddUI(panel); }
public ListView(int width, int height) : base(width, height) { uiList = new UICollection(this); //panel for listview items // var simpleBox = new SimpleBox(width, height); simpleBox.ContentLayoutKind = BoxContentLayoutKind.VerticalStack; simpleBox.BackColor = Color.LightGray; simpleBox.MouseDown += panel_MouseDown; simpleBox.MouseDoubleClick += panel_MouseDoubleClick; simpleBox.AcceptKeyboardFocus = true; simpleBox.KeyDown += simpleBox_KeyDown; this.panel = simpleBox; uiList.AddUI(panel); }