wineandroid: Properly clean up windows that aren't destroyed explicitly.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
e6fdea726a
commit
c339d7214c
|
@ -314,7 +314,9 @@ public WineWindow( int w, WineWindow parent )
|
|||
public void destroy()
|
||||
{
|
||||
Log.i( LOGTAG, String.format( "destroy hwnd %08x", hwnd ));
|
||||
if (visible && window_view != null) top_view.removeView( window_view );
|
||||
visible = false;
|
||||
window_view = null;
|
||||
win_map.remove( this );
|
||||
}
|
||||
|
||||
|
|
|
@ -828,8 +828,6 @@ BOOL CDECL ANDROID_CreateWindow( HWND hwnd )
|
|||
|
||||
init_event_queue();
|
||||
start_android_device();
|
||||
desktop_orig_wndproc = (WNDPROC)SetWindowLongPtrW( hwnd, GWLP_WNDPROC,
|
||||
(LONG_PTR)desktop_wndproc_wrapper );
|
||||
if (!(data = alloc_win_data( hwnd ))) return FALSE;
|
||||
release_win_data( data );
|
||||
}
|
||||
|
@ -1214,6 +1212,9 @@ LRESULT CDECL ANDROID_WindowMessage( HWND hwnd, UINT msg, WPARAM wp, LPARAM lp )
|
|||
*/
|
||||
BOOL CDECL ANDROID_create_desktop( UINT width, UINT height )
|
||||
{
|
||||
desktop_orig_wndproc = (WNDPROC)SetWindowLongPtrW( GetDesktopWindow(), GWLP_WNDPROC,
|
||||
(LONG_PTR)desktop_wndproc_wrapper );
|
||||
|
||||
/* wait until we receive the surface changed event */
|
||||
while (!screen_width)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue