diff options
-rw-r--r-- | Xamarin.Forms.Platform.Android/AppCompat/FormsAppCompatActivity.cs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Xamarin.Forms.Platform.Android/AppCompat/FormsAppCompatActivity.cs b/Xamarin.Forms.Platform.Android/AppCompat/FormsAppCompatActivity.cs index 4ca0eab8..8bba063b 100644 --- a/Xamarin.Forms.Platform.Android/AppCompat/FormsAppCompatActivity.cs +++ b/Xamarin.Forms.Platform.Android/AppCompat/FormsAppCompatActivity.cs @@ -236,7 +236,7 @@ namespace Xamarin.Forms.Platform.Android // counterpart to OnPause base.OnResume(); - if (_application.OnThisPlatform().GetShouldPreserveKeyboardOnResume()) + if (_application != null && _application.OnThisPlatform().GetShouldPreserveKeyboardOnResume()) { if (CurrentFocus != null && (CurrentFocus is EditText || CurrentFocus is TextView || CurrentFocus is SearchView)) { @@ -568,4 +568,4 @@ namespace Xamarin.Forms.Platform.Android #endregion } -}
\ No newline at end of file +} |