Commit [20636d] Maximize Restore History

Add a command queue to standardize and simplify commands that call other

commands and allow a command to block execution of subsequent
commands. This allows run-shell and if-shell to be synchronous which has
been much requested.

Each client has a default command queue and commands are consumed one at
a time from it. A command may suspend execution from the queue by
returning CMD_RETURN_WAIT and then resume it by calling cmd_continue() -
for example run-shell does this from the callback that is fired after
the job is freed.

When the command queue becomes empty, command clients are automatically
exited (unless attaching). A callback is also fired - this is used for
nested commands in, for example, if-shell which can block execution of
the client's cmdq until a new cmdq becomes empty.

Also merge all the old error/info/print functions together and lose the
old curclient/cmdclient distinction - a cmdq is bound to one client (or
none if in the configuration file), this is a command client if
c->session is NULL otherwise an attached client.

Nicholas Marriott Nicholas Marriott 2013-03-24

1 2 3 4 > >> (Page 1 of 4)
changed Makefile
changed cfg.c
changed client.c
changed cmd-attach-session.c
changed cmd-bind-key.c
changed cmd-break-pane.c
changed cmd-capture-pane.c
changed cmd-choose-buffer.c
changed cmd-choose-client.c
changed cmd-choose-list.c
changed cmd-choose-tree.c
changed cmd-clear-history.c
changed cmd-clock-mode.c
changed cmd-command-prompt.c
changed cmd-confirm-before.c
changed cmd-copy-mode.c
changed cmd-delete-buffer.c
changed cmd-detach-client.c
changed cmd-display-message.c
changed cmd-display-panes.c
changed cmd-find-window.c
changed cmd-has-session.c
changed cmd-if-shell.c
changed cmd-join-pane.c
changed cmd-kill-pane.c
Makefile Diff Switch to side-by-side view
Loading...
cfg.c Diff Switch to side-by-side view
Loading...
client.c Diff Switch to side-by-side view
Loading...
cmd-attach-session.c Diff Switch to side-by-side view
Loading...
cmd-bind-key.c Diff Switch to side-by-side view
Loading...
cmd-break-pane.c Diff Switch to side-by-side view
Loading...
cmd-capture-pane.c Diff Switch to side-by-side view
Loading...
cmd-choose-buffer.c Diff Switch to side-by-side view
Loading...
cmd-choose-client.c Diff Switch to side-by-side view
Loading...
cmd-choose-list.c Diff Switch to side-by-side view
Loading...
cmd-choose-tree.c Diff Switch to side-by-side view
Loading...
cmd-clear-history.c Diff Switch to side-by-side view
Loading...
cmd-clock-mode.c Diff Switch to side-by-side view
Loading...
cmd-command-prompt.c Diff Switch to side-by-side view
Loading...
cmd-confirm-before.c Diff Switch to side-by-side view
Loading...
cmd-copy-mode.c Diff Switch to side-by-side view
Loading...
cmd-delete-buffer.c Diff Switch to side-by-side view
Loading...
cmd-detach-client.c Diff Switch to side-by-side view
Loading...
cmd-display-message.c Diff Switch to side-by-side view
Loading...
cmd-display-panes.c Diff Switch to side-by-side view
Loading...
cmd-find-window.c Diff Switch to side-by-side view
Loading...
cmd-has-session.c Diff Switch to side-by-side view
Loading...
cmd-if-shell.c Diff Switch to side-by-side view
Loading...
cmd-join-pane.c Diff Switch to side-by-side view
Loading...
cmd-kill-pane.c Diff Switch to side-by-side view
Loading...
1 2 3 4 > >> (Page 1 of 4)