Exemplo n.º 1
0
        public ColorPicker(Location location, PropertyInfo ColorProperty, object colorPropertyContainingObject) : base(location, null)
        {
            this.ColorProperty = ColorProperty;
            this.colorPropertyContainingObject = colorPropertyContainingObject;
            InitKeyColors();

            Dimensions = new SimpleDimensions(WIDTH, HEIGHT);
            Textbox colorPickerText = new Textbox(SimpleLocation.Zero, null, Strings.color_picker_text, DefaultUIValues.Default.DefaultEditorControlSpriteFont);

            AddConstantComponent(colorPickerText);

            InitColorButtons();
        }
Exemplo n.º 2
0
        public IndexPicker(Location location, PropertyInfo indexProperty, object indexPropertyContainingObject) : base(location, null)
        {
            this.indexProperty = indexProperty;
            this.indexPropertyContainingObject = indexPropertyContainingObject;

            InitIndices();

            indexButtons = new TextureButton[selectableIndices.Count];

            Dimensions = new SimpleDimensions(WIDTH, HEIGHT);
            AddConstantComponent(new Textbox(SimpleLocation.Zero, null, Strings.index_picker_text, DefaultUIValues.Default.DefaultEditorControlSpriteFont));

            InitIndexButtons();
        }