mirror of
https://github.com/an-anime-team/an-anime-game-launcher.git
synced 2025-02-16 15:22:01 +03:00
feat(ui): added signal blockings to recommended only switches
This commit is contained in:
parent
c477f21abd
commit
95548fc394
1 changed files with 13 additions and 4 deletions
|
@ -463,11 +463,15 @@ impl SimpleAsyncComponent for GeneralApp {
|
|||
|
||||
add_suffix = >k::Switch {
|
||||
set_valign: gtk::Align::Center,
|
||||
|
||||
#[block_signal(wine_recommended_notify)]
|
||||
set_state: true,
|
||||
|
||||
connect_state_notify[sender] => move |switch| {
|
||||
sender.input(GeneralAppMsg::WineRecommendedOnly(switch.state()));
|
||||
}
|
||||
if is_ready() {
|
||||
sender.input(GeneralAppMsg::WineRecommendedOnly(switch.state()));
|
||||
}
|
||||
} @wine_recommended_notify
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@ -513,11 +517,15 @@ impl SimpleAsyncComponent for GeneralApp {
|
|||
|
||||
add_suffix = >k::Switch {
|
||||
set_valign: gtk::Align::Center,
|
||||
|
||||
#[block_signal(dxvk_recommended_notify)]
|
||||
set_state: true,
|
||||
|
||||
connect_state_notify[sender] => move |switch| {
|
||||
sender.input(GeneralAppMsg::DxvkRecommendedOnly(switch.state()));
|
||||
}
|
||||
if is_ready() {
|
||||
sender.input(GeneralAppMsg::DxvkRecommendedOnly(switch.state()));
|
||||
}
|
||||
} @dxvk_recommended_notify
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@ -544,6 +552,7 @@ impl SimpleAsyncComponent for GeneralApp {
|
|||
download_folder: CONFIG.game.wine.builds.clone(),
|
||||
groups: wine::get_groups(&CONFIG.components.path).unwrap_or_default()
|
||||
.into_iter()
|
||||
.filter(|group| !["wine-staging", "wine-staging-tkg"].contains(&group.name.as_str()))
|
||||
.map(|mut group| {
|
||||
group.versions = group.versions.into_iter().take(12).collect();
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue