Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release 1.9.1 #208

Merged
merged 6 commits into from
Dec 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Fixed

- (supposedly) fixed background picture updating
- (supposedly) fixed wishes URL parsing
- Fixed game version parsing on updated game files layout

## [1.9.0] - 09.10.2024

### Removed
Expand Down
8 changes: 4 additions & 4 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ glib-build-tools = "0.20"

[dependencies.anime-launcher-sdk]
git = "https://github.com/an-anime-team/anime-launcher-sdk"
tag = "1.22.0"
tag = "1.25.0"
features = ["all", "star-rail", "star-rail-patch"]

# path = "../anime-launcher-sdk" # ! for dev purposes only
Expand Down
5 changes: 4 additions & 1 deletion src/background.rs
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ pub fn download_background() -> anyhow::Result<()> {
let info = get_background_info()?;

let mut download_image = true;
let mut replace_cached_image = false;

if crate::BACKGROUND_FILE.exists() {
let hash = Md5::digest(std::fs::read(crate::BACKGROUND_FILE.as_path())?);
Expand All @@ -84,6 +85,8 @@ pub fn download_background() -> anyhow::Result<()> {
if let Err(err) = downloader.download(crate::BACKGROUND_FILE.as_path(), |_, _| {}) {
anyhow::bail!(err);
}

replace_cached_image = true;
}

// Workaround for GTK weakness
Expand All @@ -98,7 +101,7 @@ pub fn download_background() -> anyhow::Result<()> {
// If it failed to re-code the file - just copy it
// Will happen with HSR because devs apparently named
// their background image ".webp" while it's JPEG
if !crate::PROCESSED_BACKGROUND_FILE.exists() {
if replace_cached_image || !crate::PROCESSED_BACKGROUND_FILE.exists() {
std::fs::copy(crate::BACKGROUND_FILE.as_path(), crate::PROCESSED_BACKGROUND_FILE.as_path())?;
}
}
Expand Down
6 changes: 4 additions & 2 deletions src/ui/about.rs
Original file line number Diff line number Diff line change
Expand Up @@ -100,10 +100,12 @@ impl SimpleComponent for AboutDialog {

set_release_notes_version: &APP_VERSION,
set_release_notes: &[
"<p>Removed</p>",
"<p>Fixed</p>",

"<ul>",
"<li>Removed Discord RPC support</li>",
"<li>(supposedly) fixed background picture updating</li>",
"<li>(supposedly) fixed wishes URL parsing</li>",
"<li>Fixed game version parsing on updated game files layout</li>",
"</ul>"
].join("\n"),

Expand Down
2 changes: 1 addition & 1 deletion src/ui/main/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -849,7 +849,7 @@ impl SimpleComponent for App {
let web_cache = String::from_utf8_lossy(&web_cache);

// https://webstatic-sea.[ho-yo-ver-se].com/[ge-nsh-in]/event/e20190909gacha-v2/index.html?......
if let Some(url) = web_cache.lines().rev().find(|line| line.contains("gacha-v3/index.html")) {
if let Some(url) = web_cache.lines().rev().find(|line| line.contains("gacha-v2/index.html")) {
let url_begin_pos = url.find("https://").unwrap();
let url_end_pos = url_begin_pos + url[url_begin_pos..].find("\0\0\0\0").unwrap();

Expand Down
Loading