From a002e4d738535e6ca779c71231f7b84864b9a8d0 Mon Sep 17 00:00:00 2001 From: Silas Bartha Date: Tue, 4 Jun 2024 15:00:16 -0400 Subject: Refactored + Renamed + Added Docs --- src/widgets/components.rs | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 src/widgets/components.rs (limited to 'src/widgets/components.rs') diff --git a/src/widgets/components.rs b/src/widgets/components.rs new file mode 100644 index 0000000..b6ff925 --- /dev/null +++ b/src/widgets/components.rs @@ -0,0 +1,14 @@ +use bevy::prelude::*; + +use super::TerminalWidget; + +/// Component representing a terminal widget. +#[derive(Component)] +pub struct Widget { + /// The widget instance itself, containing rendering and input logic + pub widget: Box, + /// Depth to render widget at + pub depth: u32, + /// Whether this widget is currently enabled or should be hidden + pub enabled: bool, +} -- cgit v1.2.3