Skip to content

Commit 86e79ed

Browse files
committed
Removed BingMaps support
1 parent 723635f commit 86e79ed

File tree

5 files changed

+5
-79
lines changed

5 files changed

+5
-79
lines changed

GoInfoGame/GoInfoGame.xcodeproj/project.pbxproj

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,6 @@
171171
FA18CAEB2CD0F718008247F2 /* CameraView.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA18CAEA2CD0F718008247F2 /* CameraView.swift */; };
172172
FA1992ED2BB1A78C003B4719 /* KeychainManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA1992EC2BB1A78C003B4719 /* KeychainManager.swift */; };
173173
FA50718C2D54E08800CE9798 /* AddFeatureView.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA50718B2D54E08800CE9798 /* AddFeatureView.swift */; };
174-
FA50718E2D54E1D200CE9798 /* BingTileOverlay.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA50718D2D54E1D200CE9798 /* BingTileOverlay.swift */; };
175174
FA5071902D5B31CC00CE9798 /* CreateNoteView.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA50718F2D5B31CC00CE9798 /* CreateNoteView.swift */; };
176175
FA5071962D6DD31A00CE9798 /* LongElementQuest.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA5071952D6DD31A00CE9798 /* LongElementQuest.swift */; };
177176
FA5071982D71F1B000CE9798 /* SyncLogger.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA5071972D71F1B000CE9798 /* SyncLogger.swift */; };
@@ -512,7 +511,6 @@
512511
FA18CAEA2CD0F718008247F2 /* CameraView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CameraView.swift; sourceTree = "<group>"; };
513512
FA1992EC2BB1A78C003B4719 /* KeychainManager.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = KeychainManager.swift; sourceTree = "<group>"; };
514513
FA50718B2D54E08800CE9798 /* AddFeatureView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AddFeatureView.swift; sourceTree = "<group>"; };
515-
FA50718D2D54E1D200CE9798 /* BingTileOverlay.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BingTileOverlay.swift; sourceTree = "<group>"; };
516514
FA50718F2D5B31CC00CE9798 /* CreateNoteView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CreateNoteView.swift; sourceTree = "<group>"; };
517515
FA5071952D6DD31A00CE9798 /* LongElementQuest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LongElementQuest.swift; sourceTree = "<group>"; };
518516
FA5071972D71F1B000CE9798 /* SyncLogger.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SyncLogger.swift; sourceTree = "<group>"; };
@@ -829,7 +827,6 @@
829827
C71EB5AF2E2100B80009E610 /* MapRepository.swift */,
830828
C71EB5AB2E2100510009E610 /* Satellite Server */,
831829
971575182B5FFE910044797C /* LocationManagerCoordinator.swift */,
832-
FA50718D2D54E1D200CE9798 /* BingTileOverlay.swift */,
833830
971575162B5FFD6F0044797C /* MapView.swift */,
834831
970D5BD22B67638400C20BE7 /* MapViewModel.swift */,
835832
A495DF2C2B6A190400478E44 /* CustomMapView.swift */,
@@ -2191,7 +2188,6 @@
21912188
05DBBB622B164D9A00B6F110 /* RealOPElement.swift in Sources */,
21922189
97AC1C0A2B6B7F10004F0BF4 /* CustomVerticalButtonsList.swift in Sources */,
21932190
FAE258522D3A780F00D2BB12 /* FloatingActionButtonStack.swift in Sources */,
2194-
FA50718E2D54E1D200CE9798 /* BingTileOverlay.swift in Sources */,
21952191
FA8C74C22C4E89C800D28220 /* LongForm.swift in Sources */,
21962192
FA9F38222DC93F5300D7AABF /* UndoSidebarView.swift in Sources */,
21972193
FAC9E60F2B04F9C800E2C608 /* OverpassRequestManager.swift in Sources */,

GoInfoGame/GoInfoGame/UI/Map/BingTileOverlay.swift

Lines changed: 0 additions & 45 deletions
This file was deleted.

GoInfoGame/GoInfoGame/UI/Map/CustomMap.swift

