Fix can not show saving dialog anymore when click on back system button
This commit is contained in:
@@ -1923,6 +1923,7 @@ class ComposerController extends BaseController with DragDropFileMixin {
|
||||
alignCenter: true,
|
||||
outsideDismissible: false,
|
||||
autoPerformPopBack: false,
|
||||
usePopScope: true,
|
||||
onConfirmAction: () => _handleSaveMessageToDraft(context),
|
||||
onCancelAction: () {
|
||||
_closeComposerButtonState = ButtonState.enabled;
|
||||
@@ -1933,6 +1934,14 @@ class ComposerController extends BaseController with DragDropFileMixin {
|
||||
popBack();
|
||||
_autoFocusFieldWhenLauncher();
|
||||
},
|
||||
onPopInvoked: (didPop) {
|
||||
log('ComposerController::_showConfirmDialogSaveMessage: didPop = $didPop');
|
||||
if (!didPop) {
|
||||
_closeComposerButtonState = ButtonState.enabled;
|
||||
popBack();
|
||||
_autoFocusFieldWhenLauncher();
|
||||
}
|
||||
},
|
||||
marginIcon: EdgeInsets.zero,
|
||||
icon: SvgPicture.asset(
|
||||
imagePaths.icQuotasWarning,
|
||||
|
||||
Reference in New Issue
Block a user