Listen to key press outside of flutter (desktop) app

Issue

I have managed to print the key the user presses when the user is using the app. But How to print the key (listen to key press) in flutter desktop when the user is not using the app or in background?

Solution

Flutter doesn’t provide APIs for intercepting key events at the OS level. You would need to write native code for each platform you want to run on to do that, and use platform channels to communicate the information to your Dart code.

Answered By – smorgan

Answer Checked By – Cary Denson (FlutterFixes Admin)

Leave a Reply

Your email address will not be published. Required fields are marked *