Version 0.10.0
This commit is contained in:
parent
d6e1594a6f
commit
67eedc4a77
16 changed files with 313 additions and 126 deletions
|
|
@ -5,7 +5,6 @@ import 'package:fluffychat/i18n/i18n.dart';
|
|||
import 'package:fluffychat/utils/app_route.dart';
|
||||
import 'package:fluffychat/views/chat_encryption_settings.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:toast/toast.dart';
|
||||
|
||||
import 'dialogs/simple_dialogs.dart';
|
||||
import 'matrix.dart';
|
||||
|
|
@ -22,8 +21,11 @@ class _EncryptionButtonState extends State<EncryptionButton> {
|
|||
|
||||
void _enableEncryptionAction() async {
|
||||
if (widget.room.encrypted) {
|
||||
Toast.show(I18n.of(context).warningEncryptionInBeta, context,
|
||||
duration: 5);
|
||||
Scaffold.of(context).showSnackBar(
|
||||
SnackBar(
|
||||
content: Text(I18n.of(context).warningEncryptionInBeta),
|
||||
),
|
||||
);
|
||||
await Navigator.of(context).push(
|
||||
AppRoute.defaultRoute(
|
||||
context,
|
||||
|
|
@ -33,7 +35,13 @@ class _EncryptionButtonState extends State<EncryptionButton> {
|
|||
return;
|
||||
}
|
||||
if (!widget.room.client.encryptionEnabled) {
|
||||
Toast.show(I18n.of(context).needPantalaimonWarning, context, duration: 8);
|
||||
Scaffold.of(context).showSnackBar(
|
||||
SnackBar(
|
||||
content: Text(
|
||||
I18n.of(context).needPantalaimonWarning,
|
||||
),
|
||||
),
|
||||
);
|
||||
return;
|
||||
}
|
||||
if (await SimpleDialogs(context).askConfirmation(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue