private static void BtnIsBlacklistedPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { ConversionResultsBtn cBtn = (ConversionResultsBtn)d; bool val = (bool)e.NewValue; if (val == true) { cBtn.conversionResultContainerGrid.Opacity = 0.5; } else { cBtn.conversionResultContainerGrid.Opacity = 1.0; } cBtn.NotifyPropertyChanged("BtnIsBlacklisted"); cBtn.NotifyPropertyChanged("BtnVisibility"); }
private static void BtnShowBlacklistedPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { ConversionResultsBtn cBtn = (ConversionResultsBtn)d; bool val = (bool)e.NewValue; if (val) { cBtn.notBlacklistedCheckBox.Visibility = Visibility.Visible; } else { cBtn.notBlacklistedCheckBox.Visibility = Visibility.Collapsed; } cBtn.NotifyPropertyChanged("BtnVisibility"); }