From 07662d9686c504d51460180bcf012dc6f5457406 Mon Sep 17 00:00:00 2001 From: Matthew Leibowitz Date: Thu, 19 Oct 2017 02:38:00 +0200 Subject: [PATCH 1/2] [SlackTextViewController] Updated to (almost) v1.9.6 to fix iOS 11 bugs --- iOS/SlackTextViewController/build.cake | 2 +- .../component/component.yaml | 4 +- .../nuget/SlackTextViewController.nuspec | 2 +- .../SlackTextViewController/ApiDefinition.cs | 41 ++++++++++++------- .../libSlackTextViewController.linkwith.cs | 2 +- 5 files changed, 31 insertions(+), 20 deletions(-) diff --git a/iOS/SlackTextViewController/build.cake b/iOS/SlackTextViewController/build.cake index ddb9fd1a56..62e502c2fa 100644 --- a/iOS/SlackTextViewController/build.cake +++ b/iOS/SlackTextViewController/build.cake @@ -7,7 +7,7 @@ var IOS_PODS = new List { "platform :ios, '7.0'", "install! 'cocoapods', :integrate_targets => false", "target 'Xamarin' do", - "pod 'SlackTextViewController', '1.9.5'", + " pod 'SlackTextViewController', :git => 'https://github.com/slackhq/SlackTextViewController.git', :commit => '4c74cbab29408dda9af33633f86dcc983a3b5363'", "end", }; diff --git a/iOS/SlackTextViewController/component/component.yaml b/iOS/SlackTextViewController/component/component.yaml index 00eb11d32d..1e858a8998 100644 --- a/iOS/SlackTextViewController/component/component.yaml +++ b/iOS/SlackTextViewController/component/component.yaml @@ -1,4 +1,4 @@ -version: "1.9.5" +version: "1.9.6" name: SlackTextViewController id: SlackTextViewController publisher: Xamarin Inc @@ -13,7 +13,7 @@ no_build: true is_shell: true local-nuget-repo: ../output packages: - ios-unified: Xamarin.SlackTextViewController, Version=1.9.5 + ios-unified: Xamarin.SlackTextViewController, Version=1.9.6 libraries: ios-unified: ../output/unified/SlackTextViewController.dll diff --git a/iOS/SlackTextViewController/nuget/SlackTextViewController.nuspec b/iOS/SlackTextViewController/nuget/SlackTextViewController.nuspec index 8a27673553..97063b20af 100644 --- a/iOS/SlackTextViewController/nuget/SlackTextViewController.nuspec +++ b/iOS/SlackTextViewController/nuget/SlackTextViewController.nuspec @@ -3,7 +3,7 @@ Xamarin.SlackTextViewController SlackTextViewController for Xamarin.iOS - 1.9.5 + 1.9.6 Xamarin Inc. Xamarin Inc. false diff --git a/iOS/SlackTextViewController/source/SlackTextViewController/ApiDefinition.cs b/iOS/SlackTextViewController/source/SlackTextViewController/ApiDefinition.cs index 8a51dd342e..537d755ea0 100644 --- a/iOS/SlackTextViewController/source/SlackTextViewController/ApiDefinition.cs +++ b/iOS/SlackTextViewController/source/SlackTextViewController/ApiDefinition.cs @@ -48,8 +48,8 @@ interface SlackTextInput : IUITextInput string WordAt (NSRange range, ref NSRange rangeInText); } - // @interface SLKTextInputbar : UIToolbar - [BaseType (typeof(UIToolbar), Name = "SLKTextInputbar")] + // @interface SLKTextInputbar : UIView + [BaseType (typeof(UIView), Name = "SLKTextInputbar")] interface SlackTextInputbar { // extern NSString *const SLKTextInputbarDidMoveNotification __attribute__((visibility("default"))); @@ -58,11 +58,15 @@ interface SlackTextInputbar NSString DidMoveNotification { get; } - // @property (nonatomic, strong) SLKTextView * textView; + // @property (nonatomic, readonly, strong) SLKTextView * textView; [Export ("textView", ArgumentSemantic.Strong)] - SlackTextView TextView { get; set; } + SlackTextView TextView { get; } + + // @property (nonatomic, readonly, strong) UIView *contentView; + [Export ("contentView", ArgumentSemantic.Strong)] + UIView ContentView { get; } - // @property (nonatomic, strong) SLKInputAccessoryView * inputAccessoryView; + // @property (nonatomic, readonly, strong) SLKInputAccessoryView * inputAccessoryView; [Export ("inputAccessoryView", ArgumentSemantic.Strong)] SlackInputAccessoryView SlackInputAccessoryView { get; } @@ -224,6 +228,10 @@ interface SlackTextView : SlackTextInput [Export ("placeholderNumberOfLines")] nint PlaceholderNumberOfLines { get; set; } + // @property (nonatomic, copy, null_resettable) UIFont *placeholderFont; + [NullAllowed, Export ("placeholderFont")] + UIFont PlaceholderFont { get; set; } + // @property (readwrite, nonatomic) NSUInteger maxNumberOfLines; [Export ("maxNumberOfLines")] nuint MaxNumberOfLines { get; set; } @@ -620,17 +628,17 @@ interface SlackTextViewController : SlackTextViewDelegate, IUITableViewDelegate, [Export ("autoCompleting")] bool AutoCompleting { [Bind ("isAutoCompleting")] get; } - // @property (readonly, copy, nonatomic) NSString * foundPrefix; + // @property (copy, nonatomic) NSString * foundPrefix; [NullAllowed, Export ("foundPrefix")] - string FoundPrefix { get; } + string FoundPrefix { get; set; } - // @property (readonly, nonatomic) NSRange foundPrefixRange; + // @property (nonatomic) NSRange foundPrefixRange; [Export ("foundPrefixRange")] - NSRange FoundPrefixRange { get; } + NSRange FoundPrefixRange { get; set; } - // @property (readonly, copy, nonatomic) NSString * foundWord; + // @property (copy, nonatomic) NSString * foundWord; [NullAllowed, Export ("foundWord")] - string FoundWord { get; } + string FoundWord { get; set; } // @property (readonly, copy, nonatomic) NSArray * registeredPrefixes; [Export ("registeredPrefixes", ArgumentSemantic.Copy)] @@ -640,10 +648,13 @@ interface SlackTextViewController : SlackTextViewDelegate, IUITableViewDelegate, [Export ("registerPrefixesForAutoCompletion:")] void RegisterPrefixesForAutoCompletion ([NullAllowed] string[] prefixes); - // -(BOOL)shouldProcessTextForAutoCompletion:(NSString * _Nonnull)text __attribute__((objc_requires_super)); - [Export ("shouldProcessTextForAutoCompletion:")] -// [RequiresSuper] - bool ShouldProcessTextForAutoCompletion (string text); + // - (BOOL)shouldProcessTextForAutoCompletion; + [Export ("shouldProcessTextForAutoCompletion")] + bool ShouldProcessTextForAutoCompletion { get; } + + // - (BOOL)shouldDisableTypingSuggestionForAutoCompletion; + [Export ("shouldDisableTypingSuggestionForAutoCompletion")] + bool ShouldDisableTypingSuggestionForAutoCompletion { get; } // -(void)didChangeAutoCompletionPrefix:(NSString *)prefix andWord:(NSString *)word; [Export ("didChangeAutoCompletionPrefix:andWord:")] diff --git a/iOS/SlackTextViewController/source/SlackTextViewController/libSlackTextViewController.linkwith.cs b/iOS/SlackTextViewController/source/SlackTextViewController/libSlackTextViewController.linkwith.cs index 221f40effc..b5a03e1fdd 100644 --- a/iOS/SlackTextViewController/source/SlackTextViewController/libSlackTextViewController.linkwith.cs +++ b/iOS/SlackTextViewController/source/SlackTextViewController/libSlackTextViewController.linkwith.cs @@ -8,7 +8,7 @@ #endif [assembly: AssemblyVersion ("1.9.0.0")] -[assembly: AssemblyFileVersion ("1.9.0.0")] +[assembly: AssemblyFileVersion ("1.9.6.0")] [assembly: LinkWith ( "libSlackTextViewController.a", From 092fd428b011c39f9686654cb095a8f92bebbee2 Mon Sep 17 00:00:00 2001 From: Matthew Leibowitz Date: Thu, 19 Oct 2017 22:49:53 +0200 Subject: [PATCH 2/2] [SlackTextViewController] This release is a preview since the native version hasn't gone official --- .../nuget/SlackTextViewController.nuspec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/iOS/SlackTextViewController/nuget/SlackTextViewController.nuspec b/iOS/SlackTextViewController/nuget/SlackTextViewController.nuspec index 97063b20af..ac1d2e6381 100644 --- a/iOS/SlackTextViewController/nuget/SlackTextViewController.nuspec +++ b/iOS/SlackTextViewController/nuget/SlackTextViewController.nuspec @@ -3,7 +3,7 @@ Xamarin.SlackTextViewController SlackTextViewController for Xamarin.iOS - 1.9.6 + 1.9.6-preview Xamarin Inc. Xamarin Inc. false