fix(launcher): tie device testing height to staging

This commit is contained in:
Brad Stein 2026-04-21 14:41:47 -03:00
parent 21c3ecfac6
commit c17777b831
4 changed files with 16 additions and 18 deletions

View File

@ -4,7 +4,7 @@ path = "src/main.rs"
[package]
name = "lesavka_client"
version = "0.11.38"
version = "0.11.39"
edition = "2024"
[dependencies]

View File

@ -82,6 +82,7 @@ pub struct LauncherWidgets {
pub diagnostics_popout_button: gtk::Button,
pub console_copy_button: gtk::Button,
pub console_popout_button: gtk::Button,
pub _device_body_height_group: gtk::SizeGroup,
}
#[derive(Clone)]
@ -113,8 +114,6 @@ const LAUNCHER_DEFAULT_HEIGHT: i32 = 860;
const OPERATIONS_RAIL_WIDTH: i32 = 288;
const CAMERA_PREVIEW_VIEWPORT_HEIGHT: i32 = 72;
const CAMERA_PREVIEW_VIEWPORT_WIDTH: i32 = 128;
const DEVICE_PANEL_HEIGHT: i32 = 204;
const DEVICE_TEST_GROUP_HEIGHT: i32 = 156;
const SIDE_LOG_HEIGHT: i32 = 104;
pub fn build_launcher_view(
@ -204,7 +203,6 @@ pub fn build_launcher_view(
staging_row.set_vexpand(false);
staging_row.set_valign(gtk::Align::Start);
staging_row.set_homogeneous(true);
staging_row.set_size_request(-1, DEVICE_PANEL_HEIGHT);
workspace.append(&staging_row);
let device_refresh_button = gtk::Button::with_label("Refresh Devices");
@ -217,7 +215,6 @@ pub fn build_launcher_view(
devices_panel.set_hexpand(true);
devices_panel.set_vexpand(false);
devices_panel.set_valign(gtk::Align::Fill);
devices_panel.set_size_request(-1, DEVICE_PANEL_HEIGHT);
devices_body.set_spacing(8);
let control_group = build_subgroup("Control Inputs");
@ -328,14 +325,15 @@ pub fn build_launcher_view(
preview_panel.set_hexpand(true);
preview_panel.set_vexpand(false);
preview_panel.set_valign(gtk::Align::Fill);
preview_panel.set_size_request(-1, DEVICE_PANEL_HEIGHT);
preview_body.set_vexpand(false);
preview_body.set_spacing(8);
let testing_row = gtk::Box::new(gtk::Orientation::Horizontal, 8);
testing_row.set_hexpand(true);
testing_row.set_vexpand(false);
testing_row.set_valign(gtk::Align::Start);
testing_row.set_size_request(-1, DEVICE_TEST_GROUP_HEIGHT);
testing_row.set_vexpand(true);
testing_row.set_valign(gtk::Align::Fill);
let device_body_height_group = gtk::SizeGroup::new(gtk::SizeGroupMode::Vertical);
device_body_height_group.add_widget(&devices_body);
device_body_height_group.add_widget(&testing_row);
let camera_preview = gtk::Picture::new();
camera_preview.set_can_shrink(false);
camera_preview.set_hexpand(false);
@ -371,17 +369,16 @@ pub fn build_launcher_view(
camera_preview_shell.append(&camera_preview_frame);
let webcam_group = build_subgroup("Webcam Preview");
webcam_group.set_hexpand(true);
webcam_group.set_vexpand(false);
webcam_group.set_valign(gtk::Align::Start);
webcam_group.set_size_request(-1, DEVICE_TEST_GROUP_HEIGHT);
webcam_group.set_vexpand(true);
webcam_group.set_valign(gtk::Align::Fill);
webcam_group.append(&camera_preview_shell);
testing_row.append(&webcam_group);
let playback_group = build_subgroup("Mic Playback");
playback_group.set_hexpand(false);
playback_group.set_vexpand(false);
playback_group.set_valign(gtk::Align::Start);
playback_group.set_size_request(72, DEVICE_TEST_GROUP_HEIGHT);
playback_group.set_vexpand(true);
playback_group.set_valign(gtk::Align::Fill);
playback_group.set_size_request(72, -1);
let playback_body = gtk::Box::new(gtk::Orientation::Vertical, 6);
playback_body.set_halign(gtk::Align::Center);
playback_body.set_vexpand(true);
@ -721,6 +718,7 @@ pub fn build_launcher_view(
diagnostics_popout_button: diagnostics_popout_button.clone(),
console_copy_button: console_copy_button.clone(),
console_popout_button: console_popout_button.clone(),
_device_body_height_group: device_body_height_group,
};
let popouts = Rc::new(RefCell::new([None, None]));
let diagnostics_popout = Rc::new(RefCell::new(None));
@ -853,7 +851,7 @@ pub fn install_css(window: &gtk::ApplicationWindow) {
background: rgba(255, 255, 255, 0.08);
}
progressbar.audio-check-meter.vertical trough {
min-height: 72px;
min-height: 116px;
}
progressbar.audio-check-meter progress {
border-radius: 999px;

View File

@ -1,6 +1,6 @@
[package]
name = "lesavka_common"
version = "0.11.38"
version = "0.11.39"
edition = "2024"
build = "build.rs"

View File

@ -10,7 +10,7 @@ bench = false
[package]
name = "lesavka_server"
version = "0.11.38"
version = "0.11.39"
edition = "2024"
autobins = false