forked from 1b-agent/opencadstudio-upstream
fix(ribbon): preserve forced panel levels
This commit is contained in:
1 parent
af2f5f691b
commit
a64a7f7889
1 file changed
+5
-1
@@ -285,7 +285,11 @@ impl<'a> Widget<Message, Theme, Renderer> for CollapsePanels<'a> {
|
|||||||
heights.push([f.height, c.height, b.height, t.height]);
|
heights.push([f.height, c.height, b.height, t.height]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
let levels = decide_levels(self.mode, &widths, max_w);
|
let levels = if let Some(level) = self.mode.forced_level() {
|
||||||
|
vec![level; n]
|
||||||
|
} else {
|
||||||
|
decide_levels(self.mode, &widths, max_w)
|
||||||
|
};
|
||||||
|
|
||||||
// The row is "tight" once any panel has dropped to its small icon — the
|
// The row is "tight" once any panel has dropped to its small icon — the
|
||||||
// last, most cramped state. The tab bar hides its mode selector then.
|
// last, most cramped state. The tab bar hides its mode selector then.
|
||||||
|
|||||||
Reference in new issue
Block a user