You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by sh...@apache.org on 2012/09/19 22:51:50 UTC

[5/5] ios commit: additional changes for CB-1461

additional changes for CB-1461


Project: http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/commit/6351d49c
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/tree/6351d49c
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/diff/6351d49c

Branch: refs/heads/master
Commit: 6351d49c78c3d49b56d7ff330c5bf259b0917424
Parents: 916c407
Author: hermwong <he...@gmail.com>
Authored: Tue Sep 18 11:31:08 2012 -0700
Committer: Shazron Abdullah <sh...@apache.org>
Committed: Wed Sep 19 13:10:26 2012 -0700

----------------------------------------------------------------------
 CordovaLib/Classes/CDVViewController.m |   19 ++++++++++++++-----
 1 files changed, 14 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/blob/6351d49c/CordovaLib/Classes/CDVViewController.m
----------------------------------------------------------------------
diff --git a/CordovaLib/Classes/CDVViewController.m b/CordovaLib/Classes/CDVViewController.m
index 1521304..62f84f7 100644
--- a/CordovaLib/Classes/CDVViewController.m
+++ b/CordovaLib/Classes/CDVViewController.m
@@ -268,13 +268,22 @@
      */
     if (IsAtLeastiOSVersion(@"6.0")) {
         BOOL keyboardDisplayRequiresUserAction = YES; // KeyboardDisplayRequiresUserAction - defaults to YES
-        if ([self.settings objectForKey:@"KeyboardDisplayRequiresUserAction"]) {
-            keyboardDisplayRequiresUserAction = [(NSNumber*)[self.settings objectForKey:@"KeyboardDisplayRequiresUserAction"] boolValue];
-        }        
+        if ([self.settings objectForKey:@"KeyboardDisplayRequiresUserAction"] != nil) {
+            if ([self.settings objectForKey:@"KeyboardDisplayRequiresUserAction"]) {
+                keyboardDisplayRequiresUserAction = [(NSNumber*)[self.settings objectForKey:@"KeyboardDisplayRequiresUserAction"] boolValue];
+            }
+        }
+
+        self.webView.keyboardDisplayRequiresUserAction = keyboardDisplayRequiresUserAction;
+        
         BOOL suppressesIncrementalRendering = NO; // SuppressesIncrementalRendering - defaults to NO
-        if ([self.settings objectForKey:@"SuppressesIncrementalRendering"]) {
-            suppressesIncrementalRendering = [(NSNumber*)[self.settings objectForKey:@"SuppressesIncrementalRendering"] boolValue];
+        if ([self.settings objectForKey:@"SuppressesIncrementalRendering"] != nil) {
+            if ([self.settings objectForKey:@"SuppressesIncrementalRendering"]) {
+                suppressesIncrementalRendering = [(NSNumber*)[self.settings objectForKey:@"SuppressesIncrementalRendering"] boolValue];
+            }
         }
+        
+        self.webView.suppressesIncrementalRendering = suppressesIncrementalRendering;
     }
     
     ///////////////////