Lines Matching refs:other_owl

415 static void InsertOwlAbove(OtpWinList *owl, OtpWinList *other_owl)
423 if(other_owl != NULL) {
424 fprintf(stderr, "\n other_owl->pri=%d w=0x%x parent_vs:(x,y)=(%d,%d)",
425 PRI(other_owl),
426 (unsigned int)WindowOfOwl(other_owl),
437 if(other_owl == NULL) {
461 vs_owl = GetOwlAtOrBelowInWinbox(&other_owl, winbox);
466 vs_owl = GetOwlAtOrBelowInVS(other_owl, owl->twm_win->parent_vs);
469 assert(PRI(owl) >= PRI(other_owl));
470 if(other_owl->above != NULL) {
471 assert(PRI(owl) <= PRI(other_owl->above));
487 assert(PRI(vs_owl) <= PRI(other_owl));
498 owl->below = other_owl;
499 owl->above = other_owl->above;
508 /* should owl stay above other_owl if other_owl was raised ? */
509 static bool shouldStayAbove(OtpWinList *owl, OtpWinList *other_owl)
512 && (other_owl->type == WinWin)
513 && isSmallTransientOf(owl->twm_win, other_owl->twm_win));
517 static void RaiseSmallTransientsOfAbove(OtpWinList *owl, OtpWinList *other_owl)
522 if((owl->type != WinWin) || other_owl == NULL) {
527 for(trans_owl = other_owl->below; trans_owl != NULL; trans_owl = tmp_owl) {
532 InsertOwlAbove(trans_owl, other_owl);
563 OtpWinList *other_owl;
581 other_owl = OwlRightBelow(priority + 1);
583 /* make sure other_owl is not one of the transients */
584 while((other_owl != NULL)
585 && shouldStayAbove(other_owl, owl)) {
586 PRI_CP(owl, other_owl);
588 other_owl = other_owl->below;
592 RaiseSmallTransientsOfAbove(owl, other_owl);
595 InsertOwlAbove(owl, other_owl);
626 OtpWinList *other_owl;
637 other_owl = OwlRightBelow(PRI(owl));
638 other_owl = (other_owl == NULL) ? Scr->bottomOwl : other_owl->above;
639 assert(PRI(other_owl) >= PRI(owl));
642 while((other_owl != NULL) && (PRI(other_owl) == PRI(owl))) {
643 OtpWinList *tmp_owl = other_owl->above;
644 if((other_owl->type == WinWin)
645 && isTransientOf(other_owl->twm_win, owl->twm_win)) {
647 other_owl->pri_aflags = owl->pri_aflags;
648 SetOwlPriority(other_owl, priority, where);
650 other_owl = tmp_owl;
693 static bool isHiddenBy(OtpWinList *owl, OtpWinList *other_owl)
696 return (isOnScreen(other_owl)
697 && isIntersectingWith(owl, other_owl));
702 OtpWinList *other_owl = owl->above;
704 while((other_owl != NULL) && (PRI(other_owl) == PRI(owl))) {
705 if(isHiddenBy(owl, other_owl)
706 && !shouldStayAbove(other_owl, owl)) {
708 RaiseSmallTransientsOfAbove(owl, other_owl);
709 InsertOwlAbove(owl, other_owl);
713 other_owl = other_owl->above;
720 OtpWinList *other_owl = owl->below;
722 while((other_owl != NULL) && (PRI(other_owl) == PRI(owl))) {
723 if(isHiddenBy(owl, other_owl)) {
725 InsertOwlAbove(owl, other_owl->below);
729 other_owl = other_owl->below;
736 OtpWinList *other_owl;
750 for(other_owl = owl->above;
751 (other_owl != NULL) && (PRI(other_owl) <= priority);
752 other_owl = other_owl->above) {
753 if(isHiddenBy(owl, other_owl)
754 && !shouldStayAbove(other_owl, owl)) {
993 OtpWinList *other_owl = other_win->otp;
1012 owl->pri_base = other_owl->pri_base;
1016 other_owl = other_owl->below;
1018 InsertOwlAbove(owl, other_owl);