diff --git a/src/MapKit/MKFeatureDisplayPriority.cs b/src/MapKit/MKFeatureDisplayPriority.cs index 995b44fbd1..023b423d4d 100644 --- a/src/MapKit/MKFeatureDisplayPriority.cs +++ b/src/MapKit/MKFeatureDisplayPriority.cs @@ -9,10 +9,14 @@ namespace MapKit { #if !WATCH || (WATCH && !NET) #if NET - [SupportedOSPlatform ("ios11.0")] [SupportedOSPlatform ("tvos11.0")] + [SupportedOSPlatform ("ios11.0")] + [SupportedOSPlatform ("macos10.13")] #else - [TV (11,0)][NoWatch][iOS (11,0)][Mac (10,13)] + [TV (11,0)] + [NoWatch] + [iOS (11,0)] + [Mac (10,13)] #endif #if WATCH && !NET [Obsolete ("This API is not available on this platform.")] diff --git a/src/MapKit/MKMapItem.cs b/src/MapKit/MKMapItem.cs index d5b4f9888e..db138eecc6 100644 --- a/src/MapKit/MKMapItem.cs +++ b/src/MapKit/MKMapItem.cs @@ -22,9 +22,14 @@ namespace MapKit { public enum MKDirectionsMode { Driving, Walking, Transit, #if NET + [SupportedOSPlatform ("ios10.0")] + [SupportedOSPlatform ("macos10.12")] [UnsupportedOSPlatform ("tvos")] #else - [iOS (10,0)][NoTV][Watch (3,0)][Mac (10,12)] + [iOS (10,0)] + [NoTV] + [Watch (3,0)] + [Mac (10,12)] #endif Default } @@ -43,7 +48,9 @@ namespace MapKit { #if !WATCH // The corresponding key (MKLaunchOptionsCameraKey) is allowed in WatchOS, but there's no MKMapCamera type. -#if !NET +#if NET + [SupportedOSPlatform ("ios7.0")] +#else [iOS (7,0)] #endif public MKMapCamera? Camera { get; set; } diff --git a/src/MapKit/MKOverlayView.cs b/src/MapKit/MKOverlayView.cs index bc9b5cb0fa..ec3fda9f78 100644 --- a/src/MapKit/MKOverlayView.cs +++ b/src/MapKit/MKOverlayView.cs @@ -6,6 +6,7 @@ using System; using System.Runtime.InteropServices; +using System.Runtime.Versioning; using Foundation; using ObjCRuntime; using MapKit; @@ -15,7 +16,14 @@ using MapKit; namespace MapKit { public partial class MKOverlayView { -#if !NET +#if NET + [SupportedOSPlatform ("tvos9.2")] + [SupportedOSPlatform ("macos10.9")] + [UnsupportedOSPlatform ("ios7.0")] +#if IOS + [Obsolete ("Starting with ios7.0 use 'MKOverlayRenderer' instead.", DiagnosticId = "BI1234", UrlFormat = "https://github.com/xamarin/xamarin-macios/wiki/Obsolete")] +#endif +#else [TV (9,2)] [Mac (10,9)] #endif diff --git a/src/MapKit/MapKit.cs b/src/MapKit/MapKit.cs index 0922389ac5..6199c6ee50 100644 --- a/src/MapKit/MapKit.cs +++ b/src/MapKit/MapKit.cs @@ -10,6 +10,7 @@ using System; using System.Runtime.InteropServices; +using System.Runtime.Versioning; using CoreGraphics; using CoreLocation; using Foundation; @@ -52,10 +53,12 @@ namespace MapKit { } // MKGeometry.h - [StructLayout (LayoutKind.Sequential)] -#if !NET +#if NET + [SupportedOSPlatform ("macos10.9")] +#else [Mac (10,9)] #endif + [StructLayout (LayoutKind.Sequential)] public struct MKCoordinateRegion { public CLLocationCoordinate2D Center; public MKCoordinateSpan Span; @@ -81,10 +84,12 @@ namespace MapKit { } // MKGeometry.h - [StructLayout (LayoutKind.Sequential)] -#if !NET +#if NET + [SupportedOSPlatform ("macos10.9")] +#else [Mac (10,9)] #endif + [StructLayout (LayoutKind.Sequential)] public struct MKMapPoint { public double X, Y; @@ -146,7 +151,9 @@ namespace MapKit { Height = height; } -#if !NET +#if NET + [SupportedOSPlatform ("tvos9.2")] +#else [TV (9,2)] #endif public static MKMapSize World { get { return new MKMapSize (0x10000000, 0x10000000); }} @@ -185,12 +192,17 @@ namespace MapKit { } // MKGeometry.h - [StructLayout (LayoutKind.Sequential)] -#if !NET +#if NET + [SupportedOSPlatform ("macos10.9")] +#else [Mac (10,9)] #endif + [StructLayout (LayoutKind.Sequential)] public struct MKMapRect { -#if !NET +#if NET + [SupportedOSPlatform ("tvos9.2")] + [SupportedOSPlatform ("macos10.9")] +#else [TV (9,2)] #endif public static readonly MKMapRect Null = new MKMapRect (double.PositiveInfinity, double.PositiveInfinity, 0, 0); @@ -283,7 +295,10 @@ namespace MapKit { } } -#if !NET +#if NET + [SupportedOSPlatform ("tvos9.2")] + [SupportedOSPlatform ("macos10.9")] +#else [TV (9,2)] #endif public MKMapRect World { @@ -396,7 +411,9 @@ namespace MapKit { } // MKGeometry.h -#if !NET +#if NET + [SupportedOSPlatform ("macos10.9")] +#else [Mac (10,9)] #endif public static class MKGeometry {