-
Notifications
You must be signed in to change notification settings - Fork 243
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #10 from the1812/preview
Update to v2.9.0
- Loading branch information
Showing
181 changed files
with
6,225 additions
and
21 deletions.
There are no files selected for viewing
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
2.8.2.0 | ||
2.9.0.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
|
||
Microsoft Visual Studio Solution File, Format Version 12.00 | ||
# Visual Studio 15 | ||
VisualStudioVersion = 15.0.26430.16 | ||
MinimumVisualStudioVersion = 10.0.40219.1 | ||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MalwarePatch", "MalwarePatch\MalwarePatch.csproj", "{769D2F79-D71B-4F5F-A61F-B1EF3A4C7414}" | ||
EndProject | ||
Global | ||
GlobalSection(SolutionConfigurationPlatforms) = preSolution | ||
Debug|Any CPU = Debug|Any CPU | ||
Release|Any CPU = Release|Any CPU | ||
EndGlobalSection | ||
GlobalSection(ProjectConfigurationPlatforms) = postSolution | ||
{769D2F79-D71B-4F5F-A61F-B1EF3A4C7414}.Debug|Any CPU.ActiveCfg = Debug|Any CPU | ||
{769D2F79-D71B-4F5F-A61F-B1EF3A4C7414}.Debug|Any CPU.Build.0 = Debug|Any CPU | ||
{769D2F79-D71B-4F5F-A61F-B1EF3A4C7414}.Release|Any CPU.ActiveCfg = Release|Any CPU | ||
{769D2F79-D71B-4F5F-A61F-B1EF3A4C7414}.Release|Any CPU.Build.0 = Release|Any CPU | ||
EndGlobalSection | ||
GlobalSection(SolutionProperties) = preSolution | ||
HideSolutionNode = FALSE | ||
EndGlobalSection | ||
EndGlobal |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<configuration> | ||
<startup> | ||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2"/> | ||
</startup> | ||
</configuration> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
<Application | ||
x:Class="MalwarePatch.App" | ||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
xmlns:wpf="clr-namespace:Ace.Wpf;assembly=Ace" | ||
xmlns:lang="clr-namespace:MalwarePatch.Languages"> | ||
<Application.Resources> | ||
<ResourceDictionary> | ||
<ResourceDictionary.MergedDictionaries> | ||
<ResourceDictionary | ||
Source="Assets/Icons.xaml" /> | ||
<ResourceDictionary | ||
Source="Assets/Icons.UserCertificates.xaml" /> | ||
</ResourceDictionary.MergedDictionaries> | ||
<SolidColorBrush | ||
x:Key="DwmColor" | ||
Color="{x:Static wpf:DwmEffect.ColorizationColor}" /> | ||
<SolidColorBrush | ||
x:Key="Foreground" | ||
Color="#F8F8F8" /> | ||
<SolidColorBrush | ||
x:Key="TitleBarBackground" | ||
Color="#263238" /> | ||
<SolidColorBrush | ||
x:Key="TitleBarForeground" | ||
Color="#8FFF" /> | ||
<SolidColorBrush | ||
x:Key="Background" | ||
Color="#324049" /> | ||
<SolidColorBrush | ||
x:Key="ToolbarBackground" | ||
Color="#703B699D" /> | ||
<SolidColorBrush | ||
x:Key="ProgressBackground" | ||
Color="#2000" /> | ||
<SolidColorBrush | ||
x:Key="ProgressForeground" | ||
Color="#448CB9" /> | ||
</ResourceDictionary> | ||
</Application.Resources> | ||
</Application> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
using MalwarePatch.CliTools; | ||
using MalwarePatch.Languages; | ||
using MalwarePatch.Models; | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Configuration; | ||
using System.Data; | ||
using System.Diagnostics; | ||
using System.Globalization; | ||
using System.IO; | ||
using System.Linq; | ||
using System.Reflection; | ||
using System.Threading; | ||
using System.Threading.Tasks; | ||
using System.Windows; | ||
using System.Windows.Shell; | ||
|
||
namespace MalwarePatch | ||
{ | ||
public partial class App : Application | ||
{ | ||
protected override void OnStartup(StartupEventArgs e) | ||
{ | ||
AppDomain.CurrentDomain.AssemblyResolve += assemblyResolveHandler; | ||
//StartupUri = new Uri("MainWindow.xaml", UriKind.RelativeOrAbsolute); | ||
base.OnStartup(e); | ||
// CultureInfo.CurrentUICulture = new CultureInfo("en-US"); | ||
AppJumpList.CreateJumpList(); | ||
#if DEBUG | ||
File.AppendAllText($"args.txt", string.Join(" ", e.Args)); | ||
#endif | ||
if (SilentUpdater.TryParse(e.Args) || | ||
UserCertificateCli.TryParse(e.Args) || | ||
MalwareChecker.TryParse(e.Args)) | ||
{ | ||
Shutdown(); | ||
} | ||
else | ||
{ | ||
Updater.InstallUpdateAndRun(this, e.Args); | ||
} | ||
} | ||
static Assembly assemblyResolveHandler(object s, ResolveEventArgs e) | ||
{ | ||
var dllName = new AssemblyName(e.Name).Name + ".dll"; | ||
var assembly = Assembly.GetExecutingAssembly(); | ||
var resourceName = assembly.GetManifestResourceNames().FirstOrDefault(name => name.EndsWith(dllName)); | ||
if (resourceName == null) | ||
{ | ||
return null; | ||
} | ||
using (var stream = assembly.GetManifestResourceStream(resourceName)) | ||
{ | ||
var assemblyData = new byte[stream.Length]; | ||
stream.Read(assemblyData, 0, assemblyData.Length); | ||
return Assembly.Load(assemblyData); | ||
} | ||
} | ||
} | ||
} |
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
using MalwarePatch.Languages; | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
using System.Threading.Tasks; | ||
using System.Windows; | ||
using System.Windows.Shell; | ||
|
||
namespace MalwarePatch | ||
{ | ||
static class AppJumpList | ||
{ | ||
public static void CreateJumpList() | ||
{ | ||
var jumpList = new JumpList(); | ||
var language = new MainLanguage(); | ||
jumpList.JumpItems.Add(new JumpTask | ||
{ | ||
Title = language[MainLanguage.Keys.DisallowProgram], | ||
Arguments = "--disallow", | ||
Description = language[MainLanguage.Keys.DisallowProgramDescription], | ||
IconResourceIndex = 1, | ||
}); | ||
jumpList.JumpItems.Add(new JumpTask | ||
{ | ||
Title = language[MainLanguage.Keys.AllowProgram], | ||
Arguments = "--allow", | ||
Description = language[MainLanguage.Keys.AllowProgramDescription], | ||
IconResourceIndex = 2, | ||
}); | ||
jumpList.ShowFrequentCategory = false; | ||
jumpList.ShowRecentCategory = false; | ||
JumpList.SetJumpList(Application.Current, jumpList); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
<ResourceDictionary | ||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> | ||
|
||
<Viewbox | ||
x:Shared="false" | ||
x:Key="DisallowFile" | ||
Stretch="Uniform"> | ||
<Canvas | ||
Width="24" | ||
Height="24" | ||
Canvas.Left="0" | ||
Canvas.Top="0"> | ||
<Canvas | ||
Clip="M0,0v15.873c0.0576,-0.0902,0.1249,-0.1761,0.2038,-0.2549l1.4142,-1.4143c0.2813,-0.2813,0.6628,-0.4394,1.0607,-0.4394c0.3978,0,0.7793,0.158,1.0606,0.4394L5,15.4645l1.2607,-1.2606c0.2813,-0.2813,0.6628,-0.4394,1.0606,-0.4394c0.3979,0,0.7794,0.158,1.0607,0.4394l1.4142,1.4143c0.5857,0.5858,0.5857,1.5355,0,2.1213L8.5355,19l1.2606,1.2606c0.5858,0.5857,0.5858,1.5354,0,2.1213L8.382,23.7962c-0.078,0.078,-0.1643,0.1455,-0.256,0.2038H24V0H0z"> | ||
<Canvas> | ||
<Canvas.RenderTransform> | ||
<TransformGroup> | ||
<TranslateTransform | ||
X="1" | ||
Y="0" /> | ||
</TransformGroup> | ||
</Canvas.RenderTransform> | ||
<Path | ||
Data="M6,2c-1.1,0,-1.99,0.9,-1.99,2L4,20c0,1.1,0.89,2,1.99,2H18c1.1,0,2,-0.9,2,-2V8l-6,-6H6zm7,7V3.5L18.5,9H13z" | ||
Fill="#FFFFFF" /> | ||
</Canvas> | ||
</Canvas> | ||
<Canvas> | ||
<Polygon | ||
Points="8.7355,21.3213 6.4142,19 8.7355,16.6787 7.3213,15.2645 5,17.5858 2.6787,15.2645 1.2645,16.6787 3.5858,19 1.2645,21.3213 2.6787,22.7355 5,20.4142 7.3213,22.7355" | ||
Fill="#FFFFFF" | ||
StrokeLineJoin="Miter" /> | ||
</Canvas> | ||
</Canvas> | ||
</Viewbox> | ||
|
||
<Viewbox | ||
x:Shared="false" | ||
x:Key="AllowFile" | ||
Stretch="Uniform"> | ||
<Canvas | ||
Width="24" | ||
Height="24" | ||
Canvas.Left="0" | ||
Canvas.Top="0"> | ||
<Canvas | ||
Clip="M0,0v18.336l1.0038,-1.0038c0.2813,-0.2813,0.6628,-0.4394,1.0607,-0.4394c0.3978,0,0.7793,0.158,1.0606,0.4394L4.3929,18.6l3.782,-3.7819c0.5857,-0.5857,1.5354,-0.5857,2.1213,0l1.4142,1.4142c0.2813,0.2813,0.4393,0.6628,0.4393,1.0606c0.0001,0.3979,-0.158,0.7794,-0.4393,1.0606L6.064,24H24V0H0z"> | ||
<Canvas> | ||
<Canvas.RenderTransform> | ||
<TransformGroup> | ||
<TranslateTransform | ||
X="1" | ||
Y="0" /> | ||
</TransformGroup> | ||
</Canvas.RenderTransform> | ||
<Path | ||
Data="M6,2c-1.1,0,-1.99,0.9,-1.99,2L4,20c0,1.1,0.89,2,1.99,2H18c1.1,0,2,-0.9,2,-2V8l-6,-6H6zm7,7V3.5L18.5,9H13z" | ||
Fill="#FFFFFF" /> | ||
</Canvas> | ||
</Canvas> | ||
<Canvas> | ||
<Polygon | ||
Points="9.2355,15.8787 4.3929,20.7213 2.0645,18.3929 0.6503,19.8071 2.9787,22.1355 4.3929,23.5497 5.8071,22.1355 10.6497,17.2929" | ||
Fill="#FFFFFF" | ||
StrokeLineJoin="Miter" /> | ||
</Canvas> | ||
</Canvas> | ||
</Viewbox> | ||
|
||
</ResourceDictionary> |
Oops, something went wrong.