public void Apply()
 {
     _withinRange = GetModdablesWithinRange(Range, TargetLayer);
     foreach (IModdable moddable in _withinRange)
     {
         Modifier.AddTo(moddable, this);
         OnApplied?.Invoke(moddable);
     }
 }
예제 #2
0
        private void button1_Click(object sender, EventArgs e)
        {
            try
            {
                if (tbThreshold.Text == string.Empty)
                {
                    MessageBox.Show("Please enter threshold value");
                    return;
                }
                var threshold = float.Parse(tbThreshold.Text, CultureInfo.InvariantCulture);
                cvsHelperClass.WriteConfigParameters("shapeThreshold", threshold.ToString());

                OnApplied?.Invoke(threshold);
            }
            catch (Exception)
            {
                MessageBox.Show("Please enter threshold value");
            }
        }
예제 #3
0
 private void button1_Click(object sender, EventArgs e)
 {
     OnApplied?.Invoke(trackBar1.Value);
 }
 public void Apply()
 {
     _modifier.AddTo(GetTarget(), this);
     OnApplied?.Invoke(GetTarget());
 }
 public virtual void Apply()
 {
     OnApplied?.Invoke();
 }