A given session can always be told to renumber its winlinks when a window is
destroyed in that session.
---
trunk/options-table.c | 5 +++++
trunk/server-fn.c | 5 +++++
2 files changed, 10 insertions(+)
diff --git a/trunk/options-table.c b/trunk/options-table.c
index 1eb50e4..81fce32 100644
--- a/trunk/options-table.c
+++ b/trunk/options-table.c
@@ -90,6 +90,11 @@ const struct options_table_entry server_options_table[] = {
/* Session options. */
const struct options_table_entry session_options_table[] = {
+ { .name = "automatic-renumber-windows",
+ .type = OPTIONS_TABLE_FLAG,
+ .default_num = 0
+ },
+
{ .name = "base-index",
.type = OPTIONS_TABLE_NUMBER,
.minimum = 0,
diff --git a/trunk/server-fn.c b/trunk/server-fn.c
index 4136bbb..d0c900e 100644
--- a/trunk/server-fn.c
+++ b/trunk/server-fn.c
@@ -263,6 +263,11 @@ server_kill_window(struct window *w)
} else
server_redraw_session_group(s);
}
+
+ /* Renumber all windows if we've been asked to. */
+ if (options_get_number(&s->options,
+ "automatic-renumber-windows"))
+ window_renumber_windows(s);
}
}
--
1.7.10
------------------------------------------------------------------------------
For Developers, A Lot Can Happen In A Second.
Boundary is the first to Know...and Tell You.
Monitor Your Applications in Ultra-Fine Resolution. Try it FREE!
http://p.sf.net/sfu/Boundary-d2dvs2
_______________________________________________
tmux-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tmux-users