예제 #1
0
        private void onEditSwCurveClicked(object sender, RoutedEventArgs e)
        {
            FanConfig       cfg    = new FanConfig(this.Controller.SoftwareFanConfig);
            List <FanPoint> curve  = new List <FanPoint>(cfg.Curve);
            FanCurveEditor  editor = new FanCurveEditor(curve, FanCurveKind.Linear);

            editor.CurveApplied += (s, e2) =>
            {
                cfg.Curve = curve.ToImmutableArray();
                this.Controller.SoftwareFanConfig = cfg;
            };
            editor.ShowDialog();
        }
예제 #2
0
        private void onEditHwCurveClicked(object sender, RoutedEventArgs e)
        {
            FanCurve curve = this.Controller.Aero.Fans.GetFanCurve();

            FanPoint[]     clone  = curve.ToArray();
            FanCurveEditor editor = new FanCurveEditor(clone, FanCurveKind.Step);

            editor.CurveApplied += (s, e2) =>
            {
                for (int i = 0; i < curve.Count; ++i)
                {
                    curve[i] = clone[i];
                }
            };
            editor.ShowDialog();
        }