uzor 1.1.6

Core UI engine — geometry, interaction, input state
1
2
3
4
5
6
7
8
9
10
11
12
13
use crate::input::core::coordinator::LayerId;
use crate::input::{InputCoordinator, Sense, WidgetKind};
use crate::types::{Rect, WidgetId};

pub fn register(
    coord: &mut InputCoordinator,
    id: impl Into<WidgetId>,
    rect: Rect,
    layer: &LayerId,
) {
    // Toast is hover-only (so user can pause auto-dismiss by hovering).
    coord.register_atomic(id, WidgetKind::Tooltip, rect, Sense::HOVER, layer);
}