Skip to content

Commit e26438c

Browse files
Provide context menu on pin tabs (Red Window)
1 parent 6c1e58f commit e26438c

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

MCMaps/Red Window/Views/RedWindowContentView.swift

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,16 @@ struct RedWindowContentView: View {
124124
}
125125
.customizationID("app.tab.library.\(mapPin.content.name.snakeCase)")
126126
.customizationBehavior(.automatic, for: .automatic)
127+
.contextMenu {
128+
Button("Go Here", systemImage: "location") {
129+
redWindowEnvironment.mapCenterCoordinate = mapPin.content.position
130+
}
131+
}
132+
.swipeActions {
133+
Button("Go Here", systemImage: "location") {
134+
redWindowEnvironment.mapCenterCoordinate = mapPin.content.position
135+
}
136+
}
127137
}
128138
}
129139
.hidden(horizontalSizeClass == .compact)

0 commit comments

Comments
 (0)