mirror of
https://github.com/krille-chan/fluffychat
synced 2024-09-10 08:25:12 +00:00
chore: Follow up select messages
This commit is contained in:
parent
84fd65f55e
commit
a6618c1817
2 changed files with 12 additions and 3 deletions
|
@ -3,6 +3,7 @@ import 'package:flutter/material.dart';
|
|||
import 'package:flutter_gen/gen_l10n/l10n.dart';
|
||||
import 'package:matrix/matrix.dart';
|
||||
import 'package:swipe_to_action/swipe_to_action.dart';
|
||||
import 'package:vibration/vibration.dart';
|
||||
|
||||
import 'package:fluffychat/config/themes.dart';
|
||||
import 'package:fluffychat/utils/date_time_extension.dart';
|
||||
|
@ -209,8 +210,16 @@ class Message extends StatelessWidget {
|
|||
alignment: alignment,
|
||||
padding: const EdgeInsets.only(left: 8),
|
||||
child: GestureDetector(
|
||||
onLongPress:
|
||||
longPressSelect ? null : () => onSelect(event),
|
||||
onLongPress: longPressSelect
|
||||
? null
|
||||
: () {
|
||||
onSelect(event);
|
||||
Vibration.hasVibrator().then((has) {
|
||||
if (has == true) {
|
||||
Vibration.vibrate(duration: 50);
|
||||
}
|
||||
});
|
||||
},
|
||||
child: AnimatedOpacity(
|
||||
opacity: animateIn
|
||||
? 0
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
import 'dart:io';
|
||||
|
||||
import 'package:desktop_notifications/desktop_notifications.dart';
|
||||
import 'package:flutter/foundation.dart';
|
||||
|
||||
import 'package:desktop_notifications/desktop_notifications.dart';
|
||||
import 'package:flutter_gen/gen_l10n/l10n.dart';
|
||||
import 'package:flutter_local_notifications/flutter_local_notifications.dart';
|
||||
import 'package:hive_flutter/hive_flutter.dart';
|
||||
|
|
Loading…
Reference in a new issue