Example #1
0
        void createButton()
        {
            string label = "Play Audio";

            if (mLabelNum > 1)
            {
                label += " " + mLabelNum;
            }
            ControlPanel.AddSlider(mButton = new Button()
            {
                Text = label
            });
            mButton.Click += new EventHandler((s, e) => {
                play();
            });
        }
Example #2
0
        void createSlider()
        {
            ControlPanel.AddSlider(mLabel = new Label()
            {
                TextAlign = ContentAlignment.BottomLeft,
                Text      = ReferenceName
            });
            int value = (int)(mPosition * 100);

            ControlPanel.AddSlider(mSlider = new TrackBar()
            {
                Minimum       = 0,
                Maximum       = 100,
                SmallChange   = 1,
                LargeChange   = 5,
                TickFrequency = 10,
                Value         = value,
                Width         = 175
            });
            mSlider.ValueChanged += new EventHandler((s, e) => { execute(); });
        }