mirror of
https://github.com/tmux/tmux.git
synced 2025-04-30 18:03:37 +00:00
Add a window-resized hook which is fired when the window is actually
resized which may be later than the client resize, GitHub issue 2995.
This commit is contained in:
parent
0027ee13a0
commit
818b2176ef
@ -1246,6 +1246,7 @@ const struct options_table_entry options_table[] = {
|
|||||||
OPTIONS_TABLE_HOOK("window-linked", ""),
|
OPTIONS_TABLE_HOOK("window-linked", ""),
|
||||||
OPTIONS_TABLE_WINDOW_HOOK("window-pane-changed", ""),
|
OPTIONS_TABLE_WINDOW_HOOK("window-pane-changed", ""),
|
||||||
OPTIONS_TABLE_WINDOW_HOOK("window-renamed", ""),
|
OPTIONS_TABLE_WINDOW_HOOK("window-renamed", ""),
|
||||||
|
OPTIONS_TABLE_WINDOW_HOOK("window-resized", ""),
|
||||||
OPTIONS_TABLE_HOOK("window-unlinked", ""),
|
OPTIONS_TABLE_HOOK("window-unlinked", ""),
|
||||||
|
|
||||||
{ .name = NULL }
|
{ .name = NULL }
|
||||||
|
1
resize.c
1
resize.c
@ -61,6 +61,7 @@ resize_window(struct window *w, u_int sx, u_int sy, int xpixel, int ypixel)
|
|||||||
tty_update_window_offset(w);
|
tty_update_window_offset(w);
|
||||||
server_redraw_window(w);
|
server_redraw_window(w);
|
||||||
notify_window("window-layout-changed", w);
|
notify_window("window-layout-changed", w);
|
||||||
|
notify_window("window-resized", w);
|
||||||
w->flags &= ~WINDOW_RESIZE;
|
w->flags &= ~WINDOW_RESIZE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user