Lines changed: 1 addition & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,7 @@ struct CustomMap: UIViewRepresentable {
3535
var onMapViewCreated: ((MKMapView) -> Void)?
3636

3737
var contextualInfo: ((String) -> Void)?
38-
39-
@Binding var useBingMaps: Bool
40-
38+
4139
@Binding var tappedCoordinate: CLLocationCoordinate2D?
4240

4341
@Binding var annotationCoordinate: CLLocationCoordinate2D?
@@ -55,15 +53,6 @@ struct CustomMap: UIViewRepresentable {
5553
mapView.userTrackingMode = trackingMode.mkUserTrackingMode
5654
// Hide points of interest except street names
5755
mapView.register(CustomAnnotationView.self, forAnnotationViewWithReuseIdentifier: CustomAnnotationView.reuseIdentifier)
58-
59-
if useBingMaps {
60-
let tileOverlay = BingTileOverlay()
61-
tileOverlay.minimumZ = 3 // Set minimum zoom level
62-
tileOverlay.maximumZ = 150 // Set maximum zoom level for better performance
63-
DispatchQueue.main.async {
64-
mapView.addOverlay(tileOverlay, level: .aboveLabels)
65-
}
66-
}
6756

6857
if case .wmts(let satelliteServer) = selectedSattiliteOption {
6958
mapView.addOverlay(WMTSSeever(satelliteServer: satelliteServer), level: .aboveLabels)
@@ -105,15 +94,6 @@ struct CustomMap: UIViewRepresentable {
10594
mapView.overlays.forEach { mapView.removeOverlay($0) }
10695

10796
mapView.addOverlay(shadowOverlay)
108-
109-
110-
// Re-add overlays based on selection
111-
if useBingMaps {
112-
let tileOverlay = BingTileOverlay()
113-
tileOverlay.minimumZ = 3
114-
tileOverlay.maximumZ = 19
115-
mapView.addOverlay(tileOverlay, level: .aboveLabels)
116-
}
11797

11898
if case .wmts(let satelliteServer) = selectedSattiliteOption {
11999
mapView.addOverlay(WMTSSeever(satelliteServer: satelliteServer), level: .aboveLabels)

GoInfoGame/GoInfoGame/UI/Map/MapView.swift

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,6 @@ struct MapView: View {
3030

3131
@AppStorage("baseUrl") var baseUrl = ""
3232

33-
@State private var useBingMaps = false
34-
3533
@State private var showSattiliteSelectionSheet: Bool = false
3634

3735
@State private var tappedCoordinate: CLLocationCoordinate2D? = nil
@@ -94,7 +92,6 @@ struct MapView: View {
9492
selectedDetent = .fraction(0.8)
9593
self.setContextualInfo(contextualinfo: contextualInfo)
9694
},
97-
useBingMaps: $useBingMaps,
9895
tappedCoordinate: $tappedCoordinate,
9996
annotationCoordinate: $annotationCoordinate,
10097
shadowOverlay: shadowOverlay)
@@ -169,7 +166,7 @@ struct MapView: View {
169166
FloatingActionButtonStack(mapButtonAction: {
170167
viewModel.updateOptions(for: mapViewRef?.region.center ?? CLLocationCoordinate2D(latitude: 0.0, longitude: 0.0))
171168
viewModel.showSatellitePicker = true
172-
}, useBingMaps: useBingMaps)
169+
})
173170
}
174171
}
175172

GoInfoGame/GoInfoGame/UI/Utils/FloatingActionButtonStack.swift

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ import SwiftUI
1010
struct FloatingActionButtonStack: View {
1111

1212
var mapButtonAction: () -> ()
13-
var useBingMaps: Bool
1413
@State private var showBottomSheet = false
1514

1615
var body: some View {
@@ -19,7 +18,7 @@ struct FloatingActionButtonStack: View {
1918
HStack {
2019
Spacer()
2120
VStack {
22-
MapSwitcherButton(action: mapButtonAction, useBingMaps: useBingMaps)
21+
MapSwitcherButton(action: mapButtonAction)
2322

2423
Button(action: {
2524
showBottomSheet.toggle()
@@ -48,13 +47,12 @@ struct FloatingActionButtonStack: View {
4847
}
4948
}
5049
#Preview {
51-
FloatingActionButtonStack(mapButtonAction: {}, useBingMaps: false)
50+
FloatingActionButtonStack(mapButtonAction: {})
5251
}
5352

5453
struct MapSwitcherButton: View {
5554

5655
var action: () -> ()
57-
var useBingMaps: Bool
5856

5957
var body: some View {
6058
Button(action:
@@ -66,7 +64,7 @@ struct MapSwitcherButton: View {
6664
.frame(width: 40, height: 40)
6765
.shadow(radius: 5)
6866

69-
Image(systemName: useBingMaps ? "square.3.layers.3d" : "map")
67+
Image(systemName: "map")
7068
.font(.system(size: 28))
7169
.foregroundColor(.white)
7270
}

0 commit comments

Comments
 (0)