Beispiel #1
0
        protected override void OnLoading()
        {
            base.OnLoading();
            var element = Controller.Element;

            _smoothing = MouseWheel.GetSmoothing(element);
            _modifiers = MouseWheel.GetModifiers(element);
            _minimum   = MouseWheel.GetMinimum(element);
            _maximum   = MouseWheel.GetMaximum(element);
            MouseWheel.SmoothingProperty.AddValueChanged(element, OnSmoothingChanged);
            MouseWheel.ModifiersProperty.AddValueChanged(element, OnModifiersChanged);
            MouseWheel.MinimumProperty.AddValueChanged(element, OnMinimumChanged);
            MouseWheel.MaximumProperty.AddValueChanged(element, OnMaximumChanged);
        }
Beispiel #2
0
 private void OnModifiersChanged(object sender, EventArgs e)
 {
     _modifiers = MouseWheel.GetModifiers(sender as DependencyObject);
 }