Skip to content

Commit

Permalink
#### v1.1.0.11
Browse files Browse the repository at this point in the history
- Fix bug of download artwork
- Show errlabel when login err
  • Loading branch information
yaronzz committed Jan 30, 2020
1 parent 76e374d commit 2f565d8
Show file tree
Hide file tree
Showing 9 changed files with 68 additions and 50 deletions.
19 changes: 5 additions & 14 deletions TIDALDL-UI/TIDALDL-UI.sln
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 15
VisualStudioVersion = 15.0.26228.4
# Visual Studio Version 16
VisualStudioVersion = 16.0.29709.97
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TIDALDL-UI", "TIDALDL-UI\TIDALDL-UI.csproj", "{87F39F78-056F-4747-A835-12BA03FE575A}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AIGS", "..\..\..\AIGS.git\trunk\AIGS.csproj", "{E0F1B398-B4D4-4536-9135-BE2EB077BBB2}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
CD_ROM|Any CPU = CD_ROM|Any CPU
Expand All @@ -26,18 +24,11 @@ Global
{87F39F78-056F-4747-A835-12BA03FE575A}.Release|Any CPU.Build.0 = Release|Any CPU
{87F39F78-056F-4747-A835-12BA03FE575A}.SingleImage|Any CPU.ActiveCfg = Release|Any CPU
{87F39F78-056F-4747-A835-12BA03FE575A}.SingleImage|Any CPU.Build.0 = Release|Any CPU
{E0F1B398-B4D4-4536-9135-BE2EB077BBB2}.CD_ROM|Any CPU.ActiveCfg = Release|Any CPU
{E0F1B398-B4D4-4536-9135-BE2EB077BBB2}.CD_ROM|Any CPU.Build.0 = Release|Any CPU
{E0F1B398-B4D4-4536-9135-BE2EB077BBB2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{E0F1B398-B4D4-4536-9135-BE2EB077BBB2}.Debug|Any CPU.Build.0 = Debug|Any CPU
{E0F1B398-B4D4-4536-9135-BE2EB077BBB2}.DVD-5|Any CPU.ActiveCfg = Debug|Any CPU
{E0F1B398-B4D4-4536-9135-BE2EB077BBB2}.DVD-5|Any CPU.Build.0 = Debug|Any CPU
{E0F1B398-B4D4-4536-9135-BE2EB077BBB2}.Release|Any CPU.ActiveCfg = Release|Any CPU
{E0F1B398-B4D4-4536-9135-BE2EB077BBB2}.Release|Any CPU.Build.0 = Release|Any CPU
{E0F1B398-B4D4-4536-9135-BE2EB077BBB2}.SingleImage|Any CPU.ActiveCfg = Release|Any CPU
{E0F1B398-B4D4-4536-9135-BE2EB077BBB2}.SingleImage|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {EE9828BC-5446-4422-83D6-9103517072A3}
EndGlobalSection
EndGlobal
2 changes: 1 addition & 1 deletion TIDALDL-UI/TIDALDL-UI/App.config
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="ICSharpCode.SharpZipLib" publicKeyToken="1b03e6acf1164f73" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-1.1.0.145" newVersion="1.1.0.145" />
<bindingRedirect oldVersion="0.0.0.0-1.2.0.246" newVersion="1.2.0.246" />
</dependentAssembly>
</assemblyBinding>
</runtime>
Expand Down
2 changes: 1 addition & 1 deletion TIDALDL-UI/TIDALDL-UI/Else/DownloadItem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ public void DownloadTrack()
if (!TidalTool.ConvertMp4ToM4a(FilePath, out sNewName))
{
Errlabel = "Convert mp4 to m4a failed!";
ErrlabelHeight = 15;
goto ERR_RETURN;
}
else
FilePath = sNewName;
Expand Down
2 changes: 1 addition & 1 deletion TIDALDL-UI/TIDALDL-UI/Pages/LoginViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ public async void Confirm()
TidalTool.PROXY = ProxyEnable ? new HttpHelper.ProxyInfo(ProxyHost, ProxyPort, ProxyUser, ProxyPwd) : null;
bool bRet = await Task.Run(() => { return TidalTool.login(Username, Password);});
if (!bRet)
Errlabel = "Login Err!";
Errlabel = "Login Err! " + TidalTool.loginErrlabel;
else
{
//DEBUG
Expand Down
4 changes: 2 additions & 2 deletions TIDALDL-UI/TIDALDL-UI/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,5 +51,5 @@
// 可以指定所有值,也可以使用以下所示的 "*" 预置版本号和修订号
// 方法是按如下所示使用“*”: :
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.1.0.10")]
[assembly: AssemblyFileVersion("1.1.0.10")]
[assembly: AssemblyVersion("1.1.0.11")]
[assembly: AssemblyFileVersion("1.1.0.11")]
48 changes: 29 additions & 19 deletions TIDALDL-UI/TIDALDL-UI/TIDALDL-UI.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="..\packages\PropertyChanged.Fody.2.6.0\build\PropertyChanged.Fody.props" Condition="Exists('..\packages\PropertyChanged.Fody.2.6.0\build\PropertyChanged.Fody.props')" />
<Import Project="..\packages\Costura.Fody.3.3.0\build\Costura.Fody.props" Condition="Exists('..\packages\Costura.Fody.3.3.0\build\Costura.Fody.props')" />
<Import Project="..\packages\PropertyChanged.Fody.3.2.4\build\PropertyChanged.Fody.props" Condition="Exists('..\packages\PropertyChanged.Fody.3.2.4\build\PropertyChanged.Fody.props')" />
<Import Project="..\packages\Costura.Fody.4.1.0\build\Costura.Fody.props" Condition="Exists('..\packages\Costura.Fody.4.1.0\build\Costura.Fody.props')" />
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
Expand Down Expand Up @@ -76,17 +76,17 @@
<Reference Include="AIGS">
<HintPath>..\packages\AIGS\AIGS.dll</HintPath>
</Reference>
<Reference Include="Costura, Version=3.3.0.0, Culture=neutral, PublicKeyToken=9919ef960d84173d, processorArchitecture=MSIL">
<HintPath>..\packages\Costura.Fody.3.3.0\lib\net40\Costura.dll</HintPath>
<Reference Include="Costura, Version=4.1.0.0, Culture=neutral, PublicKeyToken=9919ef960d84173d, processorArchitecture=MSIL">
<HintPath>..\packages\Costura.Fody.4.1.0\lib\net40\Costura.dll</HintPath>
</Reference>
<Reference Include="ICSharpCode.SharpZipLib, Version=1.1.0.145, Culture=neutral, PublicKeyToken=1b03e6acf1164f73, processorArchitecture=MSIL">
<HintPath>..\packages\SharpZipLib.1.1.0\lib\net45\ICSharpCode.SharpZipLib.dll</HintPath>
<Reference Include="ICSharpCode.SharpZipLib, Version=1.2.0.246, Culture=neutral, PublicKeyToken=1b03e6acf1164f73, processorArchitecture=MSIL">
<HintPath>..\packages\SharpZipLib.1.2.0\lib\net45\ICSharpCode.SharpZipLib.dll</HintPath>
</Reference>
<Reference Include="MaterialDesignColors, Version=1.1.3.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\MaterialDesignColors.1.1.3\lib\net45\MaterialDesignColors.dll</HintPath>
<Reference Include="MaterialDesignColors, Version=1.2.2.920, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\MaterialDesignColors.1.2.2\lib\net45\MaterialDesignColors.dll</HintPath>
</Reference>
<Reference Include="MaterialDesignThemes.Wpf, Version=2.5.1.1345, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\MaterialDesignThemes.2.5.1\lib\net45\MaterialDesignThemes.Wpf.dll</HintPath>
<Reference Include="MaterialDesignThemes.Wpf, Version=3.0.1.920, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\MaterialDesignThemes.3.0.1\lib\net45\MaterialDesignThemes.Wpf.dll</HintPath>
</Reference>
<Reference Include="Microsoft.VisualBasic" />
<Reference Include="Newtonsoft.Json, Version=4.5.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
Expand All @@ -99,11 +99,11 @@
<Reference Include="policy.2.0.taglib-sharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=db62eba44689b5b0, processorArchitecture=MSIL">
<HintPath>..\packages\taglib.2.1.0.0\lib\policy.2.0.taglib-sharp.dll</HintPath>
</Reference>
<Reference Include="PropertyChanged, Version=2.6.0.0, Culture=neutral, PublicKeyToken=ee3ee20bcf148ddd, processorArchitecture=MSIL">
<HintPath>..\packages\PropertyChanged.Fody.2.6.0\lib\net452\PropertyChanged.dll</HintPath>
<Reference Include="PropertyChanged, Version=3.2.4.0, Culture=neutral, PublicKeyToken=ee3ee20bcf148ddd, processorArchitecture=MSIL">
<HintPath>..\packages\PropertyChanged.Fody.3.2.4\lib\net40\PropertyChanged.dll</HintPath>
</Reference>
<Reference Include="Stylet, Version=1.1.22.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\Stylet.1.1.22\lib\net45\Stylet.dll</HintPath>
<Reference Include="Stylet, Version=1.3.0.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\Stylet.1.3.0\lib\net45\Stylet.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Data" />
Expand Down Expand Up @@ -144,6 +144,10 @@
<DependentUpon>SearchView.xaml</DependentUpon>
</Compile>
<Compile Include="Pages\SearchViewModel.cs" />
<Compile Include="Pages\ShellView.xaml.cs">
<DependentUpon>ShellView.xaml</DependentUpon>
</Compile>
<Compile Include="Pages\ShellViewModel.cs" />
<Compile Include="Tidal\Enum.cs" />
<Compile Include="Tidal\Model.cs" />
<Compile Include="Tidal\TidalTool.cs" />
Expand Down Expand Up @@ -235,6 +239,10 @@
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="Pages\ShellView.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
</ItemGroup>
<ItemGroup>
<Resource Include="FodyWeavers.xml">
Expand Down Expand Up @@ -269,13 +277,15 @@
<Resource Include="Resource\Tidal.png" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="..\packages\Fody.6.0.6\build\Fody.targets" Condition="Exists('..\packages\Fody.6.0.6\build\Fody.targets')" />
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
<PropertyGroup>
<ErrorText>此项目引用这台计算机上缺少的 NuGet 程序包。使用 NuGet 程序包还原可下载这些程序包。有关详细信息,请参阅 http://go.microsoft.com/fwlink/?LinkID=322105。缺少的文件是 {0}。</ErrorText>
<ErrorText>这台计算机上缺少此项目引用的 NuGet 程序包。使用NuGet 程序包还原”可下载这些程序包。有关更多信息,请参见 http://go.microsoft.com/fwlink/?LinkID=322105。缺少的文件是 {0}。</ErrorText>
</PropertyGroup>
<Error Condition="!Exists('..\packages\Costura.Fody.3.3.0\build\Costura.Fody.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\Costura.Fody.3.3.0\build\Costura.Fody.props'))" />
<Error Condition="!Exists('..\packages\Fody.3.3.5\build\Fody.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\Fody.3.3.5\build\Fody.targets'))" />
<Error Condition="!Exists('..\packages\PropertyChanged.Fody.2.6.0\build\PropertyChanged.Fody.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\PropertyChanged.Fody.2.6.0\build\PropertyChanged.Fody.props'))" />
<Error Condition="!Exists('..\packages\Fody.6.0.6\build\Fody.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\Fody.6.0.6\build\Fody.targets'))" />
<Error Condition="!Exists('..\packages\Costura.Fody.4.1.0\build\Costura.Fody.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\Costura.Fody.4.1.0\build\Costura.Fody.props'))" />
<Error Condition="!Exists('..\packages\MaterialDesignThemes.3.0.1\build\MaterialDesignThemes.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\MaterialDesignThemes.3.0.1\build\MaterialDesignThemes.targets'))" />
<Error Condition="!Exists('..\packages\PropertyChanged.Fody.3.2.4\build\PropertyChanged.Fody.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\PropertyChanged.Fody.3.2.4\build\PropertyChanged.Fody.props'))" />
</Target>
<Import Project="..\packages\Fody.3.3.5\build\Fody.targets" Condition="Exists('..\packages\Fody.3.3.5\build\Fody.targets')" />
<Import Project="..\packages\MaterialDesignThemes.3.0.1\build\MaterialDesignThemes.targets" Condition="Exists('..\packages\MaterialDesignThemes.3.0.1\build\MaterialDesignThemes.targets')" />
</Project>
19 changes: 16 additions & 3 deletions TIDALDL-UI/TIDALDL-UI/Tidal/TidalTool.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
using TagLib;
using TIDALDL_UI.Else;
using System.Windows.Data;
using System.Text.RegularExpressions;

namespace Tidal
{
Expand Down Expand Up @@ -47,6 +48,7 @@ public static void logout()
ISLOGIN = false;
}

public static string loginErrlabel = "";
public static bool login(string UserName, string Password)
{
if (ISLOGIN)
Expand All @@ -67,8 +69,12 @@ public static bool login(string UserName, string Password)
if (ISLOGIN)
return true;
if (Errmsg.IsNotBlank())
{
loginErrlabel = AIGS.Helper.JsonHelper.GetValue(Errmsg, "userMessage");
if (loginErrlabel == null)
loginErrlabel = Errmsg;
return false;

}
if (i == 0)
SessID1 = JsonHelper.GetValue(sRet, "sessionId");
else
Expand Down Expand Up @@ -690,10 +696,17 @@ public static string getAlbumFolder(string basePath, Album album)

public static string getAlbumCoverPath(string basePath,Album album)
{
string sRet = string.Format("{0}/Album/{1}/{2}/{2}.jpg", basePath, formatPath(album.Artist.Name), formatPath(album.Title));
string sAlbumDir = getAlbumFolder(basePath, album);
string title = Regex.Replace(album.Title.Replace("(", "(").Replace(")", ")"), @"\([^\(]*\)", "");
string sRet = string.Format("{0}/{1}.jpg", sAlbumDir, formatPath(title));
if (sRet.Length >= 260)
{
int iLen = sRet.Length - 260;
sRet = string.Format("{0}/{1}.jpg", sAlbumDir, formatPath(title).Substring(0, formatPath(title).Length - iLen));
}
return Path.GetFullPath(sRet);
}

public static string getTrackPath(string basePath, Album album, Track track, string sdlurl, bool hyphen=false, Playlist plist=null, string trackTitle = null, bool artistBeforeTitle = false)
{
string sArtistStr = "";
Expand Down
16 changes: 8 additions & 8 deletions TIDALDL-UI/TIDALDL-UI/packages.config
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Costura.Fody" version="3.3.0" targetFramework="net452" />
<package id="Fody" version="3.3.5" targetFramework="net452" developmentDependency="true" />
<package id="MaterialDesignColors" version="1.1.3" targetFramework="net452" />
<package id="MaterialDesignThemes" version="2.5.1" targetFramework="net452" />
<package id="Costura.Fody" version="4.1.0" targetFramework="net452" />
<package id="Fody" version="6.0.6" targetFramework="net452" developmentDependency="true" />
<package id="MaterialDesignColors" version="1.2.2" targetFramework="net452" />
<package id="MaterialDesignThemes" version="3.0.1" targetFramework="net452" />
<package id="NPinyin" version="0.2.6321.26573" targetFramework="net452" />
<package id="PropertyChanged.Fody" version="2.6.0" targetFramework="net452" />
<package id="SharpZipLib" version="1.1.0" targetFramework="net452" />
<package id="Stylet" version="1.1.22" targetFramework="net452" />
<package id="Stylet.Start" version="1.1.22" targetFramework="net452" />
<package id="PropertyChanged.Fody" version="3.2.4" targetFramework="net452" />
<package id="SharpZipLib" version="1.2.0" targetFramework="net452" />
<package id="Stylet" version="1.3.0" targetFramework="net452" />
<package id="Stylet.Start" version="1.3.0" targetFramework="net452" />
<package id="taglib" version="2.1.0.0" targetFramework="net452" />
</packages>
6 changes: 5 additions & 1 deletion TIDALDL-UI/TIDALDL-UI/updateLog.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
#### v1.1.0.10
#### v1.1.0.11
- Fix bug of download artwork
- Show errlabel when login err

#### v1.1.0.10
- Get ep&singles
- Check if song is downloaded already
- Fix bug of login
Expand Down

0 comments on commit 2f565d8

Please sign in to comment.