mirror of
https://github.com/subsurface/subsurface.git
synced 2024-12-11 19:41:30 +00:00
mobile/UI: move dive delete to context menu
Having this as the right action button (same one used for 'cancel' in the edit screen) made it too likely to inadvertantly delete a dive. And outside of testing, wanting to delete a dive really shouldn't be all that common an operation. So remove the function from the action button and place it into the context menu instead, right next to the undo action so the user also is aware that there is an undo option. Suggested-by: Peter Zaal <peter.zaal@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
1913e97bf2
commit
0a632e12d2
1 changed files with 2 additions and 2 deletions
|
@ -115,7 +115,7 @@ Kirigami.Page {
|
||||||
enabled: manager.redoText !== ""
|
enabled: manager.redoText !== ""
|
||||||
onTriggered: manager.redo()
|
onTriggered: manager.redo()
|
||||||
}
|
}
|
||||||
property variant contextactions: [ removeDiveFromTripAction, addDiveToTripAboveAction, addDiveToTripBelowAction, undoAction, redoAction ]
|
property variant contextactions: [ removeDiveFromTripAction, addDiveToTripAboveAction, addDiveToTripBelowAction, deleteAction, undoAction, redoAction ]
|
||||||
|
|
||||||
states: [
|
states: [
|
||||||
State {
|
State {
|
||||||
|
@ -123,7 +123,7 @@ Kirigami.Page {
|
||||||
PropertyChanges {
|
PropertyChanges {
|
||||||
target: diveDetailsPage;
|
target: diveDetailsPage;
|
||||||
actions {
|
actions {
|
||||||
right: deleteAction
|
right: null
|
||||||
left: currentItem ? (currentItem.modelData && currentItem.modelData.gps !== "" ? mapAction : null) : null
|
left: currentItem ? (currentItem.modelData && currentItem.modelData.gps !== "" ? mapAction : null) : null
|
||||||
}
|
}
|
||||||
contextualActions: contextactions
|
contextualActions: contextactions
|
||||||
|
|
Loading…
Reference in a new issue