示例#1
0
 private static SidebarPanel CreatePanel(string text, Control contents, bool insert = false)
 {
     var panel = new SidebarPanel { Text = text, Name = text, Dock = DockStyle.Fill, Hidden = !Expanded(text) };
     panel.AddControl(contents);
     if (insert) _container.Insert(panel, _container.Count() - 1);
     else _container.Add(panel);
     return panel;
 }
示例#2
0
        private static void CreatePanel(string text, Control contents)
        {
            var panel = new SidebarPanel {
                Text = text, Dock = DockStyle.Fill, Hidden = !Expanded(text)
            };

            panel.AddControl(contents);
            _container.Add(panel);
        }
示例#3
0
        private static SidebarPanel CreatePanel(string text, Control contents, bool insert = false)
        {
            var panel = new SidebarPanel {
                Text = text, Name = text, Dock = DockStyle.Fill, Hidden = !Expanded(text)
            };

            panel.AddControl(contents);
            if (insert)
            {
                _container.Insert(panel, _container.Count() - 1);
            }
            else
            {
                _container.Add(panel);
            }
            return(panel);
        }
示例#4
0
 private static void CreatePanel(string text, Control contents)
 {
     var panel = new SidebarPanel { Text = text, Dock = DockStyle.Fill, Hidden = !Expanded(text) };
     panel.AddControl(contents);
     _container.Add(panel);
 }