Xamarin.Forms icon indicating copy to clipboard operation
Xamarin.Forms copied to clipboard

[Bug] Physical keyboard new line symbol is ignored

Open valentasm1 opened this issue 3 years ago • 0 comments

Description

Using barcode reader which acts as Physical keyboard and returns barcode as char. When it finished reading barcode it sends new line char "\n". After 5.0.0.2478 (including) version it never returns "\n" symbol. We are reading symbols in OnKeyDown in MainActivity. It didnt focused any entry, so it doesnt looks like some issue with entry

Steps to Reproduce

  1. Create fresh xamarin application
  2. Update to 5.0.0.2515 version
  3. Read keys with public override bool OnKeyDown(Keycode keyCode, KeyEvent? e) in MainActivity android
  4. Enter new line character

Expected Behavior

New line char should be invoked in OnKeyDown

Actual Behavior

New line char should be invoked in OnKeyDown

Basic Information

  • Version with issue:
  • Last known good version:
  • Platform Target Frameworks:
    • iOS:
    • Android:
    • UWP:
  • Android Support Library / AndroidX Version:
  • NuGet Packages:
  • Affected Devices:

Environment

Visual studio Version 17.3.1 Android Physical device Xamarin version 5.0.0.2515 Barcode reader as HID, but any keybourd would work too

Workaround

Stay with 5.0.0.2401 version

valentasm1 avatar Aug 24 '22 11:08 valentasm1