MCPcopy Create free account
hub / github.com/angular-rust/ux-components / topmost_at_point

Method topmost_at_point

src/elements/row.rs:168–177  ·  view source on GitHub ↗

Get the top most control under the given point, or None if there is none (or is the canvas itself)

(&self, x: f32, y: f32)

Source from the content-addressed store, hash-verified

166
167 /// Get the top most control under the given point, or None if there is none (or is the canvas itself)
168 pub fn topmost_at_point(&self, x: f32, y: f32) -> Option<&Box<dyn Element>> {
169 if let Some(control) = self.topmost_child_at_point(x, y) {
170 // control is not this canvas
171 if control.id() != self.id() {
172 return Some(control);
173 }
174 }
175
176 None
177 }
178
179 //Internal
180

Callers 1

get_focusableMethod · 0.45

Calls 2

idMethod · 0.45

Tested by

no test coverage detected