user32: Don't show the icon title for off-screen icons.

This commit is contained in:
Alexandre Julliard 2012-10-15 16:17:46 +02:00
parent 0bc93684f0
commit 49a5db3869
1 changed files with 34 additions and 33 deletions

View File

@ -660,17 +660,20 @@ BOOL WINPOS_RedrawIconTitle( HWND hWnd )
/*********************************************************************** /***********************************************************************
* WINPOS_ShowIconTitle * WINPOS_ShowIconTitle
*/ */
static BOOL WINPOS_ShowIconTitle( HWND hwnd, BOOL bShow ) static void WINPOS_ShowIconTitle( HWND hwnd, BOOL bShow )
{
if (!GetPropA( hwnd, "__wine_x11_managed" ))
{ {
WND *win = WIN_GetPtr( hwnd ); WND *win = WIN_GetPtr( hwnd );
HWND title = 0; HWND title = 0;
TRACE("%p %i\n", hwnd, (bShow != 0) ); TRACE("%p %i\n", hwnd, (bShow != 0) );
if (!win || win == WND_OTHER_PROCESS || win == WND_DESKTOP) return FALSE; if (!win || win == WND_OTHER_PROCESS || win == WND_DESKTOP) return;
title = win->icon_title; if (win->rectWindow.left == -32000 || win->rectWindow.top == -32000)
{
TRACE( "not showing title for hidden icon %p\n", hwnd );
bShow = FALSE;
}
else title = win->icon_title;
WIN_ReleasePtr( win ); WIN_ReleasePtr( win );
if (bShow) if (bShow)
@ -681,7 +684,7 @@ static BOOL WINPOS_ShowIconTitle( HWND hwnd, BOOL bShow )
if (!(win = WIN_GetPtr( hwnd )) || win == WND_OTHER_PROCESS) if (!(win = WIN_GetPtr( hwnd )) || win == WND_OTHER_PROCESS)
{ {
DestroyWindow( title ); DestroyWindow( title );
return FALSE; return;
} }
win->icon_title = title; win->icon_title = title;
WIN_ReleasePtr( win ); WIN_ReleasePtr( win );
@ -695,8 +698,6 @@ static BOOL WINPOS_ShowIconTitle( HWND hwnd, BOOL bShow )
} }
else if (title) ShowWindow( title, SW_HIDE ); else if (title) ShowWindow( title, SW_HIDE );
} }
return FALSE;
}
/******************************************************************* /*******************************************************************
* WINPOS_GetMinMaxInfo * WINPOS_GetMinMaxInfo