Esempio n. 1
0
        /// <summary>
        /// The callback of the Realized event.
        /// </summary>
        /// <since_tizen> preview </since_tizen>
        protected override void OnRealized()
        {
            base.OnRealized();
            _changed     = new SmartEvent(this, this.RealHandle, "changed");
            _changed.On += (s, e) => ValueChanged?.Invoke(this, EventArgs.Empty);

            _delayedChanged     = new SmartEvent(this, this.RealHandle, "delay,changed");
            _delayedChanged.On += (s, e) => DelayedValueChanged?.Invoke(this, EventArgs.Empty);
        }
Esempio n. 2
0
        /// <summary>
        /// Creates and initializes a new instance of the Slider class.
        /// </summary>
        /// <param name="parent">The <see cref="EvasObject"/> to which the new Slider will be attached as a child.</param>
        /// <since_tizen> preview </since_tizen>
        public Slider(EvasObject parent) : base(parent)
        {
            _changed     = new SmartEvent(this, this.RealHandle, "changed");
            _changed.On += (s, e) => ValueChanged?.Invoke(this, EventArgs.Empty);

            _delayedChanged     = new SmartEvent(this, this.RealHandle, "delay,changed");
            _delayedChanged.On += (s, e) => DelayedValueChanged?.Invoke(this, EventArgs.Empty);

            _dragStarted     = new SmartEvent(this, this.RealHandle, "slider,drag,start");
            _dragStarted.On += (s, e) => DragStarted?.Invoke(this, EventArgs.Empty);

            _dragStopped     = new SmartEvent(this, this.RealHandle, "slider,drag,stop");
            _dragStopped.On += (s, e) => DragStopped?.Invoke(this, EventArgs.Empty);
        }
 protected virtual void OnDelayedValueChanged(object sender, RoutedPropertyChangedEventArgs <double> e)
 {
     DelayedValueChanged?.Invoke(sender, e);
 }