From a1f0518d0cd123a791adde64f4f11bd8e44276c7 Mon Sep 17 00:00:00 2001 From: ivar Date: Mon, 20 Oct 2025 00:26:34 +0200 Subject: Initial commit --- "ios/H\303\246-appen/LocationAuthorizer.swift" | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 "ios/H\303\246-appen/LocationAuthorizer.swift" (limited to 'ios/Hæ-appen/LocationAuthorizer.swift') diff --git "a/ios/H\303\246-appen/LocationAuthorizer.swift" "b/ios/H\303\246-appen/LocationAuthorizer.swift" new file mode 100644 index 0000000..fb6f3c8 --- /dev/null +++ "b/ios/H\303\246-appen/LocationAuthorizer.swift" @@ -0,0 +1,20 @@ +// +// LocationAuthorizer.swift +// Hæ-appen +// +// Created by Ivar Løvlie on 16/10/2025. +// + +import SwiftUI +import MapKit +import CoreLocation + +final class LocationAuthorizer: NSObject, CLLocationManagerDelegate { + static let shared = LocationAuthorizer() + private let manager = CLLocationManager() + + func requestWhenInUse() { + manager.delegate = self + manager.requestWhenInUseAuthorization() + } +} -- cgit v1.3