From 36f2ac00b1389816ea5381545ccec54f8cda1df9 Mon Sep 17 00:00:00 2001 From: Alex Soto Date: Tue, 6 Jun 2017 18:50:13 -0500 Subject: [PATCH] [Accounts] Uodate to Xcode 9 Beta 1 Also added ACAccountStore.RemoveAccount, xtro caught this API common.unclassified:!missing-selector! ACAccountStore::removeAccount:withCompletionHandler: not bound --- src/accounts.cs | 22 ++++++++++++++++++++++ tests/xtro-sharpie/osx.pending | 3 +++ 2 files changed, 25 insertions(+) diff --git a/src/accounts.cs b/src/accounts.cs index bfd44026897e..5d9e25fdce19 100644 --- a/src/accounts.cs +++ b/src/accounts.cs @@ -66,6 +66,7 @@ interface ACAccountCredential : NSSecureCoding { } delegate void ACAccountStoreSaveCompletionHandler (bool success, NSError error); + delegate void ACAccountStoreRemoveCompletionHandler (bool success, NSError error); delegate void ACRequestCompletionHandler (bool granted, NSError error); [Since (5,0)] @@ -112,6 +113,11 @@ interface ACAccountStore { [Wrap ("RequestAccess (accountType, options == null ? null : options.Dictionary, completion)")] [Async] void RequestAccess (ACAccountType accountType, [NullAllowed] AccountStoreOptions options, ACRequestCompletionHandler completion); + + [iOS (6,0)] + [Export ("removeAccount:withCompletionHandler:")] + [Async] + void RemoveAccount (ACAccount account, ACAccountStoreRemoveCompletionHandler completionHandler); } [Since (5,0)] @@ -127,29 +133,40 @@ interface ACAccountType : NSSecureCoding { [Export ("accessGranted")] bool AccessGranted { get; } + [Deprecated (PlatformName.iOS, 11, 0, message: "Use Twitter SDK instead")] + [Deprecated (PlatformName.MacOSX, 10, 13, message: "Use Twitter SDK instead")] [Field ("ACAccountTypeIdentifierTwitter")] NSString Twitter { get; } + [Deprecated (PlatformName.iOS, 11, 0, message: "Use Sina Weibo SDK instead")] + [Deprecated (PlatformName.MacOSX, 10, 13, message: "Use Sina Weibo SDK instead")] [Since (6,0)] [Field ("ACAccountTypeIdentifierSinaWeibo")] NSString SinaWeibo { get; } + [Deprecated (PlatformName.iOS, 11, 0, message: "Use Facebook SDK instead")] + [Deprecated (PlatformName.MacOSX, 10, 13, message: "Use Facebook SDK instead")] [Since (6,0)] [Field ("ACAccountTypeIdentifierFacebook")] NSString Facebook { get; } + [Deprecated (PlatformName.iOS, 11, 0, message: "Use Tencent Weibo SDK instead")] + [Deprecated (PlatformName.MacOSX, 10, 13, message: "Use Tencent Weibo SDK instead")] [Since (7,0)] [Mac (10,9)] [Field ("ACAccountTypeIdentifierTencentWeibo")] NSString TencentWeibo { get; } #if MONOMAC + [Deprecated (PlatformName.MacOSX, 10, 13, message: "Use LinkedIn SDK instead")] [Mac (10,9)] [Field ("ACAccountTypeIdentifierLinkedIn")] NSString LinkedIn { get; } #endif } + [Deprecated (PlatformName.iOS, 11, 0, message: "Use Facebook SDK instead")] + [Deprecated (PlatformName.MacOSX, 10, 13, message: "Use Facebook SDK instead")] [Since (6,0)] [Mac (10,8, onlyOn64 : true)] [Static] @@ -165,6 +182,8 @@ interface ACFacebookKey { NSString Audience { get; } } + [Deprecated (PlatformName.iOS, 11, 0, message: "Use Facebook SDK instead")] + [Deprecated (PlatformName.MacOSX, 10, 13, message: "Use Facebook SDK instead")] [Since (6,0)] [Mac (10,8, onlyOn64 : true)] [Static] @@ -180,6 +199,8 @@ interface ACFacebookAudienceValue NSString OnlyMe { get; } } + [Deprecated (PlatformName.iOS, 11, 0, message: "Use Tencent Weibo SDK instead")] + [Deprecated (PlatformName.MacOSX, 10, 13, message: "Use Tencent Weibo SDK instead")] [Since (7,0)] [Mac (10,9, onlyOn64 : true)] [Static] @@ -189,6 +210,7 @@ interface ACTencentWeiboKey { } #if MONOMAC + [Deprecated (PlatformName.MacOSX, 10, 13, message: "Use LinkedIn SDK instead")] [Mac (10,9, onlyOn64 : true)] [Static] interface ACLinkedInKey { diff --git a/tests/xtro-sharpie/osx.pending b/tests/xtro-sharpie/osx.pending index c57a82a88a40..19f68635438e 100644 --- a/tests/xtro-sharpie/osx.pending +++ b/tests/xtro-sharpie/osx.pending @@ -456,3 +456,6 @@ !missing-selector! MPMediaEntity::objectForKeyedSubscript: not bound !missing-selector! MPMediaEntity::valueForProperty: not bound !missing-selector! MPMediaItemArtwork::imageCropRect not bound + +# Not available in OS X +!missing-selector! ACAccount::userFullName not bound