public void PositionOptionsChanged(bool top, bool right, bool bottom, bool left)
        {
            var positionOptions = new PositionOptions
            {
                Top = new Location(top),
                Right = new Location(right),
                Bottom = new Location(bottom),
                Left = new Location(left)
            };

            Model.Reposition(positionOptions);
        }
Exemplo n.º 2
0
        public StripedBar()
        {
            _positionInfo = new PositionOptions
            {
                Top = new Location(available: true, selected: true),
                Right = new Location(available: false, selected: false),
                Bottom = new Location(available: true, selected: false),
                Left = new Location(available: false, selected: false)
            };

            Image thumbnailImage = Resources.theme_solid;
            const string friendlyName = "Striped Bar";

            _info = new BarInfo(thumbnailImage, friendlyName);
        }
Exemplo n.º 3
0
        public DottedBar()
        {
            Image thumbnailImage = Resources.theme_dotted;
            const string friendlyName = "Dotted Bar";

            _barInfo = new BarInfo(thumbnailImage, friendlyName);

            _positionOptions = new PositionOptions
            {
                Top = new Location(available: true, selected: true),
                Right = new Location(available: true, selected: false),
                Bottom = new Location(available: true, selected: false),
                Left = new Location(available: true, selected: true)
            };
        }
Exemplo n.º 4
0
        public void Reposition(PositionOptions positionOptions)
        {
            GetCurrentBar().PositionOptions.Top.Selected = positionOptions.Top.Selected;
            GetCurrentBar().PositionOptions.Right.Selected = positionOptions.Right.Selected;
            GetCurrentBar().PositionOptions.Bottom.Selected = positionOptions.Bottom.Selected;
            GetCurrentBar().PositionOptions.Left.Selected = positionOptions.Left.Selected;

            Add(GetCurrentBar());
            AlignmentOptionsChanged(GetCurrentBar().PositionOptions);
        }