Render picked pane last
This commit is contained in:
parent
dca99f35e9
commit
fb036529a2
1 changed files with 6 additions and 1 deletions
|
|
@ -757,7 +757,12 @@ pub fn draw<Renderer, T>(
|
||||||
cursor_position
|
cursor_position
|
||||||
};
|
};
|
||||||
|
|
||||||
for ((id, pane), layout) in elements.zip(layout.children()) {
|
// Render picked pane last
|
||||||
|
let mut elements = elements.zip(layout.children()).collect::<Vec<_>>();
|
||||||
|
elements
|
||||||
|
.sort_by_key(|((id, _), _)| picked_pane.map(|(id, _)| id) == Some(*id));
|
||||||
|
|
||||||
|
for ((id, pane), layout) in elements {
|
||||||
match picked_pane {
|
match picked_pane {
|
||||||
Some((dragging, origin)) if id == dragging => {
|
Some((dragging, origin)) if id == dragging => {
|
||||||
let bounds = layout.bounds();
|
let bounds = layout.bounds();
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue