Пример #1
0
        static void AddButton(MenuCommand menuCommand)
        {
            var go = DefaultControls.CreateButton(
                LoadResource <Sprite>("Button.png"),
                LoadResource <Font>("DejaVuSans-ExtraLight.ttf")
                );

            PlaceUIElementRoot(go, menuCommand);
        }
Пример #2
0
        static void AddToggle(MenuCommand menuCommand)
        {
            var go = DefaultControls.CreateToggle(
                LoadResource <Sprite>("Toggle.png"),
                LoadResource <Sprite>("Toggle Fill.png"),
                LoadResource <Font>("DejaVuSans-ExtraLight.ttf")
                );

            PlaceUIElementRoot(go, menuCommand);
        }
Пример #3
0
        static void AddKnob(MenuCommand menuCommand)
        {
            var go = DefaultControls.CreateKnob(
                LoadResource <Material>("Knob.mat"),
                LoadResource <Sprite>("Knob.png"),
                LoadResource <Font>("DejaVuSans-ExtraLight.ttf")
                );

            PlaceUIElementRoot(go, menuCommand);
        }