AvaloniaUtils / DialogHost.Avalonia

AvaloniaUI control that provides a simple way to display a dialog with information or prompt the user when information is needed
MIT License
228 stars 15 forks source link

The application crashes after the keyboard is output and clicking on the View closure #12

Closed DenisTukhvatshin closed 1 year ago

DenisTukhvatshin commented 1 year ago

Actions: 1) Add in View TextBox and Button with CloseDialogCommand 2) Run application in Android 3) Show View 4) Click in the text box, the android keyboard appears on the screen 5) Click to close Button 6) We see that the application has terminated with an error

SKProCH commented 1 year ago

Hello, @DenisT90

Can you provide error details (error message and stacktrace) and minimum reproduceable example please?
I'll try to look soon.

DenisTukhvatshin commented 1 year ago

https://github.com/DenisT90/AvaloniaDialogHostBugWithKeyboard I created repo for you)

SKProCH commented 1 year ago

Seems like this is an Avalonia bug. I've updated Avalonia to 11.0.0-preview3 and seems all working fine now.

DenisTukhvatshin commented 1 year ago

Seems like this is an Avalonia bug. I've updated Avalonia to 11.0.0-preview3 and seems all working fine now.

How you updated it? I Changed file Directory.Build.Props to:

<Project>
  <PropertyGroup>
    <AvaloniaVersion>11.0.0-preview3</AvaloniaVersion>
  </PropertyGroup>
</Project>

And in Android Project MainActivity.cs to:

    public class MainActivity : AvaloniaMainActivity
    {
    }

After that, I started android, it crashes

SKProCH commented 1 year ago

I've created a pull request for you: https://github.com/DenisT90/AvaloniaDialogHostBugWithKeyboard/pull/1