Add portable mode with removable media detection and scanning

This commit is contained in:
lashman
2026-02-28 00:16:52 +02:00
parent f2abfba753
commit 2108b0f3d8
8 changed files with 138 additions and 1 deletions

View File

@@ -265,6 +265,17 @@ fn build_behavior_page(settings: &gio::Settings) -> adw::PreferencesPage {
});
automation_group.add(&auto_integrate_row);
let removable_row = adw::SwitchRow::builder()
.title(&i18n("Watch removable media"))
.subtitle(&i18n("Scan USB drives and other removable media for AppImages"))
.active(settings.boolean("watch-removable-media"))
.build();
let settings_rem = settings.clone();
removable_row.connect_active_notify(move |row| {
settings_rem.set_boolean("watch-removable-media", row.is_active()).ok();
});
automation_group.add(&removable_row);
page.add(&automation_group);
// Backup group