Skip to content

Commit a256596

Browse files
committed
Mute warnings in sample app
1 parent ad238e3 commit a256596

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

Samples/UnitConverter.Wpf/UnitConverter.Wpf/DelegateCommand.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,9 @@ public void Execute(object parameter)
2626
_commandDelegate.Invoke();
2727
}
2828

29+
// Is never used
30+
#pragma warning disable CS0067
2931
public event EventHandler CanExecuteChanged;
32+
#pragma warning restore CS0067
3033
}
31-
}
34+
}

Samples/UnitConverter.Wpf/UnitConverter.Wpf/MainWindowDesignVM.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
using System.Collections.ObjectModel;
33
using System.ComponentModel;
44
using System.Linq;
5+
using System.Runtime.CompilerServices;
56
using System.Windows.Input;
67

78
namespace UnitsNet.Samples.UnitConverter.Wpf
@@ -21,6 +22,7 @@ public MainWindowDesignVm()
2122
SelectedToUnit = Units[2];
2223
}
2324

25+
2426
public ReadOnlyObservableCollection<QuantityType> Quantities { get; }
2527
public ReadOnlyObservableCollection<UnitListItem> Units { get; }
2628
public QuantityType SelectedQuantity { get; set; }
@@ -34,7 +36,10 @@ public MainWindowDesignVm()
3436

3537
public ICommand SwapCommand { get; } = new RoutedCommand();
3638

39+
// Is never used
40+
#pragma warning disable CS0067
3741
public event PropertyChangedEventHandler PropertyChanged;
42+
#pragma warning restore CS0067
3843

3944
private static ReadOnlyObservableCollection<T> ToReadOnly<T>(IEnumerable<T> items)
4045
{

0 commit comments

Comments
 (0)