mirror of
https://github.com/jayfunc/BetterLyrics.git
synced 2026-01-12 10:54:55 +08:00
fix lrc file supporting bug
This commit is contained in:
@@ -48,7 +48,7 @@
|
||||
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
|
||||
</Content>
|
||||
<Content Update="Assets\TestMusic.mp3">
|
||||
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
|
||||
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||
</Content>
|
||||
</ItemGroup>
|
||||
|
||||
|
||||
@@ -33,8 +33,8 @@ namespace BetterLyrics.WinUI3.Helper {
|
||||
|
||||
// Base Folders
|
||||
private static string LocalFolder => ApplicationData.Current.LocalFolder.Path;
|
||||
private static string CacheFolder => ApplicationData.Current.LocalCacheFolder.Path;
|
||||
public static string AssetsFolder => Path.Combine(AppContext.BaseDirectory, "Assets");
|
||||
public static string CacheFolder => ApplicationData.Current.LocalCacheFolder.Path;
|
||||
public static string AssetsFolder => Path.Combine(Package.Current.InstalledPath, "Assets");
|
||||
|
||||
// Data Files
|
||||
private static string DatabaseFileName => "database.db";
|
||||
|
||||
@@ -35,8 +35,8 @@ namespace BetterLyrics.WinUI3.Services.Database {
|
||||
var track = new Track(file);
|
||||
_connection.Insert(new MetadataIndex {
|
||||
Path = file,
|
||||
Title = track.Title,
|
||||
Artist = track.Artist,
|
||||
Title = track.Title == "" ? file : track.Title,
|
||||
Artist = track.Artist == "" ? file : track.Artist,
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -46,7 +46,7 @@ namespace BetterLyrics.WinUI3.Services.Database {
|
||||
|
||||
public Track? GetMusicMetadata(string? title, string? artist) {
|
||||
var founds = _connection.Table<MetadataIndex>()
|
||||
.Where(m => m.Title == title && m.Artist == artist).ToList();
|
||||
.Where(m => m.Title.Contains(title) && m.Artist.Contains(artist)).ToList();
|
||||
if (founds == null || founds.Count == 0) {
|
||||
return null;
|
||||
} else {
|
||||
|
||||
@@ -5,6 +5,7 @@ using CommunityToolkit.Mvvm.ComponentModel;
|
||||
using CommunityToolkit.Mvvm.Input;
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Windows.ApplicationModel.Core;
|
||||
|
||||
@@ -35,10 +35,12 @@ We provide more than one setting item to better align with your preference
|
||||
|
||||
- Language (English, Simplified Chinese, Traditional Chinese)
|
||||
|
||||
## Demonstration video
|
||||
## Live demonstration
|
||||
|
||||

|
||||
|
||||

|
||||
|
||||
Or watch our introduction video「BetterLyrics 阶段性开发成果展示」(uploaded on 31 May 2025) on Bilibili below (click the cover image to watch):
|
||||
|
||||
[](https://b23.tv/QjKkYmL)
|
||||
|
||||
BIN
Screenshots/BetterLyrics.WinUI3_igDdnc4rzW.gif
Normal file
BIN
Screenshots/BetterLyrics.WinUI3_igDdnc4rzW.gif
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 44 MiB |
Reference in New Issue
Block a user