]> git.r.bdr.sh - rbdr/map/blobdiff - Map/Views/ContentView.swift
Make delete a context action
[rbdr/map] / Map / Views / ContentView.swift
index cf1f145ab46c3d840d94fcfd65750269f8c71244..f439026249988f669b78b118f7d9b4116db2ed10 100644 (file)
@@ -37,6 +37,11 @@ struct ContentView: View {
                 .foregroundColor(Color.black)
                 .cornerRadius(2.0)
             }.padding(.leading, 8.0)
+          }.contextMenu {
+            Button(action: { store.send(.deleteMap(map: map))}) {
+              Image(systemName: "trash")
+              Text("Delete")
+            }
           }
         }
         .onDelete(perform: deleteMaps)
@@ -51,6 +56,7 @@ struct ContentView: View {
             }
           }
         }
+        DefaultMapView()
     }
   }