jsakamoto / Toolbelt.Blazor.HotKeys2

This is a class library that provides configuration-centric keyboard shortcuts for your Blazor apps.
https://jsakamoto.github.io/Toolbelt.Blazor.HotKeys2/
Mozilla Public License 2.0
87 stars 6 forks source link

The hotkey registered by `Code.ShiftRight` doesn't work #2

Closed jsakamoto closed 1 year ago

jsakamoto commented 1 year ago

The code below using the Code class never increments the count even when a user presses the Right Shift key.

  protected override void OnInitialized()
  {
      this.HotKeysContext = this.HotKeys.CreateContext()
          .Add(Code.ShiftRight, this.IncrementCount);
  }

P.S. The code below using the Key class works fine.

.Add(Key.Shift, this.IncrementCount);