Haptisches Feedback hinzufügen #216

Merged
flixcoo merged 14 commits from feature/215-haptisches-feedback-hinzufügen into development 2026-05-14 13:09:01 +00:00
2 changed files with 6 additions and 3 deletions
Showing only changes of commit cadb5793e7 - Show all commits

View File

@@ -70,11 +70,14 @@ class _MainMenuButtonState extends State<MainMenuButton>
const Duration(milliseconds: 400),
() async {
_isLongPressing = true;
await HapticFeedback.vibrate();
widget.onLongPressed?.call();
await HapticFeedback.heavyImpact();
_repeatTimer = Timer.periodic(
const Duration(milliseconds: 250),
(_) => widget.onLongPressed?.call(),
(_) async {
widget.onLongPressed?.call();
await HapticFeedback.heavyImpact();
},
);
},
);

View File

@@ -61,7 +61,7 @@ class GameTile extends StatelessWidget {
}
},
onLongPress: () async {
await HapticFeedback.vibrate();
await HapticFeedback.heavyImpact();
if (onLongPress != null) {
onLongPress!.call();
}