mirror of
https://gitlab.com/gabmus/envision.git
synced 2025-04-20 03:24:52 +00:00
feat: switch to new profile on save
This commit is contained in:
parent
f614941e8f
commit
a71359e800
1 changed files with 3 additions and 2 deletions
|
@ -484,14 +484,15 @@ impl SimpleComponent for App {
|
|||
self.profiles.remove(index);
|
||||
}
|
||||
}
|
||||
self.profiles.push(prof);
|
||||
self.profiles.push(prof.clone());
|
||||
self.profiles.sort_unstable_by(|a, b| a.name.cmp(&b.name));
|
||||
self.config.set_profiles(&self.profiles);
|
||||
self.config.selected_profile_uuid = prof.uuid;
|
||||
self.config.save();
|
||||
self.main_view.sender().emit(MainViewMsg::UpdateProfiles(
|
||||
self.profiles.clone(),
|
||||
self.config.clone(),
|
||||
))
|
||||
));
|
||||
}
|
||||
Msg::RunSetCap => {
|
||||
if !check_dependency(pkexec_dep()) {
|
||||
|
|
Loading…
Add table
Reference in a new issue