Changed `MenuItem`'s `string InputGestureText` property to `KeyGesture InputGesture` and gave it a value converter in the default template, because the string representation of a key gesture depends on platform, and putting platform-specific behavior into `ToString` isn't a good idea.
To do this we needed to change the `KeyGesture.ToString()` method to produce input gesture text suitable for menus. Also demonstrated in `MainWindow` how to produce different gestures/headers depending on platform.
Added a new `IsEnabledCore` property to `InputElement` which is overridden in `Button` and `MenuItem` to override the `IsEffectivelyEnabled` state with the enabled state of the command.
Also add data validation of the `Command` property to `MenuItem` to make it behave the same as `Button` when `Command` is bound to a non-existent property.
Fixes#2501
When a captured control is removed from the visual tree, clear the mouse capture.
Note that our capture logic needs to be improved - it shouldn't be possible to capture a non-visible or non-enabled control. This doesn't address that but it does fix the crash in #1203.
Fixes#1203
Previously this project was spewing loads of
```
Severity Code Description Project File Line Suppression State
Warning CS1701 Assuming assembly reference 'System.Runtime, Version=4.0.20.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' used by 'Avalonia.Controls' matches identity 'System.Runtime, Version=4.1.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' of 'System.Runtime', you may need to supply runtime policy Avalonia.Input.UnitTests(net461) D:\projects\Avalonia\tests\Avalonia.Input.UnitTests\CSC 1 Active`
```
Warnings. Not sure why this was, but updating the `csproj` to be in the same format as the other unit tests stops these warnings and reduces the warnings for a solution build from 5755(!) to 238.