Welcome to the Flutter feedback portal. We’re happy you’re here! If you have feedback on how to improve the Flutter, we’d love to hear it!

  • Check out the features or bugs others have reported and vote on your favorites. Feedback will be prioritized based on popularity.
  • If you have feedback that’s not listed yet, submit your own.

Thanks for joining our community and helping improve Syncfusion products!

1
Vote

class CustomSelectionManager extends RowSelectionManager {
  @override
  void handleKeyEvent(RawKeyEvent keyEvent) {
    if (keyEvent.logicalKey == LogicalKeyboardKey.enter) {
      //apply your logic
      return;
    }

    super.handleKeyEvent(keyEvent);
  }
}

It is showing two errors in the code:

1 - 'CustomSelectionManager.handleKeyEvent' ('void Function(RawKeyEvent)') isn't a valid override of 'RowSelectionManager.handleKeyEvent' ('Future Function(KeyEvent)').dartinvalid_override


2 - Undefined name 'LogicalKeyboardKey'.


Flutter 3.19.1 • channel stable • https://github.com/flutter/flutter.git

Framework • revision abb292a07e (13 days ago) • 2024-02-20 14:35:05 -0800

Engine • revision 04817c99c9

Tools • Dart 3.3.0 • DevTools 2.31.1