feat(proto): SurfaceState + SetState command + State event + SurfaceView.state

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-06-09 22:10:54 +07:00
parent c2f8ef4214
commit 4bd4aa4a36
4 changed files with 67 additions and 0 deletions
+4
View File
@@ -2,6 +2,7 @@ use std::collections::HashMap;
use serde::{Deserialize, Serialize};
use crate::ids::{GroupId, SurfaceId, WorkspaceId};
use crate::layout::LayoutNode;
use crate::status::SurfaceState;
/// Everything needed to (re)create a panel's process.
#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
@@ -50,6 +51,9 @@ pub struct SurfaceView {
pub spec: SurfaceSpec,
/// true = has a live actor/PTY; false = stopped (in tree, no process).
pub running: bool,
/// Ephemeral agent-activity status (meaningful while running).
#[serde(default)]
pub state: SurfaceState,
}
/// Workspace view in `status` / `workspace_changed`: structure + per-surface state.