Use the available width for the Android device table, keeping individual peers expandable and their full details reachable in both orientations. Show network selection and settings side by side in landscape and reuse the VIP editor with a compact toolbar and width-aware backend columns. Retain the selected network, expanded peer, traffic unit and VIP draft across rotation. Show data-channel readiness consistently in the tray and on Android. Distinguish an establishing channel, a disabled data plane, an offline peer and a transport failure. Use an animated arc for visible waiting peers. Explain Phosphor controls on hover, focus and long press, and provide a masked-by-default reveal button in the shared secret field. Store the last confirmed exit network and endpoint in Android's private preferences. A Quick Settings tap disconnects that selection or restores the exact peer through the existing agent. First use opens the chooser. On a cold start, wait for an authenticated exit offer outside the command loop. Check the current selection again before changing the route. Only changed exit offers wake roster subscribers. Wire formats, software version and mesh identity storage remain compatible. On macOS arm64, cargo fmt and strict workspace Clippy passed. The locked workspace suite passed 598 tests with four opt-in tests ignored. Built the tray, the ARM64 debug APK and its test APK. All three instrumentation tests passed on an Android API 37 emulator. Opened the chooser from the actual Quick Settings tile, rotated the activity and inspected rendered device lists with ready, waiting, failed and offline peers. Physical phones and native Linux and Windows builds were not exercised.
32 lines
921 B
Rust
32 lines
921 B
Rust
//! Shared presentation for the egui clients.
|
|
pub mod about;
|
|
pub mod client;
|
|
pub mod devices;
|
|
mod exit;
|
|
pub mod format;
|
|
pub mod home;
|
|
pub mod listeners;
|
|
#[cfg(test)]
|
|
mod presentation_tests;
|
|
pub mod stats;
|
|
mod table;
|
|
pub mod vip;
|
|
mod vip_status;
|
|
pub mod widgets;
|
|
|
|
/// Install the Phosphor icons and bold network title face for both egui clients.
|
|
pub fn app_fonts() -> egui::FontDefinitions {
|
|
let mut fonts = egui::FontDefinitions::default();
|
|
egui_phosphor::add_to_fonts(&mut fonts, egui_phosphor::Variant::Regular);
|
|
let mut bold = fonts.families[&egui::FontFamily::Proportional].clone();
|
|
bold.insert(0, "Source Sans Pro Bold".into());
|
|
fonts.font_data.insert(
|
|
"Source Sans Pro Bold".into(),
|
|
egui::FontData::from_static(include_bytes!("../fonts/SourceSansPro-Bold.ttf")).into(),
|
|
);
|
|
fonts
|
|
.families
|
|
.insert(egui::FontFamily::Name("Bold".into()), bold);
|
|
fonts
|
|
}
|