@zenkit-dev/cordova-plugin-keyboard 1.3.0-dev.0 → 1.3.0-dev.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zenkit-dev/cordova-plugin-keyboard",
3
- "version": "1.3.0-dev.0",
3
+ "version": "1.3.0-dev.1",
4
4
  "description": "Cordova Keyboard Plugin",
5
5
  "cordova": {
6
6
  "id": "cordova-plugin-keyboard",
@@ -1,9 +1,10 @@
1
1
  #import "CDVKeyboard.h"
2
+ #import <UIKit/UIKit.h>
2
3
  #import <Cordova/CDVAvailability.h>
3
4
  #import <Cordova/NSDictionary+CordovaPreferences.h>
4
5
  #import <objc/runtime.h>
5
6
 
6
- @interface CDVKeyboard () <UIScrollViewDelegate>
7
+ @interface CDVKeyboard ()
7
8
 
8
9
  @property(nonatomic, readwrite, assign) BOOL keyboardIsVisible;
9
10
  @property(readwrite, assign, nonatomic) BOOL keyboardShrinksView;
@@ -235,22 +236,14 @@ static IMP WKOriginalImp;
235
236
  }
236
237
 
237
238
  #pragma mark KeyboardDisablesScrolling
238
- - (void)scrollViewDidScroll:(UIScrollView *)scrollView {
239
- [scrollView setContentOffset:CGPointZero];
240
- }
241
-
242
239
  - (void)setKeyboardDisablesScrolling:(BOOL)keyboardDisablesScrolling {
243
240
  if (keyboardDisablesScrolling == _keyboardDisablesScrolling) {
244
241
  return;
245
242
  }
246
243
 
247
- if (keyboardDisablesScrolling) {
248
- self.webView.scrollView.scrollEnabled = NO;
249
- self.webView.scrollView.delegate = self;
250
- } else {
251
- self.webView.scrollView.scrollEnabled = YES;
252
- self.webView.scrollView.delegate = nil;
253
- }
244
+ // Do not assign scrollView.delegate: CDVViewController uses it for
245
+ // built-in status-bar inset tracking on cordova-ios 8.
246
+ self.webView.scrollView.scrollEnabled = !keyboardDisablesScrolling;
254
247
 
255
248
  _keyboardDisablesScrolling = keyboardDisablesScrolling;
256
249
  }