Simplify resize handle hover handling
This commit is contained in:
parent
8d91020238
commit
63a087f265
|
@ -69,11 +69,10 @@ impl View for ResizeHandle {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
WindowEvent::MouseMove(x, y) => {
|
WindowEvent::MouseMove(x, y) => {
|
||||||
if !intersects_triangle(cx.cache.get_bounds(cx.current), (x, y)) {
|
cx.current.set_hover(
|
||||||
cx.current.set_hover(cx, false);
|
cx,
|
||||||
} else {
|
intersects_triangle(cx.cache.get_bounds(cx.current), (x, y)),
|
||||||
cx.current.set_hover(cx, true);
|
);
|
||||||
}
|
|
||||||
|
|
||||||
if self.drag_active {
|
if self.drag_active {
|
||||||
// We need to convert our measurements into physical pixels relative to the
|
// We need to convert our measurements into physical pixels relative to the
|
||||||
|
|
Loading…
Reference in a new issue