Hi all, >From the following code, I can see only if the last child of pWin is a WORKWINDOW *as well as* a MENUBARWINDOW, the function will return TRUE.
All the status of the former child will be overwrite by the last one. Is this the thing the function do? If so, why use a loop to read the status of the former children and overwrite it with the status of the latter one? And what is a WORKWINDOW? Thank you very much. The following code are copied from OOoSrc/automation/server/sta_list.cxx <quote> // a Doc Frame is a Document or the Backing Window BOOL StatementList::IsDocFrame( Window* pWin ) { if ( pWin && pWin->IsVisible() && pWin->GetType() == WINDOW_BORDERWINDOW ) { USHORT nCount; BOOL bHasWorkWindow = FALSE; BOOL bHasMenuBar = FALSE; /* #91724# it is now necessary to sort out the IME WIndow in Solaris as well. so now we check for existence of WINDOW_WORKWINDOW and newly for WINDOW_MENUBARWINDOW which contains the Menu and the close/min/max buttons*/ for ( nCount = 0 ; nCount < pWin->GetChildCount() ; nCount++ ) { if ( pWin->GetChild( nCount )->GetType() == WINDOW_WORKWINDOW ) bHasWorkWindow = TRUE; if ( pWin->GetChild( nCount )->GetType() == WINDOW_MENUBARWINDOW ) bHasMenuBar = TRUE; } return bHasWorkWindow && bHasMenuBar; } return FALSE; } </quote> -- Lihua 北京红旗贰仟软件技术有限公司 Beijing Redflag 2000 Software Co., Ltd. Building No.2, Block A, Huilongsen, 18 Xihuan Nanlu Beijing Economic-Technological Development Area Beijing - P.R.China Tel:+86-10-51570010 ext.6141 http://www.RedOffice.com --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@framework.openoffice.org For additional commands, e-mail: dev-h...@framework.openoffice.org