Beispiel #1
0
        protected override void SetupControls()
        {
            EditorStateBinder binder = EditorStateBinder.FromState(this.EditorState);

            binder.BindStringTextBox(this.prefsPlayerTextBox, PROP(s => s.Prefs.PlayerProfile), false);
            binder.BindCheckBox(this.prefsUsetexcolorsCheckBox, PROP(s => s.Toggles.UseTexColors), false);
            binder.BindComboBox <InformationLevel>(this.prefsInformationLevelComboBox, PROP(s => s.Prefs.MessageLevel));
            binder.BindCheckBox(this.prefsSplashscreenCheckBox, PROP(s => s.Prefs.ShowSplash), false);
        }
        protected override void SetupControls()
        {
            EditorStateBinder binder = EditorStateBinder.FromState(this.EditorState);

            binder.BindComboBox(this.segmentIdComboBox,
                                PROP(s => s.Level.Segments.Items), PROP(s => s.CurrentSelection.Segment));
            binder.BindComboBox <SegFunction>(this.segmentFunctionComboBox,
                                              PROP(s => s.CurrentSelection.Segment.Function));
            binder.BindRadioButton(this.segmentSide1RadioButton, PROP(s => s.CurrentSelection.SideNum), 0);
            binder.BindRadioButton(this.segmentSide2RadioButton, PROP(s => s.CurrentSelection.SideNum), 1);
            binder.BindRadioButton(this.segmentSide3RadioButton, PROP(s => s.CurrentSelection.SideNum), 2);
            binder.BindRadioButton(this.segmentSide4RadioButton, PROP(s => s.CurrentSelection.SideNum), 3);
            binder.BindRadioButton(this.segmentSide5RadioButton, PROP(s => s.CurrentSelection.SideNum), 4);
            binder.BindRadioButton(this.segmentSide6RadioButton, PROP(s => s.CurrentSelection.SideNum), 5);
            binder.BindRadioButton(this.segmentPoint1RadioButton, PROP(s => s.CurrentSelection.PointNum), 0);
            binder.BindRadioButton(this.segmentPoint2RadioButton, PROP(s => s.CurrentSelection.PointNum), 1);
            binder.BindRadioButton(this.segmentPoint3RadioButton, PROP(s => s.CurrentSelection.PointNum), 2);
            binder.BindRadioButton(this.segmentPoint4RadioButton, PROP(s => s.CurrentSelection.PointNum), 3);
            binder.BindFloatTextBox(this.segmentPointxTextBox, PROP(s => s.CurrentSelection.Point.X), false);
            binder.BindFloatTextBox(this.segmentPointyTextBox, PROP(s => s.CurrentSelection.Point.Y), false);
            binder.BindFloatTextBox(this.segmentPointzTextBox, PROP(s => s.CurrentSelection.Point.Z), false);
        }
        protected override void SetupControls()
        {
            EditorStateBinder binder = EditorStateBinder.FromState(this.EditorState);

            prefsViewdistTrackBar.Maximum = EditorSettings.MaximumMineRenderDepth;

            binder.BindRadioButton(this.prefsRenderer3RdPersonRadioButton, PROP(s => s.Prefs.Perspective), PerspectiveMode.ThirdPerson);
            binder.BindRadioButton(this.prefsRenderer3RdPersonRadioButton, PROP(s => s.Prefs.Perspective), PerspectiveMode.FirstPerson);
            binder.BindRadioButton(this.prefsDepthOffRadioButton, PROP(s => s.Prefs.DepthPerception), DetailLevel.None);
            binder.BindRadioButton(this.prefsDepthLowRadioButton, PROP(s => s.Prefs.DepthPerception), DetailLevel.Low);
            binder.BindRadioButton(this.prefsDepthMediumRadioButton, PROP(s => s.Prefs.DepthPerception), DetailLevel.Medium);
            binder.BindRadioButton(this.prefsDepthHighRadioButton, PROP(s => s.Prefs.DepthPerception), DetailLevel.High);
            binder.BindComboBox <MineCenterDisplayShape>(this.prefsMinecenterComboBox, PROP(s => s.Prefs.MineCenterDisplay));
            binder.BindTrackBar(this.prefsViewdistTrackBar, PROP(s => s.Prefs.ViewDepth));
        }