Skip to content

Commit 808c669

Browse files
committed
Small function update
1 parent fef856c commit 808c669

37 files changed

+1560
-329
lines changed

.gitignore

+6-1
Original file line numberDiff line numberDiff line change
@@ -360,4 +360,9 @@ MigrationBackup/
360360
.ionide/
361361

362362
# Fody - auto-generated XML schema
363-
FodyWeavers.xsd
363+
FodyWeavers.xsd
364+
365+
366+
#other
367+
design/
368+
design/*

App.config

+1-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
</dependentAssembly>
4141
<dependentAssembly>
4242
<assemblyIdentity name="Microsoft.Bcl.AsyncInterfaces" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral"/>
43-
<bindingRedirect oldVersion="0.0.0.0-6.0.0.0" newVersion="6.0.0.0"/>
43+
<bindingRedirect oldVersion="0.0.0.0-6.0.0.0" newVersion="7.0.0.0"/>
4444
</dependentAssembly>
4545
<dependentAssembly>
4646
<assemblyIdentity name="Microsoft.Extensions.Configuration.EnvironmentVariables" publicKeyToken="adb9793829ddae60" culture="neutral"/>

App.xaml.cs

+1
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,7 @@ public partial class App
8282
services.AddTransient<DownloadWindowViewModel>();
8383
}).Build();
8484

85+
8586
private async void OnStartup(object sender, StartupEventArgs e)
8687
{
8788
XmlConfigurator.Configure();

DarkMode_2.csproj

+76-22
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?xml version="1.0" encoding="utf-8"?>
1+
<?xml version="1.0" encoding="utf-8"?>
22
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
33
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
44
<PropertyGroup>
@@ -20,7 +20,7 @@
2020
<IsWebBootstrapper>false</IsWebBootstrapper>
2121
<RuntimeIdentifiers>win-x64;win-arm64;win</RuntimeIdentifiers>
2222
<TargetFrameworkProfile />
23-
<PublishUrl>publish\</PublishUrl>
23+
<PublishUrl>D:\Desktop\public\</PublishUrl>
2424
<Install>true</Install>
2525
<InstallFrom>Disk</InstallFrom>
2626
<UpdateEnabled>false</UpdateEnabled>
@@ -30,8 +30,9 @@
3030
<UpdatePeriodically>false</UpdatePeriodically>
3131
<UpdateRequired>false</UpdateRequired>
3232
<MapFileExtensions>true</MapFileExtensions>
33+
<TargetCulture>zh-CN</TargetCulture>
3334
<ApplicationRevision>1</ApplicationRevision>
34-
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
35+
<ApplicationVersion>2.1.3.%2a</ApplicationVersion>
3536
<UseApplicationTrust>false</UseApplicationTrust>
3637
<PublishWizardCompleted>true</PublishWizardCompleted>
3738
<BootstrapperEnabled>true</BootstrapperEnabled>
@@ -64,10 +65,10 @@
6465
<StartupObject />
6566
</PropertyGroup>
6667
<PropertyGroup>
67-
<ManifestCertificateThumbprint>87096E6F81E5257E95B6EA90EEAB5C64BEE34F59</ManifestCertificateThumbprint>
68+
<ManifestCertificateThumbprint>A2DED38FEA9DE4C15FD140AE858B4EC31CBB2EE6</ManifestCertificateThumbprint>
6869
</PropertyGroup>
6970
<PropertyGroup>
70-
<ManifestKeyFile>DarkMode_2_TemporaryKey.pfx</ManifestKeyFile>
71+
<ManifestKeyFile>Melon Studio.pfx</ManifestKeyFile>
7172
</PropertyGroup>
7273
<PropertyGroup>
7374
<GenerateManifests>false</GenerateManifests>
@@ -76,11 +77,9 @@
7677
<SignManifests>true</SignManifests>
7778
</PropertyGroup>
7879
<PropertyGroup>
79-
<TargetZone>LocalIntranet</TargetZone>
80-
</PropertyGroup>
81-
<PropertyGroup>
82-
<ApplicationManifest>app.manifest</ApplicationManifest>
80+
<TargetZone>Custom</TargetZone>
8381
</PropertyGroup>
82+
<PropertyGroup />
8483
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|ARM64'">
8584
<DebugSymbols>true</DebugSymbols>
8685
<OutputPath>bin\ARM64\Debug\</OutputPath>
@@ -118,6 +117,49 @@
118117
<LangVersion>preview</LangVersion>
119118
<ErrorReport>prompt</ErrorReport>
120119
</PropertyGroup>
120+
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'All|AnyCPU'">
121+
<OutputPath>bin\All\</OutputPath>
122+
<DefineConstants>TRACE</DefineConstants>
123+
<Optimize>true</Optimize>
124+
<DebugType>pdbonly</DebugType>
125+
<PlatformTarget>x64</PlatformTarget>
126+
<LangVersion>preview</LangVersion>
127+
<ErrorReport>prompt</ErrorReport>
128+
</PropertyGroup>
129+
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'All|ARM64'">
130+
<OutputPath>bin\Out\ARM64\</OutputPath>
131+
<DefineConstants>TRACE</DefineConstants>
132+
<Optimize>true</Optimize>
133+
<DebugType>none</DebugType>
134+
<PlatformTarget>ARM64</PlatformTarget>
135+
<LangVersion>preview</LangVersion>
136+
<ErrorReport>prompt</ErrorReport>
137+
<Prefer32Bit>true</Prefer32Bit>
138+
<GenerateSatelliteAssembliesForCore>true</GenerateSatelliteAssembliesForCore>
139+
</PropertyGroup>
140+
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'All|x64'">
141+
<OutputPath>bin\Out\x64\</OutputPath>
142+
<DefineConstants>TRACE</DefineConstants>
143+
<Optimize>true</Optimize>
144+
<DebugType>none</DebugType>
145+
<PlatformTarget>x64</PlatformTarget>
146+
<LangVersion>preview</LangVersion>
147+
<ErrorReport>prompt</ErrorReport>
148+
<Prefer32Bit>true</Prefer32Bit>
149+
<GenerateSatelliteAssembliesForCore>false</GenerateSatelliteAssembliesForCore>
150+
</PropertyGroup>
151+
<PropertyGroup>
152+
<SignAssembly>false</SignAssembly>
153+
</PropertyGroup>
154+
<PropertyGroup>
155+
<ApplicationManifest>Properties\app.manifest</ApplicationManifest>
156+
</PropertyGroup>
157+
<PropertyGroup>
158+
<AssemblyOriginatorKeyFile>Melon Studio.pfx</AssemblyOriginatorKeyFile>
159+
</PropertyGroup>
160+
<PropertyGroup>
161+
<ManifestTimestampUrl>http://timestamp.digicert.com</ManifestTimestampUrl>
162+
</PropertyGroup>
121163
<ItemGroup>
122164
<Reference Include="System" />
123165
<Reference Include="System.ComponentModel.Composition" />
@@ -148,6 +190,12 @@
148190
<Generator>MSBuild:Compile</Generator>
149191
<SubType>Designer</SubType>
150192
</ApplicationDefinition>
193+
<Compile Include="i18n\Languages.zh-TW.Designer.cs">
194+
<AutoGen>True</AutoGen>
195+
<DesignTime>True</DesignTime>
196+
<DependentUpon>Languages.zh-TW.resx</DependentUpon>
197+
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
198+
</Compile>
151199
<Compile Include="Models\AppConfig.cs" />
152200
<Compile Include="Models\AutoStartManager.cs" />
153201
<Compile Include="Models\Colors\Pa__one.cs" />
@@ -168,6 +216,7 @@
168216
<Compile Include="Models\SwitchMode.cs" />
169217
<Compile Include="Models\SystemHotKey.cs" />
170218
<Compile Include="Models\TimeConverter.cs" />
219+
<Compile Include="Models\ToastHelper.cs" />
171220
<Compile Include="Models\Update.cs" />
172221
<Compile Include="Models\VersionControl.cs" />
173222
<Compile Include="Models\WallpaperChanger.cs" />
@@ -179,6 +228,7 @@
179228
</Compile>
180229
<Compile Include="Services\ApplicationHostService.cs" />
181230
<Compile Include="Services\Contracts\ITestWindowService.cs" />
231+
<Compile Include="Services\MessageQueue\QueueService.cs" />
182232
<Compile Include="Services\PageService.cs" />
183233
<Compile Include="Services\TestWindowService.cs" />
184234
<Compile Include="ViewModels\ColorsViewModel.cs" />
@@ -286,29 +336,26 @@
286336
<Compile Include="Properties\AssemblyInfo.cs">
287337
<SubType>Code</SubType>
288338
</Compile>
289-
<Compile Include="Properties\Settings.Designer.cs">
290-
<AutoGen>True</AutoGen>
291-
<DependentUpon>Settings.settings</DependentUpon>
292-
<DesignTimeSharedInput>True</DesignTimeSharedInput>
293-
</Compile>
294339
<EmbeddedResource Include="i18n\Languages.resx">
295-
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
296340
<Generator>PublicResXFileCodeGenerator</Generator>
297341
<LastGenOutput>Languages.Designer.cs</LastGenOutput>
298342
</EmbeddedResource>
299343
<EmbeddedResource Include="i18n\Languages.en-US.resx">
300344
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
301345
</EmbeddedResource>
302-
<None Include="app.manifest" />
303-
<None Include="DarkMode_2_TemporaryKey.pfx" />
346+
<EmbeddedResource Include="i18n\Languages.zh-CN.resx">
347+
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
348+
</EmbeddedResource>
349+
<EmbeddedResource Include="i18n\Languages.zh-TW.resx">
350+
<Generator>PublicResXFileCodeGenerator</Generator>
351+
<LastGenOutput>Languages.zh-TW.Designer.cs</LastGenOutput>
352+
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
353+
</EmbeddedResource>
304354
<None Include="i18n\languages_list.json">
305355
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
306356
</None>
357+
<None Include="Melon Studio.pfx" />
307358
<None Include="Properties\app.manifest" />
308-
<None Include="Properties\Settings.settings">
309-
<Generator>SettingsSingleFileGenerator</Generator>
310-
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
311-
</None>
312359
<Resource Include="Resources\Fonts\icons.ttf" />
313360
</ItemGroup>
314361
<ItemGroup>
@@ -345,13 +392,21 @@
345392
<PackageReference Include="WPFLocalizeExtension">
346393
<Version>3.10.0</Version>
347394
</PackageReference>
395+
<PackageReference Include="XAMLMarkupExtensions">
396+
<Version>2.1.3</Version>
397+
</PackageReference>
348398
</ItemGroup>
349399
<ItemGroup>
350400
<BootstrapperPackage Include=".NETFramework,Version=v4.7.2">
351401
<Visible>False</Visible>
352402
<ProductName>Microsoft .NET Framework 4.7.2 %28x86 和 x64%29</ProductName>
353403
<Install>true</Install>
354404
</BootstrapperPackage>
405+
<BootstrapperPackage Include=".NETFramework,Version=v4.8">
406+
<Visible>False</Visible>
407+
<ProductName>Microsoft .NET Framework 4.8 %28x86 和 x64%29</ProductName>
408+
<Install>true</Install>
409+
</BootstrapperPackage>
355410
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
356411
<Visible>False</Visible>
357412
<ProductName>.NET Framework 3.5 SP1</ProductName>
@@ -366,7 +421,6 @@
366421
<Resource Include="Resources\we%28dark%29.png" />
367422
<Resource Include="Resources\we%28light%29.png" />
368423
</ItemGroup>
369-
<ItemGroup />
370424
<ItemGroup>
371425
<Resource Include="Resources\logo-new.ico" />
372426
<Resource Include="Resources\MouseDark.png" />

DarkMode_2.sln

+32-8
Original file line numberDiff line numberDiff line change
@@ -5,22 +5,46 @@ VisualStudioVersion = 17.2.32630.192
55
MinimumVisualStudioVersion = 10.0.40219.1
66
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DarkMode_2", "DarkMode_2.csproj", "{4632FA56-60E4-4F55-958F-8283C97D2042}"
77
EndProject
8-
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DarkModeUpdate", "..\DarkModeUpdate\DarkModeUpdate.csproj", "{607E06C0-935C-4097-B35F-D37EC1DF245D}"
9-
EndProject
108
Global
119
GlobalSection(SolutionConfigurationPlatforms) = preSolution
10+
All|Any CPU = All|Any CPU
11+
All|ARM64 = All|ARM64
12+
All|x64 = All|x64
13+
All|x86 = All|x86
1214
Debug|Any CPU = Debug|Any CPU
15+
Debug|ARM64 = Debug|ARM64
16+
Debug|x64 = Debug|x64
17+
Debug|x86 = Debug|x86
1318
Release|Any CPU = Release|Any CPU
19+
Release|ARM64 = Release|ARM64
20+
Release|x64 = Release|x64
21+
Release|x86 = Release|x86
1422
EndGlobalSection
1523
GlobalSection(ProjectConfigurationPlatforms) = postSolution
24+
{4632FA56-60E4-4F55-958F-8283C97D2042}.All|Any CPU.ActiveCfg = All|x64
25+
{4632FA56-60E4-4F55-958F-8283C97D2042}.All|Any CPU.Build.0 = All|x64
26+
{4632FA56-60E4-4F55-958F-8283C97D2042}.All|ARM64.ActiveCfg = All|ARM64
27+
{4632FA56-60E4-4F55-958F-8283C97D2042}.All|ARM64.Build.0 = All|ARM64
28+
{4632FA56-60E4-4F55-958F-8283C97D2042}.All|x64.ActiveCfg = All|x64
29+
{4632FA56-60E4-4F55-958F-8283C97D2042}.All|x64.Build.0 = All|x64
30+
{4632FA56-60E4-4F55-958F-8283C97D2042}.All|x86.ActiveCfg = All|Any CPU
31+
{4632FA56-60E4-4F55-958F-8283C97D2042}.All|x86.Build.0 = All|Any CPU
1632
{4632FA56-60E4-4F55-958F-8283C97D2042}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
1733
{4632FA56-60E4-4F55-958F-8283C97D2042}.Debug|Any CPU.Build.0 = Debug|Any CPU
18-
{4632FA56-60E4-4F55-958F-8283C97D2042}.Release|Any CPU.ActiveCfg = Release|Any CPU
19-
{4632FA56-60E4-4F55-958F-8283C97D2042}.Release|Any CPU.Build.0 = Release|Any CPU
20-
{607E06C0-935C-4097-B35F-D37EC1DF245D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
21-
{607E06C0-935C-4097-B35F-D37EC1DF245D}.Debug|Any CPU.Build.0 = Debug|Any CPU
22-
{607E06C0-935C-4097-B35F-D37EC1DF245D}.Release|Any CPU.ActiveCfg = Release|Any CPU
23-
{607E06C0-935C-4097-B35F-D37EC1DF245D}.Release|Any CPU.Build.0 = Release|Any CPU
34+
{4632FA56-60E4-4F55-958F-8283C97D2042}.Debug|ARM64.ActiveCfg = Debug|ARM64
35+
{4632FA56-60E4-4F55-958F-8283C97D2042}.Debug|ARM64.Build.0 = Debug|ARM64
36+
{4632FA56-60E4-4F55-958F-8283C97D2042}.Debug|x64.ActiveCfg = Debug|x64
37+
{4632FA56-60E4-4F55-958F-8283C97D2042}.Debug|x64.Build.0 = Debug|x64
38+
{4632FA56-60E4-4F55-958F-8283C97D2042}.Debug|x86.ActiveCfg = Debug|Any CPU
39+
{4632FA56-60E4-4F55-958F-8283C97D2042}.Debug|x86.Build.0 = Debug|Any CPU
40+
{4632FA56-60E4-4F55-958F-8283C97D2042}.Release|Any CPU.ActiveCfg = Release|x64
41+
{4632FA56-60E4-4F55-958F-8283C97D2042}.Release|Any CPU.Build.0 = Release|x64
42+
{4632FA56-60E4-4F55-958F-8283C97D2042}.Release|ARM64.ActiveCfg = Release|ARM64
43+
{4632FA56-60E4-4F55-958F-8283C97D2042}.Release|ARM64.Build.0 = Release|ARM64
44+
{4632FA56-60E4-4F55-958F-8283C97D2042}.Release|x64.ActiveCfg = Release|x64
45+
{4632FA56-60E4-4F55-958F-8283C97D2042}.Release|x64.Build.0 = Release|x64
46+
{4632FA56-60E4-4F55-958F-8283C97D2042}.Release|x86.ActiveCfg = Release|Any CPU
47+
{4632FA56-60E4-4F55-958F-8283C97D2042}.Release|x86.Build.0 = Release|Any CPU
2448
EndGlobalSection
2549
GlobalSection(SolutionProperties) = preSolution
2650
HideSolutionNode = FALSE

Melon-Studio.cer

536 Bytes
Binary file not shown.

Models/DownloadManager.cs

+6
Original file line numberDiff line numberDiff line change
@@ -75,5 +75,11 @@ public async Task DownloadFileAsync(string url)
7575
}
7676
catch { }
7777
}
78+
79+
public static string GetDownloadPath()
80+
{
81+
string downloadFolderPath = Path.Combine(KnownFolders.Downloads.Path, DownloadFolderName);
82+
return downloadFolderPath;
83+
}
7884
}
7985
}

0 commit comments

Comments
 (0)