Пример #1
0
        private static void OnVisibleWidthPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
        {
            TextTickerControl control = d as TextTickerControl;

            if (control != null)
            {
                control.SetDimensions();
            }
        }
Пример #2
0
        private static void OnStartDelayInMillisecondsPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
        {
            TextTickerControl control = d as TextTickerControl;

            if (control != null && (int)e.NewValue < TextTickerControl.UpdateTextTimerDelayInMilliseconds)
            {
                control.StartDelayInMilliseconds = TextTickerControl.UpdateTextTimerDelayInMilliseconds;
            }
        }
Пример #3
0
        private static void OnTextPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
        {
            TextTickerControl control = d as TextTickerControl;

            if (control != null && control.tickerTextBlock != null)
            {
                control.tickerTextBlock.Text        = (string)e.NewValue;
                control.trimmedTickerTextBlock.Text = (string)e.NewValue;
                control.Reset();
            }
        }