Lines Matching refs:wl

325 	struct winlink		*wl;
341 RB_FOREACH(wl, winlinks, &s->windows) {
342 TAILQ_FOREACH(wp, &wl->window->panes, entry) {
583 struct winlink *wl, *wlfound;
592 if ((wl = winlink_find_by_index(&s->windows, idx)) != NULL)
593 return (wl);
598 RB_FOREACH(wl, winlinks, &s->windows) {
599 if (strcmp(name, wl->window->name) == 0) {
604 wlfound = wl;
612 RB_FOREACH(wl, winlinks, &s->windows) {
613 if (strncmp(name, wl->window->name, strlen(name)) == 0 ||
614 fnmatch(name, wl->window->name, 0) == 0) {
619 wlfound = wl;
635 struct winlink *wl;
639 if ((wl = cmd_lookup_window(s, name, ambiguous)) != NULL)
640 return (wl->idx);
677 struct winlink *wl;
682 wl = winlink_find_by_window(&s->windows, wp->window);
683 if (wl != NULL) {
685 *wlp = wl;
758 struct winlink *wl;
782 s = cmd_pane_session(ctx, wp, &wl);
785 return (wl);
813 wl = s->curw;
815 wl = TAILQ_FIRST(&s->lastw);
817 wl = cmd_find_window_offset(winptr, s, &ambiguous);
819 wl = cmd_lookup_window(s, winptr, &ambiguous);
820 if (wl == NULL)
825 return (wl);
833 if ((wl = TAILQ_FIRST(&s->lastw)) == NULL)
836 if ((wl = cmd_find_window_offset(arg, s, &ambiguous)) == NULL)
838 } else if ((wl = cmd_lookup_window(s, arg, &ambiguous)) == NULL)
844 return (wl);
879 struct winlink *wl;
885 wl = cmd_lookup_window(s, winptr, ambiguous);
888 wl = winlink_next_by_number(s->curw, s, offset);
890 wl = winlink_previous_by_number(s->curw, s, offset);
893 return (wl);
906 struct winlink *wl;
954 if ((wl = TAILQ_FIRST(&s->lastw)) == NULL)
956 idx = wl->idx;
973 if ((wl = TAILQ_FIRST(&s->lastw)) == NULL)
975 idx = wl->idx;
1062 struct winlink *wl;
1083 s = cmd_pane_session(ctx, *wpp, &wl);
1086 return (wl);
1097 wl = s->curw;
1098 else if ((wl = cmd_find_window(ctx, winptr, sp)) == NULL)
1104 *wpp = wl->window->active;
1106 *wpp = cmd_find_pane_offset(paneptr, wl);
1111 *wpp = window_pane_at_index(wl->window, idx);
1117 return (wl);
1121 if ((*wpp = window_find_string(wl->window, paneptr)) == NULL) {
1127 return (wl);
1147 if ((wl = cmd_find_window(ctx, arg, sp)) != NULL)
1148 *wpp = wl->window->active;
1149 return (wl);
1157 cmd_find_pane_offset(const char *paneptr, struct winlink *wl)
1159 struct window *w = wl->window;