mirror of
https://github.com/tmux/tmux.git
synced 2026-07-22 08:51:17 +00:00
Merge remote-tracking branch 'refs/remotes/tmux-openbsd/master'
* refs/remotes/tmux-openbsd/master: Add pane-activity event.
This commit is contained in:
6
input.c
6
input.c
@@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: input.c,v 1.267 2026/07/13 13:01:14 nicm Exp $ */
|
||||
/* $OpenBSD: input.c,v 1.268 2026/07/13 15:03:03 nicm Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2007 Nicholas Marriott <nicholas.marriott@gmail.com>
|
||||
@@ -1051,6 +1051,10 @@ input_parse_buffer(struct window_pane *wp, const u_char *buf, size_t len)
|
||||
return;
|
||||
|
||||
window_update_activity(wp->window);
|
||||
if (~wp->flags & PANE_ACTIVITY) {
|
||||
wp->flags |= PANE_ACTIVITY;
|
||||
events_fire_pane("pane-activity", wp);
|
||||
}
|
||||
wp->flags |= PANE_CHANGED;
|
||||
|
||||
/* Flag new input while in a mode. */
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: options-table.c,v 1.234 2026/07/13 13:01:14 nicm Exp $ */
|
||||
/* $OpenBSD: options-table.c,v 1.235 2026/07/13 15:03:03 nicm Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2011 Nicholas Marriott <nicholas.marriott@gmail.com>
|
||||
@@ -1935,6 +1935,7 @@ const struct options_table_entry options_table[] = {
|
||||
OPTIONS_TABLE_HOOK("client-dark-theme", ""),
|
||||
OPTIONS_TABLE_HOOK("command-error", ""),
|
||||
OPTIONS_TABLE_HOOK("marked-pane-changed", ""),
|
||||
OPTIONS_TABLE_PANE_HOOK("pane-activity", ""),
|
||||
OPTIONS_TABLE_PANE_HOOK("pane-bell", ""),
|
||||
OPTIONS_TABLE_PANE_HOOK("pane-command-finished", ""),
|
||||
OPTIONS_TABLE_PANE_HOOK("pane-command-started", ""),
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: server-client.c,v 1.487 2026/07/13 13:01:14 nicm Exp $ */
|
||||
/* $OpenBSD: server-client.c,v 1.488 2026/07/13 15:03:03 nicm Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2009 Nicholas Marriott <nicholas.marriott@gmail.com>
|
||||
@@ -1808,7 +1808,8 @@ server_client_loop(void)
|
||||
server_client_check_pane_resize(wp);
|
||||
server_client_check_pane_buffer(wp);
|
||||
}
|
||||
wp->flags &= ~(PANE_REDRAW|PANE_REDRAWSCROLLBAR);
|
||||
wp->flags &= ~(PANE_REDRAW|PANE_REDRAWSCROLLBAR|
|
||||
PANE_ACTIVITY);
|
||||
}
|
||||
check_window_name(w);
|
||||
}
|
||||
|
||||
11
tmux.1
11
tmux.1
@@ -1,4 +1,4 @@
|
||||
.\" $OpenBSD: tmux.1,v 1.1134 2026/07/13 13:01:14 nicm Exp $
|
||||
.\" $OpenBSD: tmux.1,v 1.1135 2026/07/13 15:03:03 nicm Exp $
|
||||
.\"
|
||||
.\" Copyright (c) 2007 Nicholas Marriott <nicholas.marriott@gmail.com>
|
||||
.\"
|
||||
@@ -6380,17 +6380,12 @@ Run when a client switches to a dark theme.
|
||||
Run when a command fails.
|
||||
.It marked\-pane\-changed
|
||||
Run when the marked pane is set or cleared.
|
||||
.It pane\-activity
|
||||
Run when there is new output in a pane.
|
||||
.It pane\-bell
|
||||
Run when a pane receives a bell.
|
||||
.It pane\-command\-finished
|
||||
Run when an OSC 133 command finishes in a pane.
|
||||
The event payload includes
|
||||
.Ql hook_command_start_time ,
|
||||
.Ql hook_command_end_time ,
|
||||
.Ql hook_command_duration
|
||||
and
|
||||
.Ql hook_command_status
|
||||
if present.
|
||||
.It pane\-command\-started
|
||||
Run when an OSC 133 command starts in a pane.
|
||||
.It pane\-created
|
||||
|
||||
3
tmux.h
3
tmux.h
@@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: tmux.h,v 1.1399 2026/07/13 13:01:14 nicm Exp $ */
|
||||
/* $OpenBSD: tmux.h,v 1.1400 2026/07/13 15:03:03 nicm Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2007 Nicholas Marriott <nicholas.marriott@gmail.com>
|
||||
@@ -1302,6 +1302,7 @@ struct window_pane {
|
||||
#define PANE_REDRAWSCROLLBAR 0x8000
|
||||
#define PANE_DESTROYED 0x10000
|
||||
#define PANE_CMDRUNNING 0x20000
|
||||
#define PANE_ACTIVITY 0x40000
|
||||
|
||||
bitstr_t *sync_dirty;
|
||||
u_int sync_dirty_size;
|
||||
|
||||
Reference in New Issue
Block a user