Ejemplo n.º 1
0
        public CrayonWindow(CrayonBoundUserInterface owner)
        {
            MinSize = SetSize = (250, 300);
            Title   = Loc.GetString("crayon-window-title");
            Owner   = owner;

            var vbox = new BoxContainer
            {
                Orientation = LayoutOrientation.Vertical
            };

            Contents.AddChild(vbox);

            _search = new LineEdit();
            _search.OnTextChanged += (_) => RefreshList();
            vbox.AddChild(_search);

            _grid = new GridContainer()
            {
                Columns = 6,
            };
            var gridScroll = new ScrollContainer()
            {
                VerticalExpand = true,
                Children       =
                {
                    _grid
                }
            };

            vbox.AddChild(gridScroll);
        }
Ejemplo n.º 2
0
        public CrayonWindow(CrayonBoundUserInterface owner)
        {
            RobustXamlLoader.Load(this);

            Owner = owner;

            Search.OnTextChanged += _ => RefreshList();
        }