Skip to content

Commit

Permalink
Merge pull request #3549 from MerginMaps/display-unsaved-change-dialog
Browse files Browse the repository at this point in the history
Fix : Unsaved changes dialog not displayed when using back button
  • Loading branch information
tomasMizera authored Jul 29, 2024
2 parents a61364b + 052b5b6 commit efb0012
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion app/qml/form/MMFormPage.qml
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,15 @@ Page {

header: MMComponents.MMPageHeader {

onBackClicked: root.rollbackAndClose()
onBackClicked: {
if ( root.controller.hasAnyChanges ) {
saveChangesDialog.open()
}
else {
root.rollbackAndClose()
}
}


title: {
if ( root.state === "add" ) return qsTr( "New feature" )
Expand Down

1 comment on commit efb0012

@inputapp-bot
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

iOS - version 24.7.644911 just submitted!

Please sign in to comment.