Browse Source

Fix unit tests. Remove default ctor.

pull/2990/head
Dariusz Komosiński 7 years ago
parent
commit
d409090b90
  1. 4
      src/Avalonia.Input/KeyGesture.cs
  2. 4
      tests/Avalonia.Controls.UnitTests/Utils/HotKeyManagerTests.cs

4
src/Avalonia.Input/KeyGesture.cs

@ -17,10 +17,6 @@ namespace Avalonia.Input
{ "+", Key.OemPlus }, { "-", Key.OemMinus }, { ".", Key.OemPeriod }
};
public KeyGesture()
{
}
[Obsolete("Use constructor taking KeyModifiers")]
public KeyGesture(Key key, InputModifiers modifiers)
{

4
tests/Avalonia.Controls.UnitTests/Utils/HotKeyManagerTests.cs

@ -24,8 +24,8 @@ namespace Avalonia.Controls.UnitTests.Utils
.Bind<IWindowingPlatform>().ToConstant(new WindowingPlatformMock())
.Bind<IStyler>().ToConstant(styler.Object);
var gesture1 = new KeyGesture {Key = Key.A, Modifiers = InputModifiers.Control};
var gesture2 = new KeyGesture {Key = Key.B, Modifiers = InputModifiers.Control};
var gesture1 = new KeyGesture(Key.A, InputModifiers.Control);
var gesture2 = new KeyGesture(Key.B, InputModifiers.Control);
var tl = new Window();
var button = new Button();

Loading…
Cancel
Save