mirror of
https://github.com/an-anime-team/an-anime-game-launcher.git
synced 2024-11-21 20:36:01 +03:00
feat(ui): small ui fixes
This commit is contained in:
parent
017f030922
commit
71d454d87c
3 changed files with 5 additions and 8 deletions
0
.gitmodules
vendored
0
.gitmodules
vendored
|
@ -387,7 +387,7 @@ impl SimpleComponent for App {
|
|||
},
|
||||
|
||||
#[watch]
|
||||
set_sensitive: match model.state.as_ref() {
|
||||
set_sensitive: !model.disabled_buttons && match &model.state {
|
||||
Some(LauncherState::GameOutdated { .. }) |
|
||||
Some(LauncherState::VoiceOutdated(_)) => false,
|
||||
|
||||
|
@ -407,7 +407,7 @@ impl SimpleComponent for App {
|
|||
},
|
||||
|
||||
#[watch]
|
||||
set_css_classes: match model.state.as_ref() {
|
||||
set_css_classes: match &model.state {
|
||||
Some(LauncherState::GameOutdated { .. }) |
|
||||
Some(LauncherState::VoiceOutdated(_)) => &["warning"],
|
||||
|
||||
|
@ -427,7 +427,7 @@ impl SimpleComponent for App {
|
|||
},
|
||||
|
||||
#[watch]
|
||||
set_tooltip_text: Some(&match model.state.as_ref() {
|
||||
set_tooltip_text: Some(&match &model.state {
|
||||
Some(LauncherState::GameOutdated { .. }) |
|
||||
Some(LauncherState::VoiceOutdated(_)) => tr("main-window--version-outdated-tooltip"),
|
||||
|
||||
|
@ -444,9 +444,6 @@ impl SimpleComponent for App {
|
|||
_ => String::new()
|
||||
}),
|
||||
|
||||
#[watch]
|
||||
set_sensitive: !model.disabled_buttons,
|
||||
|
||||
set_hexpand: false,
|
||||
set_width_request: 200,
|
||||
|
||||
|
@ -668,7 +665,7 @@ impl SimpleComponent for App {
|
|||
sender.input(AppMsg::SetLoadingStatus(Some(Some(tr("downloading-background-picture")))));
|
||||
|
||||
if let Err(err) = crate::background::download_background() {
|
||||
tracing::error!("Failed to download background picture");
|
||||
tracing::error!("Failed to download background picture: {err}");
|
||||
|
||||
sender.input(AppMsg::Toast {
|
||||
title: tr("background-downloading-failed"),
|
||||
|
|
|
@ -346,7 +346,7 @@ impl SimpleAsyncComponent for GeneralApp {
|
|||
VersionDiff::NotInstalled { .. } => &[]
|
||||
}
|
||||
|
||||
None => &["success"]
|
||||
None => &[]
|
||||
},
|
||||
|
||||
#[watch]
|
||||
|
|
Loading…
Reference in a new issue