Commit 5b056f61 authored by Alexandre Julliard's avatar Alexandre Julliard

wineandroid: Forward the destroy window ioctl to Java even if the window was freed already.

parent 28c040c9
......@@ -358,7 +358,8 @@ public class WineActivity extends Activity
{
if (window_group != null)
{
if (parent != null) parent.client_group.removeView( window_group );
if (parent != null && parent.client_group != null)
parent.client_group.removeView( window_group );
window_group.destroy_view();
}
if (client_group != null) client_group.destroy_view();
......
......@@ -604,7 +604,7 @@ static NTSTATUS destroyWindow_ioctl( void *data, DWORD in_size, DWORD out_size,
if (in_size < sizeof(*res)) return STATUS_INVALID_PARAMETER;
if (!(win_data = get_ioctl_native_win_data( &res->hdr ))) return STATUS_INVALID_HANDLE;
win_data = get_ioctl_native_win_data( &res->hdr );
TRACE( "hwnd %08x opengl %u\n", res->hdr.hwnd, res->hdr.opengl );
......@@ -613,7 +613,7 @@ static NTSTATUS destroyWindow_ioctl( void *data, DWORD in_size, DWORD out_size,
wrap_java_call();
(*jni_env)->CallVoidMethod( jni_env, object, method, res->hdr.hwnd );
unwrap_java_call();
free_native_win_data( win_data );
if (win_data) free_native_win_data( win_data );
return STATUS_SUCCESS;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment