Open nashihu opened 3 months ago
for me it works using syncfusion_flutter_datepicker: "24.2.6"
i suggest to add sdk constraint in pubspec if it's related to flutter sdk requirement
Hi @nashihu ,
We have migrated our source which is compatible with Flutter SDK 3.19.0, in Flutter SDK version 3.19.0 they have done breaking changes in the RawKeyEvent and replaced it with HardWareKeyBoard. So, we kindly request you to upgrade the Flutter SDK version to 3.19.0 or else use the packages syncfusion_flutter_datepicker version below 24.2.7. We have also shared the breaking changes documentation below for your reference.
We hope it will help you to resolve the issue, if you have any further queries please get back to us. We are always happy to assist you.
Flutter 3.19.0 breaking change, https://docs.flutter.dev/release/breaking-changes/key-event-migration#migrating-iskeypressed-and-related-functions
Regards, Yuvaraj.
Hi @nashihu ,
We have migrated our source which is compatible with Flutter SDK 3.19.0, in Flutter SDK version 3.19.0 they have done breaking changes in the RawKeyEvent and replaced it with HardWareKeyBoard. So, we kindly request you to upgrade the Flutter SDK version to 3.19.0 or else use the packages syncfusion_flutter_datepicker version below 24.2.7. We have also shared the breaking changes documentation below for your reference.
We hope it will help you to resolve the issue, if you have any further queries please get back to us. We are always happy to assist you.
Flutter 3.19.0 breaking change, https://docs.flutter.dev/release/breaking-changes/key-event-migration#migrating-iskeypressed-and-related-functions
Regards, Yuvaraj.
hi ,
i have an issue similar to this My error: Error: The getter 'isControlPressed' isn't defined for the class 'HardwareKeyboard'.
Code:
@override
Widget build(BuildContext context) {
final callsProvider = Provider.of
)
],
),
);
}
}
class CallsDataTableSource extends DataGridSource {
final List
CallsDataTableSource(this.calls);
@override DataRow? getRow(int index) { if (index >= calls.length) { return null; } final call = calls[index]; return DataRow(cells: [ DataCell(Text("${index +1}",style: MyTextStyle.blackText15)), // Replace field1, field2, etc. with actual fields from Call DataCell(Text(call.userId!.firstName.toString(),style: MyTextStyle.blackText15,)), // Replace field1, field2, etc. with actual fields from Call DataCell(Text(call.leadId!.name.toString(),style: MyTextStyle.blackText15)), DataCell(Text(call.callNotes.toString(),style: MyTextStyle.blackText15)), DataCell(Text(call.timestamp.toString(),style: MyTextStyle.blackText15)), DataCell(Text(call.startAt.toString(),style: MyTextStyle.blackText15)), // Add more DataCells as needed for each field in Call ]); }
@override bool get isRowCountApproximate => true;
@override int get rowCount => calls.length;
@override int get selectedRowCount => 0;
@override DataGridRowAdapter? buildRow(DataGridRow row) { // TODO: implement buildRow throw UnimplementedError(); } }
but the below code works fine :
class _MyDataGridState extends State
@override
Widget build(BuildContext context) {
return SfDataGrid(
frozenColumnsCount: 2,
source: _MyDataSource(),
columns:
class _MyDataSource extends DataGridSource {
@override
List
@override
DataGridRowAdapter buildRow(DataGridRow row) {
return DataGridRowAdapter(
cells: row.getCells().map
Hi @nashihu,
We have updated our package from version 24.2.7 to be compatible with Flutter SDK v3.19.0. In Flutter SDK v3.19.0 they have done breaking changes in the RawKeyEvent and replaced it with HardWareKeyBoard. So, we kindly request you to upgrade the Flutter SDK version to 3.19.0. We have also shared the breaking changes documentation below for your reference.
Flutter 3.19.0 breaking change, https://docs.flutter.dev/release/breaking-changes/key-event-migration#migrating-iskeypressed-and-related-functions
Also, we would like to share our package compatibility with respect to the Flutter SDK below.
UG: https://help.syncfusion.com/flutter/system-requirements#sdk-version-compatibility
We hope it will help you to resolve the issue. If you are still facing issue, we recommend that you check by clearing the cache using the below mentioned methods:
Regards, Lokesh P.
Hello, I'm using Flutter 3.16.9
I added
syncfusion_flutter_datepicker: ^24.2.9
to pubspec.I'm not using any code from syncfusion yet, but after adding to pubspec, i got this error
log
../../../../.pub-cache/hosted/pub.dev/syncfusion_flutter_datepicker-24.2.9/lib/src/date_picker/date_picker.dart:10064:35: Error: The getter 'isAltPressed' isn't defined for the class 'HardwareKeyboard'. 'HardwareKeyboard' is from 'package:flutter/src/services/hardware_keyboard.dart' ('../../../../flutter/packages/flutter/lib/src/services/hardware_keyboard.dart'). Try correcting the name to the name of an existing getter, or defining a getter or field named 'isAltPressed'. if (HardwareKeyboard.instance.isAltPressed) { ^^^^^^^^^^^^ ../../../../.pub-cache/hosted/pub.dev/syncfusion_flutter_datepicker-24.2.9/lib/src/date_picker/date_picker.dart:10108:35: Error: The getter 'isShiftPressed' isn't defined for the class 'HardwareKeyboard'. 'HardwareKeyboard' is from 'package:flutter/src/services/hardware_keyboard.dart' ('../../../../flutter/packages/flutter/lib/src/services/hardware_keyboard.dart'). Try correcting the name to the name of an existing getter, or defining a getter or field named 'isShiftPressed'. HardwareKeyboard.instance.isShiftPressed) { ^^^^^^^^^^^^^^ ../../../../.pub-cache/hosted/pub.dev/syncfusion_flutter_datepicker-24.2.9/lib/src/date_picker/date_picker.dart:10131:35: Error: The getter 'isShiftPressed' isn't defined for the class 'HardwareKeyboard'. 'HardwareKeyboard' is from 'package:flutter/src/services/hardware_keyboard.dart' ('../../../../flutter/packages/flutter/lib/src/services/hardware_keyboard.dart'). Try correcting the name to the name of an existing getter, or defining a getter or field named 'isShiftPressed'. HardwareKeyboard.instance.isShiftPressed) { ^^^^^^^^^^^^^^ ../../../../.pub-cache/hosted/pub.dev/syncfusion_flutter_datepicker-24.2.9/lib/src/date_picker/date_picker.dart:10320:35: Error: The getter 'isShiftPressed' isn't defined for the class 'HardwareKeyboard'. 'HardwareKeyboard' is from 'package:flutter/src/services/hardware_keyboard.dart' ('../../../../flutter/packages/flutter/lib/src/services/hardware_keyboard.dart'). Try correcting the name to the name of an existing getter, or defining a getter or field named 'isShiftPressed'. if (HardwareKeyboard.instance.isShiftPressed && ^^^^^^^^^^^^^^ ../../../../.pub-cache/hosted/pub.dev/syncfusion_flutter_datepicker-24.2.9/lib/src/date_picker/date_picker.dart:10335:35: Error: The getter 'isControlPressed' isn't defined for the class 'HardwareKeyboard'. 'HardwareKeyboard' is from 'package:flutter/src/services/hardware_keyboard.dart' ('../../../../flutter/packages/flutter/lib/src/services/hardware_keyboard.dart'). Try correcting the name to the name of an existing getter, or defining a getter or field named 'isControlPressed'. if (HardwareKeyboard.instance.isControlPressed) { ^^^^^^^^^^^^^^^^ ../../../../.pub-cache/hosted/pub.dev/syncfusion_flutter_datepicker-24.2.9/lib/src/date_picker/date_picker.dart:10563:35: Error: The getter 'isShiftPressed' isn't defined for the class 'HardwareKeyboard'. 'HardwareKeyboard' is from 'package:flutter/src/services/hardware_keyboard.dart' ('../../../../flutter/packages/flutter/lib/src/services/hardware_keyboard.dart'). Try correcting the name to the name of an existing getter, or defining a getter or field named 'isShiftPressed'. if (HardwareKeyboard.instance.isShiftPressed && ^^^^^^^^^^^^^^ ../../../../.pub-cache/hosted/pub.dev/syncfusion_flutter_datepicker-24.2.9/lib/src/date_picker/date_picker.dart:10586:42: Error: The getter 'isShiftPressed' isn't defined for the class 'HardwareKeyboard'. 'HardwareKeyboard' is from 'package:flutter/src/services/hardware_keyboard.dart' ('../../../../flutter/packages/flutter/lib/src/services/hardware_keyboard.dart'). Try correcting the name to the name of an existing getter, or defining a getter or field named 'isShiftPressed'. } else if (HardwareKeyboard.instance.isShiftPressed && ^^^^^^^^^^^^^^ ../../../../.pub-cache/hosted/pub.dev/syncfusion_flutter_datepicker-24.2.9/lib/src/date_picker/date_picker.dart:10609:42: Error: The getter 'isShiftPressed' isn't defined for the class 'HardwareKeyboard'. 'HardwareKeyboard' is from 'package:flutter/src/services/hardware_keyboard.dart' ('../../../../flutter/packages/flutter/lib/src/services/hardware_keyboard.dart'). Try correcting the name to the name of an existing getter, or defining a getter or field named 'isShiftPressed'. } else if (HardwareKeyboard.instance.isShiftPressed && ^^^^^^^^^^^^^^ ../../../../.pub-cache/hosted/pub.dev/syncfusion_flutter_datepicker-24.2.9/lib/src/date_picker/date_picker.dart:10632:42: Error: The getter 'isShiftPressed' isn't defined for the class 'HardwareKeyboard'. 'HardwareKeyboard' is from 'package:flutter/src/services/hardware_keyboard.dart' ('../../../../flutter/packages/flutter/lib/src/services/hardware_keyboard.dart'). Try correcting the name to the name of an existing getter, or defining a getter or field named 'isShiftPressed'. } else if (HardwareKeyboard.instance.isShiftPressed &&