Browse Source
Merge pull request #10811 from AvaloniaUI/null-ref-textclient
Android - Don't create an input connection if client is null
pull/10824/head
Max Katz
3 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
3 additions and
1 deletions
-
src/Android/Avalonia.Android/AndroidInputMethod.cs
|
|
|
@ -1,7 +1,6 @@ |
|
|
|
using System; |
|
|
|
using Android.Content; |
|
|
|
using Android.Runtime; |
|
|
|
using Android.Text; |
|
|
|
using Android.Views; |
|
|
|
using Android.Views.InputMethods; |
|
|
|
using Avalonia.Android.Platform.SkiaPlatform; |
|
|
|
@ -99,6 +98,9 @@ namespace Avalonia.Android |
|
|
|
{ |
|
|
|
_host.InitEditorInfo((topLevel, outAttrs) => |
|
|
|
{ |
|
|
|
if (_client == null) |
|
|
|
return null; |
|
|
|
|
|
|
|
_inputConnection = new AvaloniaInputConnection(topLevel, this); |
|
|
|
|
|
|
|
outAttrs.InputType = options.ContentType switch |
|
|
|
|