chore: remove trivial single-use helper functions
Rust / build (macos-latest, stable) (push) Canceled after 0s
Rust / build (ubuntu-latest, stable) (push) Canceled after 0s
Rust / build (windows-latest, stable) (push) Canceled after 0s

This commit is contained in:
2026-10-06 10:20:28 +07:00
parent a4df8e5731
commit cd72b25626
14 changed files with 58 additions and 130 deletions
+3 -6
View File
@@ -71,11 +71,6 @@ impl Render for DragPanelPreview {
}
}
/// The zoom affordance for the group's displayed panel, if it offers one.
fn zoom_control(group: &TabGroupContext, cx: &App) -> Option<PanelControl> {
panel_zoom_control(group.active_panel()?, cx)
}
/// The zoom affordance `panel` offers, if any.
///
/// The panel must offer a control and be zoomable, base refuses a zoom otherwise.
@@ -542,7 +537,9 @@ impl SignedTabGroupSkin {
impl TabGroupRenderer for SignedTabGroupSkin {
fn frame(&self, group: &TabGroupContext, _: &mut Window, cx: &mut App) -> Stateful<Div> {
let control = zoom_control(group, cx);
let control = group
.active_panel()
.and_then(|panel| panel_zoom_control(panel, cx));
// An emptied group draws nothing, so no bare tab bar is left behind.
if group.panels().is_empty() {
return div().id("tab-panel");