From acd79e1505c06089e4fb9fb6c0c6e1d351ba9176 Mon Sep 17 00:00:00 2001 From: Drew DeVault Date: Tue, 26 Jun 2018 20:32:09 -0400 Subject: Implement pid->workspace tracking When you spawn a process with the exec command, sway now notes the workspace you had focused and the pid of the child process, then assigns that workspace to the child when its window appears. Some of this is carried over from sway 0.15, but with some major refactoring and centralization of state. --- include/sway/tree/workspace.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'include/sway/tree') diff --git a/include/sway/tree/workspace.h b/include/sway/tree/workspace.h index c72a4ac0..d84e4a02 100644 --- a/include/sway/tree/workspace.h +++ b/include/sway/tree/workspace.h @@ -42,4 +42,9 @@ void workspace_output_add_priority(struct sway_container *workspace, struct sway_container *workspace_output_get_highest_available( struct sway_container *ws, struct sway_container *exclude); + +struct sway_container *workspace_for_pid(pid_t pid); + +void workspace_record_pid(pid_t pid); + #endif -- cgit v1.2.3-54-g00ecf