示例#1
0
        private static SetSuffix <TParam> BuildBasicSetSuffix <TParam>() where TParam : Encapsulation.Structure
        {
            var basicInstance = new StrongBox <TParam>(default(TParam));

            SuffixSetDlg <TParam> setter = value => basicInstance.Value = value;
            SuffixGetDlg <TParam> getter = () => basicInstance.Value;

            return(new SetSuffix <TParam>(getter, setter));
        }
示例#2
0
        private static SetSuffix<TParam> BuildBasicSetSuffix<TParam>()
        {
            var basicInstance = new StrongBox<TParam>(default(TParam));

            SuffixSetDlg<TParam> setter = value => basicInstance.Value = value;
            SuffixGetDlg<TParam> getter = () => basicInstance.Value;

            return new SetSuffix<TParam>(getter, setter);
        }
示例#3
0
 public SetSuffix(SuffixGetDlg <TValue> getter, SuffixSetDlg <TValue> setter, string description = "")
     : base(getter, description)
 {
     this.setter = setter;
 }
示例#4
0
 public ClampSetSuffix(SuffixGetDlg <TValue> getter, SuffixSetDlg <TValue> setter, double min, double max, string description = "")
     : base(getter, setter, description)
 {
     this.min = min;
     this.max = max;
 }
示例#5
0
 public ClampSetSuffix(SuffixGetDlg <TValue> getter, SuffixSetDlg <TValue> setter, double min, double max, float stepIncrement, string description = "")
     : this(getter, setter, min, max, description)
 {
     this.stepIncrement = stepIncrement;
 }
示例#6
0
 public Suffix(SuffixGetDlg <TReturn> getter, string description = "") : base(description)
 {
     this.getter = getter;
 }
        private static SuffixGetDlg <TParam> BuildBasicGetter <TParam>(StrongBox <TParam> state)
        {
            SuffixGetDlg <TParam> getter = () => state.Value;

            return(getter);
        }
示例#8
0
        private static SuffixGetDlg <TParam> BuildBasicGetter <TParam>(StrongBox <TParam> state) where TParam : Encapsulation.Structure
        {
            SuffixGetDlg <TParam> getter = () => state.Value;

            return(getter);
        }