WIP
This commit is contained in:
parent
3ed50939d0
commit
262b8dd63b
|
@ -291,14 +291,15 @@ class PreferencesPageModel with ChangeNotifier {
|
||||||
ScaffoldMessenger.of(context).showSnackBar(
|
ScaffoldMessenger.of(context).showSnackBar(
|
||||||
SnackBar(
|
SnackBar(
|
||||||
content: Text(
|
content: Text(
|
||||||
FFLocalizations.of(context).getVariableText(
|
FFLocalizations.of(context).getVariableText(
|
||||||
enText: 'Device unlinked successfully',
|
enText: 'Device unlinked successfully',
|
||||||
ptText:
|
ptText:
|
||||||
'Dispositivo desvinculado com sucesso',
|
'Dispositivo desvinculado com sucesso',
|
||||||
),
|
),
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
color:
|
color: FlutterFlowTheme.of(context).info,
|
||||||
FlutterFlowTheme.of(context).info)),
|
),
|
||||||
|
),
|
||||||
backgroundColor:
|
backgroundColor:
|
||||||
FlutterFlowTheme.of(context).success,
|
FlutterFlowTheme.of(context).success,
|
||||||
duration: const Duration(seconds: 3),
|
duration: const Duration(seconds: 3),
|
||||||
|
@ -308,20 +309,41 @@ class PreferencesPageModel with ChangeNotifier {
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
})
|
}).catchError((err, stack) {
|
||||||
// ignore: body_might_complete_normally_catch_error
|
|
||||||
.catchError((err, stack) {
|
|
||||||
log(err.toString());
|
log(err.toString());
|
||||||
ScaffoldMessenger.of(context).showSnackBar(
|
ScaffoldMessenger.of(context).showSnackBar(
|
||||||
SnackBar(
|
SnackBar(
|
||||||
content: Text(
|
content: Text(
|
||||||
FFLocalizations.of(context).getVariableText(
|
FFLocalizations.of(context).getVariableText(
|
||||||
enText: 'Error unlinking device',
|
enText: 'Error unlinking device',
|
||||||
ptText: 'Erro ao desvincular dispositivo',
|
ptText: 'Erro ao desvincular dispositivo',
|
||||||
),
|
),
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
color:
|
color: FlutterFlowTheme.of(context).info,
|
||||||
FlutterFlowTheme.of(context).info)),
|
),
|
||||||
|
),
|
||||||
|
backgroundColor:
|
||||||
|
FlutterFlowTheme.of(context).error,
|
||||||
|
duration: const Duration(seconds: 3),
|
||||||
|
behavior: SnackBarBehavior.floating,
|
||||||
|
shape: RoundedRectangleBorder(
|
||||||
|
borderRadius: BorderRadius.circular(30),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}).catchError((err, stack) {
|
||||||
|
log(err.toString());
|
||||||
|
ScaffoldMessenger.of(context).showSnackBar(
|
||||||
|
SnackBar(
|
||||||
|
content: Text(
|
||||||
|
FFLocalizations.of(context).getVariableText(
|
||||||
|
enText: 'Error unlinking device',
|
||||||
|
ptText: 'Erro ao desvincular dispositivo',
|
||||||
|
),
|
||||||
|
style: TextStyle(
|
||||||
|
color: FlutterFlowTheme.of(context).info,
|
||||||
|
),
|
||||||
|
),
|
||||||
backgroundColor:
|
backgroundColor:
|
||||||
FlutterFlowTheme.of(context).error,
|
FlutterFlowTheme.of(context).error,
|
||||||
duration: const Duration(seconds: 3),
|
duration: const Duration(seconds: 3),
|
||||||
|
|
Loading…
Reference in New Issue