//------------------------------------------------------------------------------ static void _calculate_obscure( void ) { __QCS_FCONTEXT( "_calculate_obscure" ); PANEL* pan, *pan2; PANELOBS* tobs; // "this" one PANELOBS* lobs; // last one pan = _bottom_panel; while( pan ) { if( pan->obscure ) { _free_obscure( pan ); } lobs = (PANELOBS*)0; pan2 = _bottom_panel; while( pan2 ) { if( _panels_overlapped( pan, pan2 ) ) { if( ( tobs = (PANELOBS*)( malloc( sizeof(PANELOBS) ) ) ) == NULL ) { return; } tobs->pan = pan2; dPanel( "obscured", pan2 ); tobs->above = (PANELOBS*)0; if( lobs ) { lobs->above = tobs; } else { pan->obscure = tobs; } lobs = tobs; } pan2 = pan2->above; } _override( pan, 1 ); pan = pan->above; } }
static void _calculate_obscure(void) { PANEL *pan, *pan2; PANELOBS *tobs; /* "this" one */ PANELOBS *lobs; /* last one */ pan = _bottom_panel; while (pan) { if (pan->obscure) _free_obscure(pan); lobs = (PANELOBS *)0; pan2 = _bottom_panel; while (pan2) { if (_panels_overlapped(pan, pan2)) { if ((tobs = malloc(sizeof(PANELOBS))) == NULL) return; tobs->pan = pan2; dPanel("obscured", pan2); tobs->above = (PANELOBS *)0; if (lobs) lobs->above = tobs; else pan->obscure = tobs; lobs = tobs; } pan2 = pan2->above; } _override(pan, 1); pan = pan->above; } }