Skip to main content

cbf_compositor/
lib.rs

1//! Scene-based browser surface compositor for CBF desktop applications.
2//!
3//! This crate separates backend ownership relationships from host composition
4//! relationships. A transient browsing context remains owned by a parent page,
5//! but may still be rendered in any compositor-managed window.
6
7mod backend;
8pub mod core;
9mod error;
10pub mod model;
11pub(crate) mod platform;
12pub(crate) mod state;
13mod window;
14
15use cbf::command::BrowserCommand;
16#[cfg(feature = "chrome")]
17use cbf_chrome::command::ChromeCommand;
18
19pub use error::CompositorError;
20pub use window::WindowHost;
21
22/// Backend command emitted by the compositor input bridge.
23#[derive(Debug, Clone)]
24pub enum BackendCommand {
25    /// Browser-generic command supported by every backend.
26    Browser(BrowserCommand),
27    /// Chrome-specific command used when compositor input must preserve
28    /// Chromium-native semantics.
29    #[cfg(feature = "chrome")]
30    Chrome(ChromeCommand),
31}