コード例 #1
0
        private static void OnCurrentFirstChanged(DependencyObject sender, DependencyPropertyChangedEventArgs e)
        {
            ComplexProgressBar myControl = sender as ComplexProgressBar;

            // Gestion des synchonisations des colonnes
            //double width = (double)sender;

            //e.Property = (double)e.NewValue + 5;
            //myControl.imgCurrent.Source = ((ImageInfoClass)e.NewValue).Image;

            myControl.ProgressBarForeground.Width = (myControl.ActualWidth - 2) * myControl.CurrentFirst / myControl.Maximum;
            // myControl.ProgressBarForeground2.Width = (myControl.ActualWidth - 2) * myControl. / myControl.Maximum;
        }
コード例 #2
0
        private static void OnCurrentSecondChanged(DependencyObject sender, DependencyPropertyChangedEventArgs e)
        {
            ComplexProgressBar myControl = sender as ComplexProgressBar;

            myControl.ProgressBarForeground2.Width = (myControl.ActualWidth - 2) * myControl.CurrentSecond / myControl.Maximum;
        }