use re_viewer_context::{ContainerId, Contents, ViewId};
use crate::ViewBlueprint;
#[derive(Clone, Debug)]
pub enum ViewportCommand {
SetTree(egui_tiles::Tree<ViewId>),
AddView {
view: ViewBlueprint,
parent_container: Option<ContainerId>,
position_in_parent: Option<usize>,
},
AddContainer {
container_kind: egui_tiles::ContainerKind,
parent_container: Option<ContainerId>,
},
SetContainerKind(ContainerId, egui_tiles::ContainerKind),
FocusTab(ViewId),
RemoveContents(Contents),
SimplifyContainer(ContainerId, egui_tiles::SimplificationOptions),
MakeAllChildrenSameSize(ContainerId),
MoveContents {
contents_to_move: Vec<Contents>,
target_container: ContainerId,
target_position_in_container: usize,
},
MoveContentsToNewContainer {
contents_to_move: Vec<Contents>,
new_container_kind: egui_tiles::ContainerKind,
target_container: ContainerId,
target_position_in_container: usize,
},
}