Skip to content

Commit 332e2af

Browse files
TF-3511 Fix Android email view system back action (#3546)
1 parent ae0c847 commit 332e2af

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

lib/features/email/presentation/widgets/email_view_app_bar_widget.dart

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ class EmailViewAppBarWidget extends StatelessWidget {
4242

4343
@override
4444
Widget build(BuildContext context) {
45-
return LayoutBuilder(builder: (context, constraints) {
45+
final child = LayoutBuilder(builder: (context, constraints) {
4646
return Container(
4747
height: PlatformInfo.isIOS
4848
? EmailViewAppBarWidgetStyles.heightIOS(context, _responsiveUtils)
@@ -150,6 +150,15 @@ class EmailViewAppBarWidget extends StatelessWidget {
150150
])
151151
);
152152
});
153+
154+
return PopScope(
155+
canPop: false,
156+
onPopInvokedWithResult: (_, __) {
157+
onBackAction();
158+
return;
159+
},
160+
child: child,
161+
);
153162
}
154163

155164
bool _supportDisplayMailboxNameTitle(BuildContext context) {

0 commit comments

Comments
 (0)