Commit 1.2

This commit is contained in:
Belim 2023-12-04 20:35:09 +01:00
parent abd9c3a3f1
commit dca5749fb6
85 changed files with 8820 additions and 0 deletions

49
src/Bloatynosy.sln Normal file
View File

@ -0,0 +1,49 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.1.32210.238
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Bloatynosy", "Bloatynosy\Bloatynosy.csproj", "{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Debug|ARM = Debug|ARM
Debug|ARM64 = Debug|ARM64
Debug|x64 = Debug|x64
Debug|x86 = Debug|x86
Release|Any CPU = Release|Any CPU
Release|ARM = Release|ARM
Release|ARM64 = Release|ARM64
Release|x64 = Release|x64
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Debug|Any CPU.Build.0 = Debug|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Debug|ARM.ActiveCfg = Debug|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Debug|ARM.Build.0 = Debug|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Debug|ARM64.ActiveCfg = Debug|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Debug|ARM64.Build.0 = Debug|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Debug|x64.ActiveCfg = Debug|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Debug|x64.Build.0 = Debug|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Debug|x86.ActiveCfg = Debug|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Debug|x86.Build.0 = Debug|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Release|Any CPU.ActiveCfg = Release|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Release|Any CPU.Build.0 = Release|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Release|ARM.ActiveCfg = Release|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Release|ARM.Build.0 = Release|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Release|ARM64.ActiveCfg = Release|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Release|ARM64.Build.0 = Release|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Release|x64.ActiveCfg = Release|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Release|x64.Build.0 = Release|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Release|x86.ActiveCfg = Release|Any CPU
{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}.Release|x86.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {8E4625AD-7C1B-4CFB-8374-5F44D4508DBA}
EndGlobalSection
EndGlobal

View File

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.8"/>
</startup>
</configuration>

BIN
src/Bloatynosy/AppIcon.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.7 KiB

View File

@ -0,0 +1,226 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{44CAFCEB-0F6D-487F-9F5F-63F230DBB069}</ProjectGuid>
<OutputType>WinExe</OutputType>
<RootNamespace>Bloatynosy</RootNamespace>
<AssemblyName>Bloatynosy</AssemblyName>
<TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<AutoGenerateBindingRedirects>false</AutoGenerateBindingRedirects>
<Deterministic>true</Deterministic>
<IsWebBootstrapper>false</IsWebBootstrapper>
<TargetFrameworkProfile />
<PublishUrl>publish\</PublishUrl>
<Install>true</Install>
<InstallFrom>Disk</InstallFrom>
<UpdateEnabled>false</UpdateEnabled>
<UpdateMode>Foreground</UpdateMode>
<UpdateInterval>7</UpdateInterval>
<UpdateIntervalUnits>Days</UpdateIntervalUnits>
<UpdatePeriodically>false</UpdatePeriodically>
<UpdateRequired>false</UpdateRequired>
<MapFileExtensions>true</MapFileExtensions>
<ApplicationRevision>0</ApplicationRevision>
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
<UseApplicationTrust>false</UseApplicationTrust>
<BootstrapperEnabled>true</BootstrapperEnabled>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup />
<PropertyGroup>
<StartupObject />
</PropertyGroup>
<PropertyGroup>
<ApplicationManifest>app.manifest</ApplicationManifest>
</PropertyGroup>
<PropertyGroup>
<ApplicationIcon>AppIcon.ico</ApplicationIcon>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Management.Automation, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\Windows\Microsoft.NET\assembly\GAC_MSIL\System.Management.Automation\v4.0_3.0.0.0__31bf3856ad364e35\System.Management.Automation.dll</HintPath>
</Reference>
<Reference Include="System.Runtime.CompilerServices.VisualC" />
<Reference Include="System.Runtime.Serialization" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Data" />
<Reference Include="System.Deployment" />
<Reference Include="System.Drawing" />
<Reference Include="System.Net.Http" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="FeatureBase.cs" />
<Compile Include="FeatureNode.cs" />
<Compile Include="Features\Bloatware\StoreAppsPrivate.cs" />
<Compile Include="Features\Bloatware\StoreHallOfShame.cs" />
<Compile Include="Features\Browser\GoogleChrome.cs" />
<Compile Include="Features\Browser\MicrosoftEdge.cs" />
<Compile Include="Features\Browser\MozillaFirefox.cs" />
<Compile Include="Features\Desktop\AppsTheme.cs" />
<Compile Include="Features\Desktop\SnapAssistFlyout.cs" />
<Compile Include="Features\Desktop\Stickers.cs" />
<Compile Include="Features\Desktop\Transparency.cs" />
<Compile Include="Features\Desktop\Widgets.cs" />
<Compile Include="Features\Desktop\WidgetsR.cs" />
<Compile Include="Features\Desktop\WindowsTheme.cs" />
<Compile Include="Features\Explorer\HiddenFileExt.cs" />
<Compile Include="Features\Explorer\HiddenFileFolder.cs" />
<Compile Include="Features\Privacy\BackgroundApps.cs" />
<Compile Include="Features\Gaming\GameDVR.cs" />
<Compile Include="Features\Gaming\PowerThrottling.cs" />
<Compile Include="Features\Gaming\VisualFX.cs" />
<Compile Include="Features\Privacy\Advertising.cs" />
<Compile Include="Features\Privacy\AppsAutoInstall.cs" />
<Compile Include="Features\Privacy\CompatibilityTelemetry.cs" />
<Compile Include="Features\Privacy\DiagnosticData.cs" />
<Compile Include="Features\Privacy\Feedback.cs" />
<Compile Include="Features\Privacy\LocationTracking.cs" />
<Compile Include="Features\Privacy\SuggestedContent.cs" />
<Compile Include="Features\Privacy\TailoredExperiences.cs" />
<Compile Include="Features\Privacy\Telemetry.cs" />
<Compile Include="Features\Privacy\WindowsTips.cs" />
<Compile Include="Features\Bloatware\StoreApps.cs" />
<Compile Include="Features\Bloatware\StoreEngine.cs" />
<Compile Include="Features\System\FaxPrinter.cs" />
<Compile Include="Features\System\FullContextMenus.cs" />
<Compile Include="Features\Bloatware\OneDriveR.cs" />
<Compile Include="Features\System\RemoveW11Watermark.cs" />
<Compile Include="Features\System\TeamsAutostart.cs" />
<Compile Include="Features\System\TPMCheck.cs" />
<Compile Include="Features\System\XPSWriter.cs" />
<Compile Include="Features\Taskbar\Copilot.cs" />
<Compile Include="Features\Taskbar\MostUsedApps.cs" />
<Compile Include="Features\Taskbar\StartmenuLayout.cs" />
<Compile Include="Features\Taskbar\StartmenuSearch.cs" />
<Compile Include="Features\Taskbar\TaskbarChat.cs" />
<Compile Include="Features\Taskbar\TaskbarSearch.cs" />
<Compile Include="Features\Taskbar\TaskView.cs" />
<Compile Include="Helpers\ErrorHelper.cs" />
<Compile Include="Helpers\HelperTool.cs" />
<Compile Include="Helpers\OsHelper.cs" />
<Compile Include="Helpers\ViewHelper.cs" />
<Compile Include="ITreeNode.cs" />
<Compile Include="Helpers\RegistryHelper.cs" />
<Compile Include="MainForm.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="MainForm.Designer.cs">
<DependentUpon>MainForm.cs</DependentUpon>
</Compile>
<Compile Include="Modules\Setup\Pages.cs" />
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Properties\Resources.Designer.cs">
<AutoGen>True</AutoGen>
<DesignTime>True</DesignTime>
<DependentUpon>Resources.resx</DependentUpon>
</Compile>
<Compile Include="Github.cs" />
<Compile Include="Views\BloatyPageView.cs">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="Views\BloatyPageView.Designer.cs">
<DependentUpon>BloatyPageView.cs</DependentUpon>
</Compile>
<Compile Include="Views\PackagesPageView.cs">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="Views\PackagesPageView.Designer.cs">
<DependentUpon>PackagesPageView.cs</DependentUpon>
</Compile>
<Compile Include="Helpers\WindowsHelper.cs" />
<Compile Include="Views\NosyPageView.cs">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="Views\NosyPageView.Designer.cs">
<DependentUpon>NosyPageView.cs</DependentUpon>
</Compile>
<Compile Include="Views\WizardPageView.cs">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="Views\WizardPageView.Designer.cs">
<DependentUpon>WizardPageView.cs</DependentUpon>
</Compile>
<EmbeddedResource Include="MainForm.resx">
<DependentUpon>MainForm.cs</DependentUpon>
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="Properties\Resources.resx">
<Generator>ResXFileCodeGenerator</Generator>
<SubType>Designer</SubType>
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
</EmbeddedResource>
<EmbeddedResource Include="Views\BloatyPageView.resx">
<DependentUpon>BloatyPageView.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Views\PackagesPageView.resx">
<DependentUpon>PackagesPageView.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Views\NosyPageView.resx">
<DependentUpon>NosyPageView.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Views\WizardPageView.resx">
<DependentUpon>WizardPageView.cs</DependentUpon>
</EmbeddedResource>
<None Include="app.manifest" />
<None Include="Properties\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
</None>
<Compile Include="Properties\Settings.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
</ItemGroup>
<ItemGroup>
<None Include="App.config" />
</ItemGroup>
<ItemGroup>
<Content Include="AppIcon.ico" />
<Content Include="Resources\systemApps.txt" />
</ItemGroup>
<ItemGroup>
<BootstrapperPackage Include=".NETFramework,Version=v4.8">
<Visible>False</Visible>
<ProductName>Microsoft .NET Framework 4.8 %28x86 und x64%29</ProductName>
<Install>true</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
<Visible>False</Visible>
<ProductName>.NET Framework 3.5 SP1</ProductName>
<Install>false</Install>
</BootstrapperPackage>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
</Project>

View File

@ -0,0 +1,51 @@
using Bloatynosy;
using System.Threading.Tasks;
namespace Features.Feature
{
public abstract class FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
public string ScriptFilePath { get; set; } // Path to Powershell plugins directory
/// <summary>
/// Name of Feature
/// </summary>
/// <returns>The feature name</returns>
public abstract string ID();
/// <summary>
/// Description of Feature
/// </summary>
/// <returns>The feature tooltip</returns>
public abstract string Info();
/// <summary>
/// Checks whether Features should be applied
/// </summary>
/// <returns>Returns true if the feature should be applied, false otherwise.</returns>
public abstract bool CheckFeature();
/// <summary>
/// Do the Feature
/// </summary>
/// <returns>Returns true if the feature was successfull, false otherwise.</returns>
public abstract bool DoFeature();
/// <summary>
/// Undo the Feature
/// </summary>
/// <returns>Returns true if the feature was successfull, false otherwise.</returns>
public abstract bool UndoFeature();
public virtual bool LoadScriptFile()
{
// Check if the script file path is set for the feature
if (!string.IsNullOrEmpty(ScriptFilePath))
{
}
return false; // Return false if no script file path is set for the feature
}
}
}

View File

@ -0,0 +1,28 @@
using Bloatynosy;
using System;
using System.Windows.Forms;
namespace Features.Feature
{
internal class FeatureNode : TreeNode
{
public FeatureBase Feature { get; }
public string ScriptFilePath { get; set; } // Path to the external script file
public FeatureNode(FeatureBase feature)
{
Feature = feature;
Text = Feature.ID();
Checked = true;
ScriptFilePath = ""; // Initialize the script file path
}
public string GetFeatureInfo()
{
return Feature.Info();
}
}
}

View File

@ -0,0 +1,81 @@
using Bloatynosy;
using System;
using System.Diagnostics;
using System.IO;
using System.Net;
namespace Features.Feature.Bloatware
{
internal class OneDriveRemove : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
public override string ID()
{
return "[MIDDLE] Uninstall OneDrive";
}
public override string Info()
{
return "";
}
public override bool CheckFeature()
{
var appPath = Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData) + @"\Microsoft\OneDrive\OneDrive.exe";
if (!File.Exists(appPath))
{
return false;
}
return true;
}
public override bool DoFeature()
{
try
{
Process proc = new Process();
proc.StartInfo.CreateNoWindow = true;
proc.StartInfo.RedirectStandardError = true;
proc.StartInfo.RedirectStandardOutput = true;
proc.StartInfo.UseShellExecute = false;
logger.Log("Uninstalling OneDrive...Please wait.");
string sysEnv = Environment.GetEnvironmentVariable("SYSTEMROOT");
proc.StartInfo.FileName = "taskkill"; proc.StartInfo.Arguments = "/F /IM OneDrive.exe";
proc.Start();
proc.StartInfo.FileName = (sysEnv + @"\System32\OneDriveSetup.exe");
proc.StartInfo.Arguments = "/uninstall";
proc.Start();
proc.WaitForExit();
logger.Log("Onedrive has been successfully uninstalled.");
}
catch (Exception ex)
{ logger.Log("{0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
using (var client = new WebClient())
{
logger.Log("= We've opened the download link in your Browser.\n\nPlease install the package \"OneDrive\". ");
Process.Start("https://www.microsoft.com/microsoft-365/onedrive/download");
return true;
}
}
catch (Exception ex)
{ logger.Log("{0}", ex.Message); }
return false;
}
}
}

View File

@ -0,0 +1,106 @@
using Bloatynosy;
using System.Linq;
using System.Management.Automation;
using System.Text.RegularExpressions;
namespace Features.Feature.Bloatware
{
internal class StoreApps : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private readonly PowerShell powerShell = PowerShell.Create();
public override string ID()
{
return "*[HIGH] Search and remove pre-installed bloatware apps automatically";
}
public override string Info()
{
return "To remove specific apps use the Bloatpilot function in the bottom right corner.";
}
private void RemoveApps(string str, out bool removed)
{
removed = false;
bool error = false;
using (PowerShell script = PowerShell.Create())
{
script.AddScript("Get-AppxPackage " + str + " | Remove-AppxPackage");
script.Invoke();
error = script.HadErrors;
}
if (error)
{
logger.Log("Error removing " + str);
}
else
{
logger.Log("App removed " + str);
removed = true;
}
}
public override bool CheckFeature()
{
var apps = BloatwareList.GetList();
powerShell.Commands.Clear();
powerShell.AddCommand("get-appxpackage");
powerShell.AddCommand("Select").AddParameter("property", "name");
bool foundMatches = false; // Flag variable to track if matches are found
logger.Log("8. The following bloatware has been found:");
try
{
foreach (PSObject result in powerShell.Invoke())
{
string current = result.Properties["Name"].Value.ToString();
if (apps.Contains(Regex.Replace(current, "(@{Name=)|(})", "")))
{
foundMatches = true;
logger.Log((Regex.Replace(current, "(@{Name=)|(})", "")));
}
}
}
catch { }
if (!foundMatches)
{
logger.Log("Your system is free of bloatware.");
}
return foundMatches; // Return value of foundMatches
}
public override bool DoFeature()
{
var apps = BloatwareList.GetList();
logger.Log("Searching bloatware database...");
bool foundAndDeleted = false;
foreach (var str in apps)
{
RemoveApps(str, out bool removed);
if (removed)
{
logger.Log("[-] Uninstalled " + str.ToString());
foundAndDeleted = true;
}
}
return foundAndDeleted;
}
public override bool UndoFeature()
{
logger.Log("-[Remove Store Apps] This feature does not provide a restore mode.");
return false;
}
}
}

View File

@ -0,0 +1,126 @@
using Bloatynosy;
using System;
using System.Diagnostics;
using System.IO;
using System.Management.Automation;
namespace Features.Feature.Bloatware
{
internal class StoreAppsPrivate : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private readonly PowerShell powerShell = PowerShell.Create();
public override string ID()
{
return "*[LOW] Remove bloatware based on private database";
}
public override string Info()
{
return "Open the bloaty.txt file in the app directory of Bloatynosy to edit your database.";
}
private void RemoveApps(string str)
{
Process process = new Process();
ProcessStartInfo startInfo = new ProcessStartInfo();
startInfo.WindowStyle = ProcessWindowStyle.Hidden;
startInfo.FileName = "powershell.exe";
startInfo.Arguments = str;
process.StartInfo = startInfo;
process.Start();
process.WaitForExit();
}
public override bool CheckFeature()
{
try
{
string bloatyFilePath = Path.Combine(HelperTool.Utils.Data.DataRootDir, "bloaty.txt");
if (!File.Exists(bloatyFilePath))
{
logger.Log("Your private signature is free of bloatware.");
return false; // Indicate failure
}
string[] num = File.ReadAllLines(bloatyFilePath);
using (PowerShell powerShell = PowerShell.Create())
{
powerShell.AddCommand("get-appxpackage")
.AddCommand("Select").AddParameter("property", "name");
bool foundMatch = false;
logger.Log("8. The following apps would be removed based on your private bloatware database:");
foreach (string line in num)
{
string[] package = line.Split(':');
string appx = package[0].Trim();
foreach (PSObject result in powerShell.Invoke())
{
string current = result.ToString(); // Get the current app
if (current.Contains(appx))
{
foundMatch = true;
logger.Log("[-] " + appx);
break;
}
}
}
if (!foundMatch)
{
logger.Log("Your private scan is free of bloatware.\n[TIP] You can manually expand and maintain your private bloatware database \"bloaty.txt\" in \"app\" directory.");
}
return foundMatch; // Return value of foundMatch
}
}
catch (Exception ex)
{
logger.Log("[!] An error occurred: " + ex.Message);
return false; // Indicate failure
}
}
public override bool DoFeature()
{
string[] num = File.ReadAllLines(HelperTool.Utils.Data.DataRootDir + "/bloaty.txt");
powerShell.Commands.Clear();
powerShell.AddCommand("get-appxpackage");
powerShell.AddCommand("Select").AddParameter("property", "name");
foreach (PSObject result in powerShell.Invoke())
{
string current = result.ToString(); // Get the current app
for (int i = 0; i < num.Length; i++)
{
string[] package = num[i].Split(':');
string appx = package[0];
string command = package[1];
try
{
if (current.Contains(appx))
{
logger.Log("[?] Removing: " + appx + " (Wait...)");
RemoveApps(command);
logger.Log("[-] Removed: " + appx);
}
}
catch (Exception ex)
{ logger.Log("Error removing " + ex); }
}
}
return true;
}
public override bool UndoFeature()
{
logger.Log("- [Remove Store Apps] This feature does not provide a restore mode.");
return false;
}
}
}

View File

@ -0,0 +1,74 @@
using System.Collections.Generic;
namespace Bloatynosy
{
public static class BloatwareList
{
// Our Windows 11 bloatware list
public static IEnumerable<string> GetList()
{
var apps = new List<string>
{
"2FE3CB00.PICSART-PHOTOSTUDIO",
"4DF9E0F8.Netflix",
"5319275A.WhatsAppDesktop",
"9E2F88E3.TWITTER",
"NAVER.LINEwin8_8ptj331gd3tyt",
"SpotifyAB.SpotifyMusic",
"king.com.CandyCrushFriends",
"king.com.CandyCrushSaga",
"king.com.FarmHeroesSaga",
"22364Disney.ESPNBetaPWA",
"5A894077.McAfeeSecurity",
"AdobeSystemsIncorporated.AdobeCreativeCloudExpress",
"AmazonVideo.PrimeVideo",
"AppUp.IntelGraphicsExperience",
"B9ECED6F.ASUSPCAssistant",
"B9ECED6F.ScreenPadMaster",
"BytedancePte.Ltd.TikTok",
"Clipchamp.Clipchamp",
"DTSInc.DTSAudioProcess",
"AdobeSystemsIncorporated.AdobeLightroom",
"AdobeSystemsIncorporated.AdobePhotoshopExpress",
"Clipchamp.Clipchamp_yxz26nhyzhsrt",
"CorelCorporation.PaintShopPro",
"FACEBOOK.317180B0BB486",
"Facebook.InstagramBeta",
"AD2F1837.HPJumpStarts",
"AD2F1837.HPPCHardwareDiagnosticsWindows",
"AD2F1837.HPPowerManager",
"AD2F1837.HPPrivacySettings",
"AD2F1837.HPSupportAssistant",
"AD2F1837.HPSureShieldAI",
"AD2F1837.HPSystemInformation",
"AD2F1837.HPQuickDrop",
"AD2F1837.HPWorkWell",
"AD2F1837.myHP",
"AD2F1837.HPDesktopSupportUtilities",
"AD2F1837.HPQuickTouch",
"AD2F1837.HPEasyClean",
"AD2F1837.HPSystemInformation",
"Microsoft.549981C3F5F10",
"Microsoft.BingNews",
"Microsoft.BingWeather",
"Microsoft.GamingApp",
"Microsoft.Getstarted",
"Microsoft.Microsoft3DViewer",
"Microsoft.MicrosoftOfficeHub",
"Microsoft.MicrosoftSolitaireCollection",
"Microsoft.MicrosoftStickyNotes",
"Microsoft.MixedReality.Portal",
"Microsoft.Office.OneNote",
"Microsoft.OneDriveSync",
"Microsoft.OneConnect",
"Microsoft.People",
"Microsoft.Print3D",
"Microsoft.SkypeApp",
"Microsoft.Wallet",
"Microsoft.WindowsSoundRecorder"
};
return apps;
}
}
}

View File

@ -0,0 +1,27 @@
using System.Collections.Generic;
namespace Bloatynosy
{
public static class BloatwareHallOfShame
{
// Our Windows 11 Hall Of Shame
public static IEnumerable<string> GetList()
{
var apps = new List<string>
{
"BytedancePte.Ltd.TikTok",
"Facebook.InstagramBeta",
"Microsoft.MicrosoftOfficeHub",
"Microsoft.MicrosoftSolitaireCollection",
"Microsoft.ZuneVideo",
"Microsoft.MixedReality.Portal",
"Microsoft.Getstarted",
"Microsoft.Office.OneNote",
"Microsoft.Print3D",
"Microsoft.People",
};
return apps;
}
}
}

View File

@ -0,0 +1,66 @@
using Bloatynosy;
using Microsoft.Win32;
namespace Features.Feature.Browser
{
internal class ChromeTelemetry : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Google\Chrome";
private const int desiredValue = 0;
public override string ID()
{
return "[HIGH] Disable Google Chrome Telemetry";
}
public override string Info()
{
return "This policy may lead to the following behavior in Chrome Browser:\r\nManaged by your organization, your browser is managed." +
"\r\nThe changes can be reverted at any time.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "MetricsReportingEnabled", desiredValue) &&
RegistryHelper.IntEquals(keyName, "ChromeCleanupReportingEnabled", desiredValue) &&
RegistryHelper.IntEquals(keyName, "ChromeCleanupEnabled", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "MetricsReportingEnabled", desiredValue, RegistryValueKind.DWord);
Registry.SetValue(keyName, "ChromeCleanupReportingEnabled", desiredValue, RegistryValueKind.DWord);
Registry.SetValue(keyName, "ChromeCleanupEnabled", desiredValue, RegistryValueKind.DWord);
logger.Log("- Google Chrome Telemetry has been disabled.");
logger.Log(keyName);
return true;
}
catch
{ }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.LocalMachine.DeleteSubKeyTree(@"Software\Policies\Google\Chrome", false);
logger.Log("+ Google Chrome Telemetry has been enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,64 @@
using Bloatynosy;
using Microsoft.Win32;
namespace Features.Feature.Browser
{
internal class EdgeBingAIButton : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Edge";
private const int desiredValue = 0;
public override string ID()
{
return "[HIGH] Disable giant Bing search (AI chat) button in Edge Browser";
}
public override string Info()
{
return "This policy may lead to the following behavior in Edge Browser:\r\nManaged by your organization, your browser is managed." +
"\r\nThe changes can be reverted at any time.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "HubsSidebarEnabled", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "HubsSidebarEnabled", desiredValue, RegistryValueKind.DWord);
logger.Log("- Bing search (AI chat) button has been disabled.");
logger.Log(keyName);
return true;
}
catch
{ }
return false;
}
public override bool UndoFeature()
{
try
{
var RegKey = Registry.LocalMachine.OpenSubKey(@"Software\Policies\Microsoft\Edge", true);
RegKey.DeleteValue("HubsSidebarEnabled");
logger.Log("+ Bing search (AI chat) button has been enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,64 @@
using Bloatynosy;
using Microsoft.Win32;
namespace Features.Feature.Browser
{
internal class FirefoxTelemetry : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Mozilla\Firefox";
private const int desiredValue = 1;
public override string ID()
{
return "[HIGH] Disable Mozilla Firefox Telemetry";
}
public override string Info()
{
return "This policy may lead to the following behavior in Firefox Browser:\r\nManaged by your organization, your browser is managed." +
"\r\nThe changes can be reverted at any time.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "DisableTelemetry", desiredValue) &&
RegistryHelper.IntEquals(keyName, "DisableDefaultBrowserAgent", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "DisableTelemetry", desiredValue, RegistryValueKind.DWord);
Registry.SetValue(keyName, "DisableDefaultBrowserAgent", desiredValue, RegistryValueKind.DWord);
logger.Log("- Mozilla Firefox Telemetry has been disabled.");
logger.Log(keyName);
return true;
}
catch
{ }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.LocalMachine.DeleteSubKeyTree(@"Policies\Mozilla\Firefox", false);
logger.Log("+ Mozilla Firefox Telemetry has been enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,63 @@
using Bloatynosy;
using Microsoft.Win32;
namespace Features.Feature.Desktop
{
internal class AppsTheme : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Themes\Personalize";
private const int desiredValue = 0;
public override string ID()
{
return "[LOW] Use Apps dark theme";
}
public override string Info()
{
return "";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "AppsUseLightTheme", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "AppsUseLightTheme", desiredValue, RegistryValueKind.DWord);
logger.Log("- Apps dark theme has been successfully enabled.");
logger.Log(keyName);
logger.Log("\n\nDark theme will also be enabled for Bloatynosy.\nPlease restart the app for the changes to take effect.");
return true;
}
catch
{ }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "AppsUseLightTheme", "1", RegistryValueKind.DWord);
logger.Log("+ Apps light theme has been successfully enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,61 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Desktop
{
internal class SnapAssistFlyout : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced";
private const int desiredValue = 0;
public override string ID()
{
return "[LOW] Disable Snap Assist";
}
public override string Info()
{
return "When you hover over the maximize button in apps, this feature gives you a flyout to display possible layouts.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "EnableSnapAssistFlyout", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "EnableSnapAssistFlyout", desiredValue, RegistryValueKind.DWord);
logger.Log("- Snap Assist Layout has been disabled.\nPlease restart your PC for the changes to take effect.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable Snap Assist {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "EnableSnapAssistFlyout", 1, RegistryValueKind.DWord);
logger.Log("+ Snap Assist has been enabled.\nPlease restart your PC for the changes to take effect.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,60 @@
using Bloatynosy;
using Microsoft.Win32;
namespace Features.Feature.Desktop
{
internal class Stickers : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\PolicyManager\current\device\Stickers";
private const int desiredValue = 0;
public override string ID()
{
return "[HIGH] Remove Desktop Stickers";
}
public override string Info()
{
return "";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "EnableStickers", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "EnableStickers", desiredValue, RegistryValueKind.DWord);
logger.Log("- Desktop Stickers has been removed.");
logger.Log(keyName);
return true;
}
catch
{ }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "EnableStickers", "1", RegistryValueKind.DWord);
logger.Log("+ Desktop Sticker feature has been enabled again.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,61 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Desktop
{
internal class Transparency : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Themes\Personalize";
private const int desiredValue = 0;
public override string ID()
{
return "[LOW] Disable acrylic Fluent Design effects";
}
public override string Info()
{
return "";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "EnableTransparency", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "EnableTransparency", desiredValue, RegistryValueKind.DWord);
logger.Log("- Transparency effects has been disabled.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable transparency effects {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "EnableTransparency", 1, RegistryValueKind.DWord);
logger.Log("+ Transparency effects has been enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,61 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Desktop
{
internal class Widgets : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced";
private const int desiredValue = 0;
public override string ID()
{
return "[MIDDLE] Disable Widgets";
}
public override string Info()
{
return "";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "TaskbarDa", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "TaskbarDa", desiredValue, RegistryValueKind.DWord);
logger.Log("- Widgets has been disabled.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable Widgets {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "TaskbarDa", 1, RegistryValueKind.DWord);
logger.Log("+ Widgets has been enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,71 @@
using Bloatynosy;
using System;
using System.Diagnostics;
using System.IO;
using System.Net;
namespace Features.Feature.Desktop
{
internal class WidgetsRemove : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
public override string ID()
{
return "[MIDDLE] Uninstall Widgets feature";
}
public override string Info()
{
return "The Widgets app runs in the background even with the option turned off.\nThis will uninstall the Widgets app package.";
}
public override bool CheckFeature()
{
var appPath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData), "Packages", "MicrosoftWindows.Client.WebExperience_cw5n1h2txyewy");
if (!Directory.Exists(appPath))
{
return false;
}
return true;
}
public override bool DoFeature()
{
try
{
using (var client = new WebClient())
{
logger.Log("- Uninstalling Widgets app");
WindowsHelper.RunWT("winget uninstall \"windows web experience pack\" --silent");
logger.Log("Done.");
return true;
}
}
catch (Exception ex)
{ logger.Log("{0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
using (var client = new WebClient())
{
logger.Log("+ Installing Widgets app...\nWe've opened the download link in the Microsoft Store.\nPlease install the package \"Windows Web Experience Pack\". ");
Process.Start("ms-windows-store://pdp/?ProductId=9MSSGKG348SP");
return true;
}
}
catch (Exception ex)
{ logger.Log("{0}", ex.Message); }
return false;
}
}
}

View File

@ -0,0 +1,60 @@
using Bloatynosy;
using Microsoft.Win32;
namespace Features.Feature.Desktop
{
internal class WindowsTheme : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Themes\Personalize";
private const int desiredValue = 0;
public override string ID()
{
return "[LOW] Use Windows dark theme";
}
public override string Info()
{
return "";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "SystemUsesLightTheme", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "SystemUsesLightTheme", desiredValue, RegistryValueKind.DWord);
logger.Log("- Windows dark theme has been successfully enabled.");
logger.Log(keyName);
return true;
}
catch
{ }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "SystemUsesLightTheme", "1", RegistryValueKind.DWord);
logger.Log("+ Windows light theme has been successfully enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,61 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Explorer
{
internal class HiddenFileExt : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced";
private const int desiredValue = 0;
public override string ID()
{
return "[HIGH] Show hidden file name extensions";
}
public override string Info()
{
return "";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "HideFileExt", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "HideFileExt", desiredValue, RegistryValueKind.DWord);
logger.Log("- File name extensions are now visible.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not hide file name extensions {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "HideFileExt", 1, RegistryValueKind.DWord);
logger.Log("+ File name extensions are now hidden again.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,61 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Explorer
{
internal class HiddenFileFolder : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced";
private const int desiredValue = 1;
public override string ID()
{
return "[HIGH] Show hidden files, folders and drives in File Explorer";
}
public override string Info()
{
return "";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "Hidden", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "Hidden", desiredValue, RegistryValueKind.DWord);
logger.Log("- Hidden files, folders and drives are now visible.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not hide files, folders and drives {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "Hidden", 2, RegistryValueKind.DWord);
logger.Log("+ Files, folders and drives are now hidden again.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,74 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Gaming
{
internal class GameDVR : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\System\GameConfigStore";
private const string keyName2 = @"HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\PolicyManager\default\ApplicationManagement\AllowGameDVR";
private const int desiredValue = 0;
private const int desiredValue2 = 2;
private const int desiredValue3 = 0;
public override string ID()
{
return "[MIDDLE] Disable Game DVR feature";
}
public override string Info()
{
return "The built-in Game DVR feature helps you record your gameplay, capture screenshots, and share them online.\n" +
"But it can interfere with your games performance, too. Background recording requires some of your GPU power, and some gamers will want all the GPU power they can get.\n" +
"If you experience low FPS or FPS loss after upgrading to Windows 11, you may resolve the issue by disabling the Xbox DVR feature.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "GameDVR_Enabled", desiredValue) &&
RegistryHelper.IntEquals(keyName, "GameDVR_FSEBehaviorMode", desiredValue2) &&
RegistryHelper.IntEquals(keyName2, "value", desiredValue3)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "GameDVR_Enabled", desiredValue, RegistryValueKind.DWord);
Registry.SetValue(keyName, "GameDVR_FSEBehaviorMode", desiredValue2, RegistryValueKind.DWord);
Registry.SetValue(keyName2, "value", desiredValue3, RegistryValueKind.DWord);
logger.Log("- Game DVR feature has been successfully disabled.");
logger.Log(keyName + Environment.NewLine + keyName2);
return true;
}
catch
{ }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "GameDVR_Enabled", "1", RegistryValueKind.DWord);
Registry.SetValue(keyName, "GameDVR_FSEBehaviorMode", "0", RegistryValueKind.DWord);
Registry.SetValue(keyName2, "value", 1, RegistryValueKind.DWord);
logger.Log("+ Game DVR feature has been successfully enabled.");
logger.Log(keyName + Environment.NewLine + keyName2);
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,65 @@
using Bloatynosy;
using Microsoft.Win32;
namespace Features.Feature.Gaming
{
internal class PowerThrottling : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Power\PowerThrottling";
private const int desiredValue = 1;
public override string ID()
{
return "[MIDDLE] Disable PowerThrottling";
}
public override string Info()
{
return "With the Windows 10 Fall Creators Update, Microsofts OS has added feature called Power Throttling\n" +
"(Power Throttling is only available on Intel 6th gen and higher processors), a way to increase the battery life of laptops by slowing down background processes.\n" +
"This feature is enabled by default in laptops and tablets. Though Windows is good at detecting background apps and limiting power, there might be situations where this feature is not so desirable.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "PowerThrottlingOff", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "PowerThrottlingOff", desiredValue, RegistryValueKind.DWord);
logger.Log("- PowerThrottling has been successfully disabled.");
logger.Log(keyName);
return true;
}
catch
{ }
return false;
}
public override bool UndoFeature()
{
try
{
var RegKey = Registry.LocalMachine.OpenSubKey(@"SYSTEM\CurrentControlSet\Control\Power\PowerThrottling", true);
RegKey.DeleteValue("PowerThrottlingOff");
logger.Log("+ PowerThrottling has been successfully enabled.");
logger.Log(keyName);
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,64 @@
using Bloatynosy;
using Microsoft.Win32;
namespace Features.Feature.Gaming
{
internal class VisualFX : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\VisualEffects";
private const int desiredValue = 2;
public override string ID()
{
return "[MIDDLE] Adjust visual effects for best performance";
}
public override string Info()
{
return "Visual effects are the visual bells and whistles for the appearance of Windows for your account.\n" +
"These visual bells and whistles can affect the performance of Windows on the PC though.\n" +
"This will turn off all visual effects under My computer->Properties->Advanced->Settings->and set to \"Adjust for best performance\"";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "VisualFXSetting", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "VisualFXSetting", desiredValue, RegistryValueKind.DWord);
logger.Log("- Visual effects has been optimized.");
logger.Log(keyName);
return true;
}
catch
{ }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "VisualFXSetting", 0, RegistryValueKind.DWord);
logger.Log("+ Visual effects has been set to default choosing Windows what's best for your computer.");
logger.Log(keyName);
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,61 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Privacy
{
internal class Advertising : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\AdvertisingInfo";
private const int desiredValue = 0;
public override string ID()
{
return "[HIGH] Disable Advertising ID for Relevant Ads";
}
public override string Info()
{
return "Windows 11 comes integrated with advertising. Microsoft assigns a unique identificator to track your activity in the Microsoft Store and on UWP apps to target you with relevant ads.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "Enabled", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "Enabled", desiredValue, RegistryValueKind.DWord);
logger.Log("- Advertising ID for Relevant Ads has been successfully disabled.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable advertising ID for Relevant Ads {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "Enabled", 1, RegistryValueKind.DWord);
logger.Log("+ Advertising ID for Relevant Ads has been successfully enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,62 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Privacy
{
internal class AppsAutoInstall : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager";
private const int desiredValue = 0;
public override string ID()
{
return "[HIGH] Disable Automatic Installation of apps";
}
public override string Info()
{
return "When you sign-in to a new Windows 11 profile or device for the first time, chance is that you notice several third - party applications and games listed prominently in the Start menu.\n" +
"This setting will block automatic Installation of suggested Windows 11 apps.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "SilentInstalledAppsEnabled", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "SilentInstalledAppsEnabled", desiredValue, RegistryValueKind.DWord);
logger.Log("- Automatic Installation of apps has been successfully disabled.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable automatic Installation of apps {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "SilentInstalledAppsEnabled", 1, RegistryValueKind.DWord);
logger.Log("+ Automatic Installation of apps has been successfully enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,61 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Privacy
{
internal class BackgroundApps : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\BackgroundAccessApplications";
private const int desiredValue = 1;
public override string ID()
{
return "[HIGH] Disable Apps running in background";
}
public override string Info()
{
return "";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "GlobalUserDisabled", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "GlobalUserDisabled", desiredValue, RegistryValueKind.DWord);
logger.Log("- App access to running in background has been successfully disabled.");
logger.Log(keyName);
return true;
}
catch
{ }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "GlobalUserDisabled", 0, RegistryValueKind.DWord);
logger.Log("- App access to running in background has been successfully enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,62 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Privacy
{
internal class CompatibilityTelemetry : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\CompatTelRunner.exe";
private const string desiredValue = @"%windir%\System32\taskkill.exe";
public override string ID()
{
return "[HIGH] Disable Compatibility Telemetry";
}
public override string Info()
{
return "This process is periodically collecting a variety of technical data about your computer and its performance and sending it to Microsoft for its Windows Customer Experience Improvement Program.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.StringEquals(keyName, "Debugger", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "Debugger", desiredValue, RegistryValueKind.String);
logger.Log("- Compatibility Telemetry has been successfully disabled.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable compatibility telemetry: {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
var RegKey = Registry.LocalMachine.OpenSubKey(@"Software\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\CompatTelRunner.exe", true);
RegKey.DeleteValue("Debugger");
logger.Log("+ Compatibility Telemetry has been successfully enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,61 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Privacy
{
internal class DiagnosticData : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Privacy";
private const int desiredValue = 0;
public override string ID()
{
return "[HIGH] Disable Diagnostic data";
}
public override string Info()
{
return "This will turn off tailored experiences with relevant tips and recommendations by using your diagnostics data. Many people would call this telemetry, or even spying.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "TailoredExperiencesWithDiagnosticDataEnabled", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "TailoredExperiencesWithDiagnosticDataEnabled", desiredValue, RegistryValueKind.DWord);
logger.Log("- Diagnostic data has been successfully disabled.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable Diagnostic data {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "TailoredExperiencesWithDiagnosticDataEnabled", 1, RegistryValueKind.DWord);
logger.Log("+ Diagnostic data has been successfully enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,67 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Privacy
{
internal class Feedback : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string periodInNanoSeconds = @"HKEY_CURRENT_USER\Software\Microsoft\Siuf\Rules";
private const string numberOfSIUFInPeriod = @"HKEY_CURRENT_USER\Software\Microsoft\Siuf\Rules";
private const int desiredValue = 0;
public override string ID()
{
return "[HIGH] Disable Feedback notifications";
}
public override string Info()
{
return "Changes the Windows 11 feedback frequency from Automatically to Never.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(periodInNanoSeconds, "PeriodInNanoSeconds", desiredValue) &&
RegistryHelper.IntEquals(numberOfSIUFInPeriod, "NumberOfSIUFInPeriod", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(periodInNanoSeconds, "PeriodInNanoSeconds", desiredValue, RegistryValueKind.DWord);
Registry.SetValue(numberOfSIUFInPeriod, "NumberOfSIUFInPeriod", desiredValue, RegistryValueKind.DWord);
logger.Log("- Feedback has been successfully disabled.");
logger.Log(periodInNanoSeconds + Environment.NewLine + numberOfSIUFInPeriod);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable Feedback {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
var RegKey = Registry.CurrentUser.OpenSubKey(@"Software\Microsoft\Siuf\Rules", true);
RegKey.DeleteValue("NumberOfSIUFInPeriod");
RegKey.DeleteValue("PeriodInNanoSeconds");
logger.Log("+ Feedback has been successfully enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,61 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Privacy
{
internal class LocationTracking : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\location";
private const string desiredValue = @"Deny";
public override string ID()
{
return "[HIGH] Disable Location tracking";
}
public override string Info()
{
return "Wherever you go, Windows 11 knows you're there. When Location Tracking is turned on, Windows and its apps are allowed to detect the current location of your computer or device.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.StringEquals(keyName, "Value", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "Value", desiredValue, RegistryValueKind.String);
logger.Log("- Location tracking has been successfully disabled.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable location tracking {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "Value", "Allow", RegistryValueKind.String);
logger.Log("+ Location tracking info has been successfully enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,71 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Privacy
{
internal class SuggestedContent : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager";
private const string keyName2 = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager";
private const string keyName3 = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager";
private const int desiredValue = 0;
public override string ID()
{
return "[HIGH] Disable Suggested content in Settings app";
}
public override string Info()
{
return "";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "SubscribedContent-338393Enabled", desiredValue) &&
RegistryHelper.IntEquals(keyName2, "SubscribedContent-353694Enabled", desiredValue) &&
RegistryHelper.IntEquals(keyName3, "SubscribedContent-353696Enabled", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "SubscribedContent-338393Enabled", desiredValue, RegistryValueKind.DWord);
Registry.SetValue(keyName2, "SubscribedContent-353694Enabled", desiredValue, RegistryValueKind.DWord);
Registry.SetValue(keyName3, "SubscribedContent-353696Enabled", desiredValue, RegistryValueKind.DWord);
logger.Log("- Suggested content in Settings app has been successfully disabled.");
logger.Log(keyName + Environment.NewLine + keyName2 + Environment.NewLine + keyName3);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable suggested content in Settings app {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "SubscribedContent-338393Enabled", 1, RegistryValueKind.DWord);
Registry.SetValue(keyName2, "SubscribedContent-353694Enabled", 1, RegistryValueKind.DWord);
Registry.SetValue(keyName3, "SubscribedContent-353696Enabled", 1, RegistryValueKind.DWord);
logger.Log("+ Suggested content in Settings app has been successfully enabled.");
logger.Log(keyName + Environment.NewLine + keyName2 + Environment.NewLine + keyName3);
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,61 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Privacy
{
internal class TailoredExperiences : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Privacy";
private const int desiredValue = 0;
public override string ID()
{
return "[HIGH] Disable Tailored experiences";
}
public override string Info()
{
return "This will prevent Windows 11 using your diagnostic data for personalized tips, ads, and recommendations.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "TailoredExperiencesWithDiagnosticDataEnabled", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "TailoredExperiencesWithDiagnosticDataEnabled", desiredValue, RegistryValueKind.DWord);
logger.Log("- Tailored experiences has been successfully disabled.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable Tailored experiences {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "TailoredExperiencesWithDiagnosticDataEnabled", 1, RegistryValueKind.DWord);
logger.Log("+ Tailored experiences has been successfully enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,83 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Privacy
{
internal class Telemetry : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string dataCollection = @"HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\DataCollection";
private const string diagTrack = @"HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\DiagTrack";
private const string dmwappushservice = @"HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\dmwappushservice";
private const int desiredValue = 0;
public override string ID()
{
return "[MIDDLE] Disable Connected User Experiences and Telemetry";
}
public override string Info()
{
return "This will prevent Windows from collecting usage information and setting diagnostic data to Basic, which is the lowest level available for all consumer versions of Windows 11.\n" +
"The services diagtrack & dmwappushservice will also be disabled.\nNOTE: Diagnostic Data must be set to Full to get preview builds from Windows-Insider-Program!";
}
public override bool CheckFeature()
{
// WindowsHelper.IsServiceRunning("DiagTrack");
// WindowsHelper.IsServiceRunning("dmwappushservice");
return !(
RegistryHelper.IntEquals(dataCollection, "AllowTelemetry", desiredValue) &&
RegistryHelper.IntEquals(diagTrack, "Start", 4) &&
RegistryHelper.IntEquals(dmwappushservice, "Start", 4)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(dataCollection, "AllowTelemetry", desiredValue, RegistryValueKind.DWord);
Registry.SetValue(diagTrack, "Start", 4, RegistryValueKind.DWord);
Registry.SetValue(dmwappushservice, "Start", 4, RegistryValueKind.DWord);
WindowsHelper.DisableService("DiagTrack");
WindowsHelper.DisableService("dmwappushservice");
logger.Log("- Connected User Experiences and Telemetry has been successfully disabled.");
logger.Log(dataCollection + Environment.NewLine + diagTrack + Environment.NewLine + dmwappushservice);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable telemetry: {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(dataCollection, "AllowTelemetry", 3, RegistryValueKind.DWord);
Registry.SetValue(diagTrack, "Start", 2, RegistryValueKind.DWord);
Registry.SetValue(dmwappushservice, "Start", 2, RegistryValueKind.DWord);
WindowsHelper.EnableService("DiagTrack");
WindowsHelper.EnableService("dmwappushservice");
logger.Log("+ Connected User Experiences and Telemetry has been successfully enabled.");
logger.Log(dataCollection + Environment.NewLine + diagTrack + Environment.NewLine + dmwappushservice);
return true;
}
catch (Exception ex)
{ logger.Log("Could not enable telemetry: {0}", ex.Message); }
return false;
}
}
}

View File

@ -0,0 +1,61 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Privacy
{
internal class WindowsTips : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager";
private const int desiredValue = 0;
public override string ID()
{
return "[LOW] Disable Windows tips";
}
public override string Info()
{
return "You will no longer see Windows tips, e.g. Spotlight and Consumer Features, Feedback Notifications etc.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "SubscribedContent-338393Enabled", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "SubscribedContent-338393Enabled", desiredValue, RegistryValueKind.DWord);
logger.Log("- Windows 11 tips has been successfully disabled.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable Windows 11 tips {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "SubscribedContent-338393Enabled", 1, RegistryValueKind.DWord);
logger.Log("+ Windows 11 tips has been successfully enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,51 @@
using Bloatynosy;
using System.Management.Automation;
namespace Features.Feature.System
{
internal class Fax : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
public override string ID()
{
return "[LOW] Remove Fax Printer";
}
public override string Info()
{
return "This operation cannot be undone!";
}
public override bool CheckFeature()
{
logger.Log("Problem on System: [UNKNOWN] Fax Printer check can not be performed, but we can remove it.");
return false;
}
public override bool DoFeature()
{
string script = "Remove-Printer -Name \"Fax\"";
PowerShell powerShell = PowerShell.Create();
powerShell.AddScript(script);
powerShell.Invoke();
if (powerShell.Streams.Error.Count > 0)
{
logger.Log("Fax Printer not found.");
return false;
}
logger.Log("- Fax printer has been successfully removed.");
return true;
}
public override bool UndoFeature()
{
logger.Log("= Fax printer can not be installed.");
return false;
}
}
}

View File

@ -0,0 +1,60 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.System
{
internal class FullContextMenus : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\SOFTWARE\CLASSES\CLSID\{86ca1aa0-34aa-4e8b-a509-50c905bae2a2}\InprocServer32";
public override string ID()
{
return "[MIDDLE] Enable Full Context Menus in Windows 11";
}
public override string Info()
{
return "Truncated context menus are Windows 11's worst feature.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.StringEquals(keyName, "", "")
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "", "", RegistryValueKind.String);
logger.Log("- Full Context Menus in Windows 11 have been enabled.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not enable Full Context Menus in Windows 11 {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.CurrentUser.DeleteSubKeyTree(@"Software\Classes\CLSID\{86ca1aa0-34aa-4e8b-a509-50c905bae2a2}", false);
logger.Log("+ Truncated context menus has been enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,63 @@
using Bloatynosy;
using Microsoft.Win32;
namespace Features.Feature.System
{
internal class RemoveW11Watermark : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Control Panel\UnsupportedHardwareNotificationCache";
private const int desiredValue = 0;
public override string ID()
{
return "[LOW] Remove Windows 11 System requirements watermark";
}
public override string Info()
{
return "Microsoft will display with Build 2257 a desktop watermark on devices where Windows 11 is running on unsupported hardware.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "SV2", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "SV2", desiredValue, RegistryValueKind.DWord);
logger.Log("- Watermark and the settings notification should be gone.");
logger.Log(keyName);
return true;
}
catch
{ }
return false;
}
public override bool UndoFeature()
{
try
{
var RegKey = Registry.CurrentUser.OpenSubKey(@"Control Panel\UnsupportedHardwareNotificationCache", true);
RegKey.DeleteValue("SV2");
logger.Log("+ Watermark has been enabled again.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,79 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.System
{
internal class TPMCheck : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_LOCAL_MACHINE\SYSTEM\Setup\LabConfig";
private const string keyName2 = @"HKEY_LOCAL_MACHINE\SYSTEM\Setup\MoSetup";
private const int desiredValue = 1;
public override string ID()
{
return "[LOW] Disable TPM 2.0 Check";
}
public override string Info()
{
return "";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "BypassCPUCheck", desiredValue) &&
RegistryHelper.IntEquals(keyName, "BypassStorageCheck", desiredValue) &&
RegistryHelper.IntEquals(keyName, "BypassTPMCheck", desiredValue) &&
RegistryHelper.IntEquals(keyName, "BypassRAMCheck", desiredValue) &&
RegistryHelper.IntEquals(keyName, "BypassSecureBootCheck", desiredValue) &&
RegistryHelper.IntEquals(keyName2, "AllowUpgradesWithUnsupportedTPMOrCPU", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "BypassCPUCheck", desiredValue, RegistryValueKind.DWord);
Registry.SetValue(keyName, "BypassStorageCheck", desiredValue, RegistryValueKind.DWord);
Registry.SetValue(keyName, "BypassTPMCheck", desiredValue, RegistryValueKind.DWord);
Registry.SetValue(keyName, "BypassRAMCheck", desiredValue, RegistryValueKind.DWord);
Registry.SetValue(keyName, "BypassSecureBootCheck", desiredValue, RegistryValueKind.DWord);
Registry.SetValue(keyName2, "AllowUpgradesWithUnsupportedTPMOrCPU", desiredValue, RegistryValueKind.DWord);
logger.Log("- TPM 2.0 Check has been successfully disabled.");
logger.Log(keyName);
logger.Log(keyName2);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable TPM 2.0 Check {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.LocalMachine.OpenSubKey(@"SYSTEM\Setup\LabConfig", true).DeleteValue("BypassTPMCheck", false);
Registry.LocalMachine.OpenSubKey(@"SYSTEM\Setup\LabConfig", true).DeleteValue("BypassRAMCheck", false);
Registry.LocalMachine.OpenSubKey(@"SYSTEM\Setup\LabConfig", true).DeleteValue("BypassSecureBootCheck", false);
Registry.LocalMachine.OpenSubKey(@"SYSTEM\Setup\LabConfig", true).DeleteValue("BypassStorageCheck", false);
Registry.LocalMachine.OpenSubKey(@"SYSTEM\Setup\LabConfig", true).DeleteValue("BypassCPUCheck", false);
Registry.SetValue(@"HKEY_LOCAL_MACHINE\SYSTEM\Setup\MoSetup", "AllowUpgradesWithUnsupportedTPMOrCPU", "0", RegistryValueKind.DWord);
logger.Log("+ TPM 2.0 Check has been enabled again.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,72 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.System
{
internal class TeamsAutostart : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Run";
private string desiredValue = string.Format("C:\\Users\\{0}\\AppData\\Local\\Microsoft\\Teams\\Update.exe --processStart \"Teams.exe\" --process-start-args \"--system-initiated", Environment.UserName);
public override string ID()
{
return "[LOW] Disable Microsoft Teams on Startup";
}
public override string Info()
{
return "";
}
public override bool CheckFeature()
{
string AppValue = "com.squirrel.Teams.Teams";
if (Registry.GetValue(keyName, AppValue, null) == null)
{
logger.Log("Problem on System: [SOLVED] Teams AutoStart is already disabled.");
return false;
}
else
{
// logger.Log("Teams AutoStart is enabled.");
return true;
}
}
public override bool DoFeature()
{
try
{
var RegKey = Registry.CurrentUser.OpenSubKey(@"Software\Microsoft\Windows\CurrentVersion\Run", true);
RegKey.DeleteValue("com.squirrel.Teams.Teams");
logger.Log("- Teams AutoStart has been disabled.");
return true;
}
catch
{ }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "com.squirrel.Teams.Teams", desiredValue, RegistryValueKind.String);
logger.Log("+ Teams AutoStart has been enabled again.");
logger.Log(keyName);
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,78 @@
using Bloatynosy;
using System.Management.Automation;
namespace Features.Feature.System
{
internal class XPSWriter : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
public override string ID()
{
return "[LOW] Remove XPS Documents Writer";
}
public override string Info()
{
return "";
}
public override bool CheckFeature()
{
string script = "Get-WindowsOptionalFeature -Online -FeatureName \"Printing-XPSServices-Features\"";
PowerShell powerShell = PowerShell.Create();
powerShell.AddScript(script);
var results = powerShell.Invoke();
foreach (var item in results)
{
var Status = item.Members["State"].Value;
if (Status.ToString() == "Enabled")
{
// logger.Log("XPS Documents Writer is installed.");
return true;
}
}
//logger.Log("XPS Documents Writer not found.");
return false;
}
public override bool DoFeature()
{
string script = "Disable-WindowsOptionalFeature -Online -FeatureName \"Printing-XPSServices-Features\" -NoRestart -WarningAction SilentlyContinue | Out-Null";
PowerShell powerShell = PowerShell.Create();
powerShell.AddScript(script);
var results = powerShell.Invoke();
if (powerShell.Streams.Error.Count > 0)
{
logger.Log("= XPS Documents Writer not found.");
return false;
}
logger.Log("- XPS Documents Writer has been successfully removed.");
return true;
}
public override bool UndoFeature()
{
string script = "Enable-WindowsOptionalFeature -Online -FeatureName \"Printing-XPSServices-Features\" -NoRestart -WarningAction SilentlyContinue | Out-Null";
PowerShell powerShell = PowerShell.Create();
powerShell.AddScript(script);
var results = powerShell.Invoke();
if (powerShell.Streams.Error.Count > 0)
{
logger.Log("- XPS Documents Writer could not be installed.");
return false;
}
logger.Log("+ XPS Documents Writer has been successfully installed.");
return true;
}
}
}

View File

@ -0,0 +1,77 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Taskbar
{
internal class Copilot: FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string showCopilotButton = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced";
private const string turnOffWindowsCopilotU = @"HKEY_CURRENT_USER\Software\Policies\Microsoft\Windows\WindowsCopilot";
private const string turnOffWindowsCopilotM = @"HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\WindowsCopilot";
private const int desiredValue = 1;
public override string ID()
{
return "[MIDDLE] Disable Windows Copilot";
}
public override string Info()
{
return "Copilot in Windows is an artificial intelligence assistant that's integrated in Windows 11 to enhance productivity and creativity.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(showCopilotButton, "ShowCopilotButton", 0) &&
RegistryHelper.IntEquals(turnOffWindowsCopilotU, "TurnOffWindowsCopilot", desiredValue) &&
RegistryHelper.IntEquals(turnOffWindowsCopilotM, "TurnOffWindowsCopilot", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(showCopilotButton, "ShowCopilotButton", 0, RegistryValueKind.DWord);
Registry.SetValue(turnOffWindowsCopilotU, "TurnOffWindowsCopilot", desiredValue, RegistryValueKind.DWord);
Registry.SetValue(turnOffWindowsCopilotM, "TurnOffWindowsCopilot", desiredValue, RegistryValueKind.DWord);
logger.Log("- Copilot has been successfully disabled.");
logger.Log(showCopilotButton + Environment.NewLine + turnOffWindowsCopilotU + Environment.NewLine + turnOffWindowsCopilotM);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable Copilot {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
var RegKey = Registry.CurrentUser.OpenSubKey(@"Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced", true);
RegKey.DeleteValue("ShowCopilotButton");
var RegKeyU = Registry.CurrentUser.OpenSubKey(@"Software\Policies\Microsoft\Windows\WindowsCopilot", true);
RegKeyU.DeleteValue("TurnOffWindowsCopilot");
var RegKeyM = Registry.LocalMachine.OpenSubKey(@"Software\Policies\Microsoft\Windows\WindowsCopilot", true);
RegKeyM.DeleteValue("TurnOffWindowsCopilot");
logger.Log("+ Copilot has been successfully enabled.");
return true;
}
catch (Exception ex)
{ logger.Log("Could not enable Copilot {0}", ex.Message); }
return false;
}
}
}

View File

@ -0,0 +1,63 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Taskbar
{
internal class MostUsedApps : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\Explorer";
private const int desiredValue = 2;
public override string ID()
{
return "[LOW] Hide most used apps in start menu";
}
public override string Info()
{
return "";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "ShowOrHideMostUsedApps", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "ShowOrHideMostUsedApps", desiredValue, RegistryValueKind.DWord);
logger.Log("- Most Used Apps has been disabled.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable Most Used Apps {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
var RegKey = Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Policies\Microsoft\Windows\Explorer", true);
RegKey.DeleteValue("ShowOrHideMostUsedApps");
logger.Log("+ Most Used Apps has been set to default behavior.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,61 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Taskbar
{
internal class StartmenuLayout : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced";
private const int desiredValue = 1;
public override string ID()
{
return "[MIDDLE] Pin more Apps on Start menu";
}
public override string Info()
{
return "This option is ONLY available in preview versions of Windows 11 Build 22509 or newer.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "Start_Layout", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "Start_Layout", desiredValue, RegistryValueKind.DWord);
logger.Log("- Start menu layout is now showing more Pins.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not enable more Pins on Start menu.{0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "Start_Layout", 0, RegistryValueKind.DWord);
logger.Log("+ Showing more Pins on Start menu has been enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,61 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Taskbar
{
internal class StartmenuSearch : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Policies\Microsoft\Windows\Explorer";
private const int desiredValue = 1;
public override string ID()
{
return "[HIGH] Disable start menu Bing search";
}
public override string Info()
{
return "This will disable web search recommendations from the start menu search bar.\nThere is no need for web search results there. That search should return local files and applications.";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "DisableSearchBoxSuggestions", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "DisableSearchBoxSuggestions", desiredValue, RegistryValueKind.DWord);
logger.Log("- Start menu Bing search has been disabled.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable start menu Bing search {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "DisableSearchBoxSuggestions", 0, RegistryValueKind.DWord);
logger.Log("+ Start menu Bing search has been enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,61 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Taskbar
{
internal class TaskView : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced";
private const int desiredValue = 0;
public override string ID()
{
return "[LOW] Hide Task view button on taskbar";
}
public override string Info()
{
return "";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "ShowTaskViewButton", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "ShowTaskViewButton", desiredValue, RegistryValueKind.DWord);
logger.Log("- Task view button has been disabled.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable Task view button {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "ShowTaskViewButton", 1, RegistryValueKind.DWord);
logger.Log("+ Task view button has been enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,61 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Taskbar
{
internal class TaskbarChat : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced";
private const int desiredValue = 0;
public override string ID()
{
return "[LOW] Hide Chat icon (Microsoft Teams) on taskbar";
}
public override string Info()
{
return "";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "TaskbarMn", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "TaskbarMn", desiredValue, RegistryValueKind.DWord);
logger.Log("- Chat icon has been disabled.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable chat icon {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "TaskbarMn", 1, RegistryValueKind.DWord);
logger.Log("+ Chat icon has been enabled.");
return true;
}
catch
{ }
return false;
}
}
}

View File

@ -0,0 +1,61 @@
using Bloatynosy;
using Microsoft.Win32;
using System;
namespace Features.Feature.Taskbar
{
internal class TaskbarSearch : FeatureBase
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private const string keyName = @"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Search";
private const int desiredValue = 0;
public override string ID()
{
return "[LOW] Hide Search icon on taskbar";
}
public override string Info()
{
return "";
}
public override bool CheckFeature()
{
return !(
RegistryHelper.IntEquals(keyName, "SearchboxTaskbarMode", desiredValue)
);
}
public override bool DoFeature()
{
try
{
Registry.SetValue(keyName, "SearchboxTaskbarMode", desiredValue, RegistryValueKind.DWord);
logger.Log("- Search icon has been disabled.");
logger.Log(keyName);
return true;
}
catch (Exception ex)
{ logger.Log("Could not disable search icon {0}", ex.Message); }
return false;
}
public override bool UndoFeature()
{
try
{
Registry.SetValue(keyName, "SearchboxTaskbarMode", 1, RegistryValueKind.DWord);
logger.Log("+ Search icon has been enabled.");
return true;
}
catch
{ }
return false;
}
}
}

62
src/Bloatynosy/Github.cs Normal file
View File

@ -0,0 +1,62 @@
using System;
using System.IO;
using System.Net.Http;
using System.Runtime.Serialization;
using System.Runtime.Serialization.Json;
using System.Threading.Tasks;
namespace Bloatynosy
{
internal class Stargazers
{
// Event to be subscribed on Mainform
public event EventHandler<int> StargazersCountFetched;
// Attributes to indicate that class is a data contract
[Serializable]
[DataContract]
public class GitHubRepository
{
[DataMember(Name = "stargazers_count")] // matches GitHub API response
public int StargazersCount { get; set; }
}
public async Task FetchStargazersAsync()
{
string repositoryOwner = "builtbybel";
string repositoryName = "Bloatynosy";
string apiUrl = $"https://api.github.com/repos/{repositoryOwner}/{repositoryName}";
try
{
using (HttpClient client = new HttpClient())
{
// Add an appropriate user agent header
client.DefaultRequestHeaders.Add("User-Agent", "Bloatynosy");
// Make GET request
Stream responseStream = await client.GetStreamAsync(apiUrl);
// Deserialize JSON using DataContractJsonSerializer
DataContractJsonSerializer serializer = new DataContractJsonSerializer(typeof(GitHubRepository));
GitHubRepository repoInfo = (GitHubRepository)serializer.ReadObject(responseStream);
// Extract and display stargazers count
int stargazersCount = repoInfo.StargazersCount;
// Notify subscribers (MainForm) about the fetched stargazers count
StargazersCountFetched?.Invoke(this, stargazersCount);
}
}
catch (Exception ex)
{
// Handle exception
Console.WriteLine($"{ex.Message}");
// Notify subscribers about exceptions
StargazersCountFetched?.Invoke(this, -1);
}
}
}
}

View File

@ -0,0 +1,58 @@
using System;
using System.Windows.Forms;
namespace Bloatynosy
{
internal class ErrorHelper
{
private static readonly ErrorHelper instance = new ErrorHelper();
private static RichTextBox target = null;
private ErrorHelper() { } // Private constructor to prevent external instantiation
// Errorlogger to target richLog
public void SetTarget(RichTextBox richText)
{
target = richText;
}
public void Log(string format, params object[] args)
{
format += "\r\n";
try
{
if (target.InvokeRequired)
{
target.Invoke(new Action(() => target.AppendText(string.Format(format, args))));
}
else
{
target.AppendText(string.Format(format, args));
}
}
catch { }
}
public void ClearLog()
{
try
{
if (target.InvokeRequired)
{
target.Invoke(new Action(() => target.Clear()));
}
else
{
target.Clear();
}
}
catch { }
}
public static ErrorHelper Instance
{
get => instance;
}
}
}

View File

@ -0,0 +1,136 @@
using Bloatynosy;
using System;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Net;
using System.Windows.Forms;
using static System.Net.WebRequestMethods;
namespace HelperTool
{
internal class Utils
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
public static readonly string TweetIntent = "https://twitter.com/intent/tweet?text=Try%20the%20new%20next%20Gen-Debloat%20App%20%23Bloatynosy%20for%20Windows%2011%0a%0ahttps://www.builtbybel.com/blog/about-debloos";
public static class Uri
{
public const string URL_ASSEMBLY = "https://raw.githubusercontent.com/builtbybel/Bloatynosy/main/src/Bloatynosy/Properties/AssemblyInfo.cs";
public const string URL_TWITTER = "https://twitter.com/builtbybel";
public const string URL_BUILTBYBEL = "https://www.builtbybel.com";
public const string URL_DONATE = "https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=donate@builtbybel.com&lc=US&item_name=%20Builtbybel&no_note=0&cn=&currency_code=USD&bn=PP-DonationsBF:btn_donateCC_LG.gif:NonHosted";
public const string URL_GITREPO = "https://github.com/builtbybel/Bloatynosy";
public const string URL_GITLATEST = URL_GITREPO + "/releases/latest";
public const string URL_HELP = "https://www.reddit.com/search/?q=bloatynosy&type=comment&sort=new";
}
public static class Paths
{
public static string SysDir = Path.GetPathRoot(Environment.SystemDirectory);
public static string LocalAppDataDir = Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData);
public static string ProgramFiles = Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles);
public static string ShellWT = LocalAppDataDir +
@"\Microsoft\WindowsApps\wt.exe";
public static string ShellCommandPrompt = SysDir +
@"Windows\System32\cmd.exe";
public static string ShellPS = SysDir +
@"Windows\System32\WindowsPowerShell\v1.0\powershell.exe";
}
public static class Data
{
public static string DataRootDir = Application.StartupPath +
@"\app\";
public static string PluginsRootDir = Application.StartupPath +
@"\plugins\";
}
// Create data directory if non present
public static void CreateDataDir()
{
bool dirExists = Directory.Exists(@"app");
if (!dirExists)
Directory.CreateDirectory(@"app");
}
// Launch Urls in richText control
public static void LaunchUri(string url)
{
if (IsHttpURL(url)) Process.Start(url);
}
// Check Urls in in richText control
public static bool IsHttpURL(string url)
{
return
((!string.IsNullOrWhiteSpace(url)) &&
(url.ToLower().StartsWith("http")));
}
public static void CheckForUpdates()
{
if (IsInet() == true)
{
try
{
string assemblyInfo = new WebClient().DownloadString(Utils.Uri.URL_ASSEMBLY);
var readVersion = assemblyInfo.Split('\n');
var infoVersion = readVersion.Where(t => t.Contains("[assembly: AssemblyFileVersion"));
var latestVersion = "";
foreach (var item in infoVersion)
{
latestVersion = item.Substring(item.IndexOf('(') + 2, item.LastIndexOf(')') - item.IndexOf('(') - 3);
}
if (latestVersion ==
Program.GetCurrentVersionTostring()) // Up-to-date
{
MessageBox.Show($"No new updates available.");
}
if (latestVersion != // Update available
Program.GetCurrentVersionTostring())
{
if (MessageBox.Show($"App version {latestVersion} available.\nDo you want to open the Download page?", "App update available", MessageBoxButtons.YesNo, MessageBoxIcon.Information, MessageBoxDefaultButton.Button1) == DialogResult.Yes)
Process.Start(HelperTool.Utils.Uri.URL_GITLATEST);
}
}
catch (Exception ex)
{
MessageBox.Show($"Checking for App updates failed.\n{ex.Message}");
}
}
else if (IsInet() == false)
{
MessageBox.Show($"Problem on Internet connection: Checking for App updates failed");
}
}
// Check Inet
public static bool IsInet()
{
try
{
using (var CheckInternet = new WebClient())
using (CheckInternet.OpenRead("http://clients3.google.com/generate_204"))
{
return true;
}
}
catch
{
return false;
}
}
}
}

View File

@ -0,0 +1,39 @@
using Microsoft.Win32;
using System;
using System.Windows.Forms;
namespace HelperTool
{
public static class OsHelper
{
public static readonly string thisOS = IsWin11() + "\x20" + GetVersion();
public static bool IsWin11()
{
try
{
RegistryKey key = Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Microsoft\Windows NT\CurrentVersion");
int osbuild = Convert.ToInt32(key.GetValue("CurrentBuildNumber"));
if (osbuild >= 21996)
{
return true;
}
}
catch (Exception ex)
{ MessageBox.Show(ex.Message); }
return false;
}
public static string GetVersion()
{
RegistryKey key = Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Microsoft\Windows NT\CurrentVersion");
var UBR = key.GetValue("UBR").ToString();
var CurrentBuild = key.GetValue("CurrentBuild").ToString();
string version = CurrentBuild + "." + UBR;
return "Build " + version;
}
}
}

View File

@ -0,0 +1,40 @@
using Microsoft.Win32;
using System;
using System.Windows.Forms;
namespace Bloatynosy
{
// Check whether registry values equal
internal class RegistryHelper
{
public static bool IntEquals(string keyName, string valueName, int expectedValue)
{
try
{
var value = Registry.GetValue(keyName, valueName, null);
return (value != null && (int)value == expectedValue);
}
catch (Exception ex)
{
MessageBox.Show(keyName, ex.Message, MessageBoxButtons.OK);
return false;
}
}
// Check whether registry strings equal
public static bool StringEquals(string keyName, string valueName, string expectedValue)
{
try
{
var value = Registry.GetValue(keyName, valueName, null);
return (value != null && (string)value == expectedValue);
}
catch (Exception ex)
{
MessageBox.Show(keyName, ex.Message, MessageBoxButtons.OK);
return false;
}
}
}
}

View File

@ -0,0 +1,34 @@
using Bloatynosy;
using Bloatynosy.Views;
using System.Linq;
using System.Windows.Forms;
namespace ViewHelper
{
public static class SwitchView
{
public static MainForm mainForm;
public static Control INavPage;
public static void SetView(Control View)
{
var control = View as Control;
control.Anchor = (AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right | AnchorStyles.Bottom);
control.Dock = DockStyle.Fill;
INavPage.Anchor = (AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right | AnchorStyles.Bottom);
INavPage.Dock = DockStyle.Fill;
mainForm.pnlForm.Controls.Clear();
mainForm.pnlForm.Controls.Add(View);
}
// Handle the back navigation
public static void SetMainFormAsView()
{
var mainForm = Application.OpenForms.OfType<MainForm>().Single();
mainForm.pnlForm.Controls.Clear();
if (INavPage != null) mainForm.pnlForm.Controls.Add(INavPage);
}
}
}

View File

@ -0,0 +1,103 @@
using System;
using System.Diagnostics;
using System.Globalization;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace Bloatynosy
{
public static class WindowsHelper
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
// Command Prompt (to be replaced with wt.exe)
public static void RunCmd(string args)
{
ProcStart(HelperTool.Utils.Paths.ShellCommandPrompt, args);
}
public static void RunWT(string args)
{
ProcStart(HelperTool.Utils.Paths.ShellWT, args);
}
public static void ProcStart(string name, string args)
{
try
{
var proc = new Process
{
StartInfo = new ProcessStartInfo
{
FileName = name,
Arguments = args,
UseShellExecute = false,
RedirectStandardOutput = true,
StandardOutputEncoding = Encoding.GetEncoding(CultureInfo.CurrentCulture.TextInfo.OEMCodePage),
CreateNoWindow = true
}
};
proc.Start();
string line = null;
while (!proc.StandardOutput.EndOfStream)
{
line += Environment.NewLine + proc.StandardOutput.ReadLine();
}
proc.WaitForExit();
logger.Log($"{name} {args} {line}");
}
catch
{
logger.Log($"Could not start {name} {args}.");
}
}
public static void IsServiceRunning(string service)
{
logger.Log($"\tCheck if {service} service is running");
RunCmd($"/c sc query {service} | find \"RUNNING\"");
}
public static void DisableService(string service)
{
RunCmd($"/c net stop {service}");
ProcStart(HelperTool.Utils.Paths.ShellPS, $"-command \"Set-Service -Name {service} -StartupType disabled\"");
logger.Log($"Disable {service} service");
}
public static void EnableService(string service)
{
RunCmd($"/c net start {service}");
ProcStart(HelperTool.Utils.Paths.ShellPS, $"-command \"Set-Service -Name {service} -StartupType auto\"");
logger.Log($"Enable {service} service");
}
public static async Task RunPowerShellScript(string scriptFilePath)
{
try
{
var startInfo = new ProcessStartInfo()
{
FileName = "powershell.exe",
UseShellExecute = false,
WindowStyle = ProcessWindowStyle.Normal,
Arguments = $"-executionpolicy bypass -file \"{scriptFilePath}\"",
CreateNoWindow = false, // Show the console window
};
using (var process = Process.Start(startInfo))
{
if (process != null)
{
await Task.Run(() => process.WaitForExit());
}
}
}
catch (Exception ex)
{
MessageBox.Show($"Error running PowerShell plugin: {ex.Message}", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
}
}

View File

@ -0,0 +1,25 @@
using System;
using System.Collections.Generic;
using System.Windows.Forms;
namespace Bloatynosy.ITreeNode
{
public static class ITreeNode
{
// Traverse tree and yields checked nodes
public static IEnumerable<TreeNode> All(this TreeNodeCollection nodes)
{
if (nodes == null) throw new ArgumentNullException(nameof(nodes));
foreach (TreeNode n in nodes)
{
yield return n;
foreach (TreeNode child in n.Nodes.All())
{
yield return child;
}
}
}
}
}

440
src/Bloatynosy/MainForm.Designer.cs generated Normal file
View File

@ -0,0 +1,440 @@
namespace Bloatynosy
{
partial class MainForm
{
/// <summary>
/// Erforderliche Designervariable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Verwendete Ressourcen bereinigen.
/// </summary>
/// <param name="disposing">True, wenn verwaltete Ressourcen gelöscht werden sollen; andernfalls False.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Vom Windows Form-Designer generierter Code
/// <summary>
/// Erforderliche Methode für die Designerunterstützung.
/// Der Inhalt der Methode darf nicht mit dem Code-Editor geändert werden.
/// </summary>
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
this.pnlMain = new System.Windows.Forms.Panel();
this.btnMenuChevronDown = new System.Windows.Forms.Button();
this.pnlNavRight = new System.Windows.Forms.Panel();
this.btnAppBloatpilot = new System.Windows.Forms.Button();
this.checkVersion = new System.Windows.Forms.CheckBox();
this.pnlRight = new System.Windows.Forms.Panel();
this.pnlRightSettings = new System.Windows.Forms.Panel();
this.label1 = new System.Windows.Forms.Label();
this.checkIgnoreLowIssues = new System.Windows.Forms.CheckBox();
this.lnkStargazers = new System.Windows.Forms.LinkLabel();
this.btnGithub = new System.Windows.Forms.Button();
this._lblAboutInfo = new System.Windows.Forms.Label();
this.lnkURLTwitter = new System.Windows.Forms.LinkLabel();
this.lnkURLReddit = new System.Windows.Forms.LinkLabel();
this.lnkURLDev = new System.Windows.Forms.LinkLabel();
this.lnkURLPayPal = new System.Windows.Forms.LinkLabel();
this.pnlForm = new System.Windows.Forms.Panel();
this.tt = new System.Windows.Forms.ToolTip(this.components);
this.contextMenuChevron = new System.Windows.Forms.ContextMenuStrip(this.components);
this.menuWizard = new System.Windows.Forms.ToolStripMenuItem();
this.menuWizardInfo = new System.Windows.Forms.ToolStripTextBox();
this.menuPackages = new System.Windows.Forms.ToolStripMenuItem();
this.menuPackagesInfo = new System.Windows.Forms.ToolStripTextBox();
this.pnlMain.SuspendLayout();
this.pnlNavRight.SuspendLayout();
this.pnlRight.SuspendLayout();
this.pnlRightSettings.SuspendLayout();
this.pnlForm.SuspendLayout();
this.contextMenuChevron.SuspendLayout();
this.SuspendLayout();
//
// pnlMain
//
this.pnlMain.AutoScroll = true;
this.pnlMain.Controls.Add(this.btnMenuChevronDown);
this.pnlMain.Controls.Add(this.pnlNavRight);
this.pnlMain.Dock = System.Windows.Forms.DockStyle.Fill;
this.pnlMain.Location = new System.Drawing.Point(0, 0);
this.pnlMain.Name = "pnlMain";
this.pnlMain.Size = new System.Drawing.Size(926, 720);
this.pnlMain.TabIndex = 0;
//
// btnMenuChevronDown
//
this.btnMenuChevronDown.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.btnMenuChevronDown.FlatAppearance.BorderSize = 0;
this.btnMenuChevronDown.Font = new System.Drawing.Font("Segoe UI Variable Display", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnMenuChevronDown.ForeColor = System.Drawing.Color.Black;
this.btnMenuChevronDown.Location = new System.Drawing.Point(536, 25);
this.btnMenuChevronDown.Name = "btnMenuChevronDown";
this.btnMenuChevronDown.Size = new System.Drawing.Size(157, 32);
this.btnMenuChevronDown.TabIndex = 219;
this.btnMenuChevronDown.Text = "+ Toggle App";
this.btnMenuChevronDown.UseVisualStyleBackColor = true;
this.btnMenuChevronDown.Click += new System.EventHandler(this.btnMenuChevronDown_Click);
//
// pnlNavRight
//
this.pnlNavRight.Controls.Add(this.btnAppBloatpilot);
this.pnlNavRight.Controls.Add(this.checkVersion);
this.pnlNavRight.Controls.Add(this.pnlRight);
this.pnlNavRight.Dock = System.Windows.Forms.DockStyle.Right;
this.pnlNavRight.Location = new System.Drawing.Point(699, 0);
this.pnlNavRight.Name = "pnlNavRight";
this.pnlNavRight.Size = new System.Drawing.Size(227, 720);
this.pnlNavRight.TabIndex = 218;
//
// btnAppBloatpilot
//
this.btnAppBloatpilot.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.btnAppBloatpilot.AutoEllipsis = true;
this.btnAppBloatpilot.BackColor = System.Drawing.Color.MediumVioletRed;
this.btnAppBloatpilot.FlatAppearance.BorderColor = System.Drawing.Color.Gray;
this.btnAppBloatpilot.FlatAppearance.BorderSize = 0;
this.btnAppBloatpilot.Font = new System.Drawing.Font("Segoe UI Variable Display", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnAppBloatpilot.ForeColor = System.Drawing.Color.White;
this.btnAppBloatpilot.Location = new System.Drawing.Point(54, 668);
this.btnAppBloatpilot.Name = "btnAppBloatpilot";
this.btnAppBloatpilot.Padding = new System.Windows.Forms.Padding(0, 0, 5, 0);
this.btnAppBloatpilot.Size = new System.Drawing.Size(120, 35);
this.btnAppBloatpilot.TabIndex = 217;
this.btnAppBloatpilot.TabStop = false;
this.btnAppBloatpilot.Text = "Bloatpilot";
this.btnAppBloatpilot.UseVisualStyleBackColor = false;
this.btnAppBloatpilot.Click += new System.EventHandler(this.btnAppBloatpilot_Click);
//
// checkVersion
//
this.checkVersion.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.checkVersion.Appearance = System.Windows.Forms.Appearance.Button;
this.checkVersion.AutoSize = true;
this.checkVersion.CheckAlign = System.Drawing.ContentAlignment.TopRight;
this.checkVersion.FlatAppearance.BorderSize = 0;
this.checkVersion.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.checkVersion.Font = new System.Drawing.Font("Segoe UI Variable Text Light", 9.75F);
this.checkVersion.ForeColor = System.Drawing.Color.Black;
this.checkVersion.Location = new System.Drawing.Point(193, 0);
this.checkVersion.Name = "checkVersion";
this.checkVersion.Size = new System.Drawing.Size(23, 27);
this.checkVersion.TabIndex = 216;
this.checkVersion.Text = "x";
this.checkVersion.TextAlign = System.Drawing.ContentAlignment.TopRight;
this.checkVersion.UseVisualStyleBackColor = true;
this.checkVersion.CheckedChanged += new System.EventHandler(this.checkVersion_CheckedChanged);
//
// pnlRight
//
this.pnlRight.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Right)));
this.pnlRight.AutoScroll = true;
this.pnlRight.Controls.Add(this.pnlRightSettings);
this.pnlRight.Controls.Add(this.lnkStargazers);
this.pnlRight.Controls.Add(this.btnGithub);
this.pnlRight.Controls.Add(this._lblAboutInfo);
this.pnlRight.Controls.Add(this.lnkURLTwitter);
this.pnlRight.Controls.Add(this.lnkURLReddit);
this.pnlRight.Controls.Add(this.lnkURLDev);
this.pnlRight.Controls.Add(this.lnkURLPayPal);
this.pnlRight.Location = new System.Drawing.Point(12, 33);
this.pnlRight.Name = "pnlRight";
this.pnlRight.Size = new System.Drawing.Size(203, 328);
this.pnlRight.TabIndex = 214;
//
// pnlRightSettings
//
this.pnlRightSettings.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.pnlRightSettings.AutoScroll = true;
this.pnlRightSettings.Controls.Add(this.label1);
this.pnlRightSettings.Controls.Add(this.checkIgnoreLowIssues);
this.pnlRightSettings.Location = new System.Drawing.Point(3, 194);
this.pnlRightSettings.Name = "pnlRightSettings";
this.pnlRightSettings.Size = new System.Drawing.Size(203, 135);
this.pnlRightSettings.TabIndex = 215;
//
// label1
//
this.label1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.label1.AutoEllipsis = true;
this.label1.AutoSize = true;
this.label1.Font = new System.Drawing.Font("Segoe UI Variable Text Light", 11.75F);
this.label1.ForeColor = System.Drawing.Color.Black;
this.label1.Location = new System.Drawing.Point(13, 22);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(63, 21);
this.label1.TabIndex = 197;
this.label1.Text = "Settings";
//
// checkIgnoreLowIssues
//
this.checkIgnoreLowIssues.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.checkIgnoreLowIssues.AutoEllipsis = true;
this.checkIgnoreLowIssues.CheckAlign = System.Drawing.ContentAlignment.TopRight;
this.checkIgnoreLowIssues.FlatAppearance.BorderColor = System.Drawing.Color.DodgerBlue;
this.checkIgnoreLowIssues.FlatAppearance.BorderSize = 0;
this.checkIgnoreLowIssues.Font = new System.Drawing.Font("Segoe UI Variable Text Light", 10.75F);
this.checkIgnoreLowIssues.ForeColor = System.Drawing.Color.Black;
this.checkIgnoreLowIssues.Location = new System.Drawing.Point(16, 54);
this.checkIgnoreLowIssues.Name = "checkIgnoreLowIssues";
this.checkIgnoreLowIssues.Size = new System.Drawing.Size(157, 24);
this.checkIgnoreLowIssues.TabIndex = 211;
this.checkIgnoreLowIssues.Text = "Ignore minor issues";
this.checkIgnoreLowIssues.UseVisualStyleBackColor = true;
this.checkIgnoreLowIssues.CheckedChanged += new System.EventHandler(this.checkIgnoreLowIssues_CheckedChanged);
//
// lnkStargazers
//
this.lnkStargazers.ActiveLinkColor = System.Drawing.Color.MediumVioletRed;
this.lnkStargazers.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.lnkStargazers.AutoEllipsis = true;
this.lnkStargazers.AutoSize = true;
this.lnkStargazers.Font = new System.Drawing.Font("Segoe UI Variable Display Semib", 9.75F, System.Drawing.FontStyle.Bold);
this.lnkStargazers.LinkBehavior = System.Windows.Forms.LinkBehavior.HoverUnderline;
this.lnkStargazers.LinkColor = System.Drawing.Color.Black;
this.lnkStargazers.Location = new System.Drawing.Point(13, 141);
this.lnkStargazers.Name = "lnkStargazers";
this.lnkStargazers.Size = new System.Drawing.Size(105, 17);
this.lnkStargazers.TabIndex = 217;
this.lnkStargazers.TabStop = true;
this.lnkStargazers.Text = "We love Github...";
this.lnkStargazers.VisitedLinkColor = System.Drawing.Color.MediumVioletRed;
this.lnkStargazers.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.lnkStargazers_LinkClicked);
//
// btnGithub
//
this.btnGithub.AutoEllipsis = true;
this.btnGithub.BackColor = System.Drawing.Color.Transparent;
this.btnGithub.FlatAppearance.BorderColor = System.Drawing.Color.Gray;
this.btnGithub.FlatAppearance.BorderSize = 0;
this.btnGithub.Font = new System.Drawing.Font("Segoe Fluent Icons", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnGithub.ForeColor = System.Drawing.Color.MediumVioletRed;
this.btnGithub.Location = new System.Drawing.Point(25, 161);
this.btnGithub.Name = "btnGithub";
this.btnGithub.Padding = new System.Windows.Forms.Padding(0, 0, 5, 0);
this.btnGithub.Size = new System.Drawing.Size(101, 27);
this.btnGithub.TabIndex = 206;
this.btnGithub.TabStop = false;
this.btnGithub.Text = "Follow";
this.btnGithub.TextAlign = System.Drawing.ContentAlignment.TopCenter;
this.btnGithub.UseVisualStyleBackColor = false;
this.btnGithub.Click += new System.EventHandler(this.btnGithub_Click);
//
// _lblAboutInfo
//
this._lblAboutInfo.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this._lblAboutInfo.AutoEllipsis = true;
this._lblAboutInfo.AutoSize = true;
this._lblAboutInfo.Font = new System.Drawing.Font("Segoe UI Variable Text Light", 11.75F);
this._lblAboutInfo.ForeColor = System.Drawing.Color.Black;
this._lblAboutInfo.Location = new System.Drawing.Point(13, 22);
this._lblAboutInfo.Name = "_lblAboutInfo";
this._lblAboutInfo.Size = new System.Drawing.Size(111, 21);
this._lblAboutInfo.TabIndex = 197;
this._lblAboutInfo.Text = "About this App";
//
// lnkURLTwitter
//
this.lnkURLTwitter.ActiveLinkColor = System.Drawing.Color.MediumVioletRed;
this.lnkURLTwitter.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.lnkURLTwitter.AutoEllipsis = true;
this.lnkURLTwitter.AutoSize = true;
this.lnkURLTwitter.Font = new System.Drawing.Font("Segoe UI Variable Text Light", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.lnkURLTwitter.LinkBehavior = System.Windows.Forms.LinkBehavior.HoverUnderline;
this.lnkURLTwitter.LinkColor = System.Drawing.Color.DimGray;
this.lnkURLTwitter.Location = new System.Drawing.Point(13, 71);
this.lnkURLTwitter.Name = "lnkURLTwitter";
this.lnkURLTwitter.Size = new System.Drawing.Size(126, 17);
this.lnkURLTwitter.TabIndex = 199;
this.lnkURLTwitter.TabStop = true;
this.lnkURLTwitter.Text = "Follow dev on Twitter";
this.lnkURLTwitter.VisitedLinkColor = System.Drawing.Color.MediumVioletRed;
this.lnkURLTwitter.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.lnkURLTwitter_LinkClicked);
//
// lnkURLReddit
//
this.lnkURLReddit.ActiveLinkColor = System.Drawing.Color.MediumVioletRed;
this.lnkURLReddit.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.lnkURLReddit.AutoEllipsis = true;
this.lnkURLReddit.AutoSize = true;
this.lnkURLReddit.Font = new System.Drawing.Font("Segoe UI Variable Text Light", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.lnkURLReddit.LinkBehavior = System.Windows.Forms.LinkBehavior.HoverUnderline;
this.lnkURLReddit.LinkColor = System.Drawing.Color.DimGray;
this.lnkURLReddit.Location = new System.Drawing.Point(14, 107);
this.lnkURLReddit.Name = "lnkURLReddit";
this.lnkURLReddit.Size = new System.Drawing.Size(41, 17);
this.lnkURLReddit.TabIndex = 201;
this.lnkURLReddit.TabStop = true;
this.lnkURLReddit.Text = "r/help";
this.tt.SetToolTip(this.lnkURLReddit, "Get help on Reddit");
this.lnkURLReddit.VisitedLinkColor = System.Drawing.Color.MediumVioletRed;
this.lnkURLReddit.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.lnkURLReddit_LinkClicked);
//
// lnkURLDev
//
this.lnkURLDev.ActiveLinkColor = System.Drawing.Color.MediumVioletRed;
this.lnkURLDev.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.lnkURLDev.AutoEllipsis = true;
this.lnkURLDev.AutoSize = true;
this.lnkURLDev.Font = new System.Drawing.Font("Segoe UI Variable Text Light", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.lnkURLDev.LinkBehavior = System.Windows.Forms.LinkBehavior.HoverUnderline;
this.lnkURLDev.LinkColor = System.Drawing.Color.DimGray;
this.lnkURLDev.Location = new System.Drawing.Point(13, 52);
this.lnkURLDev.Name = "lnkURLDev";
this.lnkURLDev.Size = new System.Drawing.Size(100, 17);
this.lnkURLDev.TabIndex = 198;
this.lnkURLDev.TabStop = true;
this.lnkURLDev.Text = "Dev @Builtbybel";
this.lnkURLDev.VisitedLinkColor = System.Drawing.Color.MediumVioletRed;
this.lnkURLDev.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.lnkURLDev_LinkClicked);
//
// lnkURLPayPal
//
this.lnkURLPayPal.ActiveLinkColor = System.Drawing.Color.MediumVioletRed;
this.lnkURLPayPal.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.lnkURLPayPal.AutoEllipsis = true;
this.lnkURLPayPal.AutoSize = true;
this.lnkURLPayPal.Font = new System.Drawing.Font("Segoe UI Variable Text Light", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.lnkURLPayPal.LinkBehavior = System.Windows.Forms.LinkBehavior.HoverUnderline;
this.lnkURLPayPal.LinkColor = System.Drawing.Color.DimGray;
this.lnkURLPayPal.Location = new System.Drawing.Point(14, 89);
this.lnkURLPayPal.Name = "lnkURLPayPal";
this.lnkURLPayPal.Size = new System.Drawing.Size(48, 17);
this.lnkURLPayPal.TabIndex = 200;
this.lnkURLPayPal.TabStop = true;
this.lnkURLPayPal.Text = "Donate";
this.lnkURLPayPal.VisitedLinkColor = System.Drawing.Color.MediumVioletRed;
this.lnkURLPayPal.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.lnkURLPayPal_LinkClicked);
//
// pnlForm
//
this.pnlForm.Controls.Add(this.pnlMain);
this.pnlForm.Dock = System.Windows.Forms.DockStyle.Fill;
this.pnlForm.Location = new System.Drawing.Point(0, 0);
this.pnlForm.Name = "pnlForm";
this.pnlForm.Size = new System.Drawing.Size(926, 720);
this.pnlForm.TabIndex = 2;
//
// tt
//
this.tt.IsBalloon = true;
this.tt.ToolTipIcon = System.Windows.Forms.ToolTipIcon.Info;
//
// contextMenuChevron
//
this.contextMenuChevron.BackColor = System.Drawing.Color.White;
this.contextMenuChevron.Font = new System.Drawing.Font("Segoe UI Variable Text Semiligh", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.contextMenuChevron.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.menuWizard,
this.menuWizardInfo,
this.menuPackages,
this.menuPackagesInfo});
this.contextMenuChevron.Name = "menuMain";
this.contextMenuChevron.RenderMode = System.Windows.Forms.ToolStripRenderMode.System;
this.contextMenuChevron.Size = new System.Drawing.Size(361, 92);
//
// menuWizard
//
this.menuWizard.Font = new System.Drawing.Font("Segoe UI Variable Text", 12.75F);
this.menuWizard.Name = "menuWizard";
this.menuWizard.Size = new System.Drawing.Size(360, 26);
this.menuWizard.Text = "Get started";
this.menuWizard.Click += new System.EventHandler(this.menuWizard_Click);
//
// menuWizardInfo
//
this.menuWizardInfo.BackColor = System.Drawing.Color.White;
this.menuWizardInfo.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.menuWizardInfo.Enabled = false;
this.menuWizardInfo.Font = new System.Drawing.Font("Segoe UI Variable Text", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.menuWizardInfo.Margin = new System.Windows.Forms.Padding(5, 1, 1, 1);
this.menuWizardInfo.Name = "menuWizardInfo";
this.menuWizardInfo.Size = new System.Drawing.Size(300, 16);
this.menuWizardInfo.Text = "Get to know Windows 11 step by step";
//
// menuPackages
//
this.menuPackages.Font = new System.Drawing.Font("Segoe UI Variable Text", 12.75F);
this.menuPackages.Name = "menuPackages";
this.menuPackages.Size = new System.Drawing.Size(360, 26);
this.menuPackages.Text = "Install packages";
this.menuPackages.TextDirection = System.Windows.Forms.ToolStripTextDirection.Horizontal;
this.menuPackages.Click += new System.EventHandler(this.menuPackages_Click);
//
// menuPackagesInfo
//
this.menuPackagesInfo.BackColor = System.Drawing.Color.White;
this.menuPackagesInfo.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.menuPackagesInfo.Enabled = false;
this.menuPackagesInfo.Font = new System.Drawing.Font("Segoe UI Variable Text", 9F);
this.menuPackagesInfo.Margin = new System.Windows.Forms.Padding(5, 1, 1, 1);
this.menuPackagesInfo.Name = "menuPackagesInfo";
this.menuPackagesInfo.Size = new System.Drawing.Size(300, 16);
this.menuPackagesInfo.Text = "Install nifty Software packages";
//
// MainForm
//
this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Dpi;
this.AutoScroll = true;
this.BackColor = System.Drawing.Color.White;
this.ClientSize = new System.Drawing.Size(926, 720);
this.Controls.Add(this.pnlForm);
this.MinimumSize = new System.Drawing.Size(942, 523);
this.Name = "MainForm";
this.ShowIcon = false;
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "Bloatynosy";
this.Load += new System.EventHandler(this.MainForm_Load);
this.Shown += new System.EventHandler(this.MainForm_Shown);
this.pnlMain.ResumeLayout(false);
this.pnlNavRight.ResumeLayout(false);
this.pnlNavRight.PerformLayout();
this.pnlRight.ResumeLayout(false);
this.pnlRight.PerformLayout();
this.pnlRightSettings.ResumeLayout(false);
this.pnlRightSettings.PerformLayout();
this.pnlForm.ResumeLayout(false);
this.contextMenuChevron.ResumeLayout(false);
this.contextMenuChevron.PerformLayout();
this.ResumeLayout(false);
}
#endregion
public System.Windows.Forms.Panel pnlForm;
private System.Windows.Forms.Panel pnlMain;
private System.Windows.Forms.Label _lblAboutInfo;
private System.Windows.Forms.LinkLabel lnkURLTwitter;
private System.Windows.Forms.LinkLabel lnkURLDev;
private System.Windows.Forms.LinkLabel lnkURLPayPal;
private System.Windows.Forms.LinkLabel lnkURLReddit;
private System.Windows.Forms.Panel pnlRight;
private System.Windows.Forms.CheckBox checkIgnoreLowIssues;
private System.Windows.Forms.Panel pnlRightSettings;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Button btnGithub;
private System.Windows.Forms.ToolTip tt;
private System.Windows.Forms.CheckBox checkVersion;
private System.Windows.Forms.Button btnAppBloatpilot;
private System.Windows.Forms.Panel pnlNavRight;
private System.Windows.Forms.Button btnMenuChevronDown;
private System.Windows.Forms.ContextMenuStrip contextMenuChevron;
private System.Windows.Forms.ToolStripMenuItem menuWizard;
private System.Windows.Forms.ToolStripTextBox menuWizardInfo;
private System.Windows.Forms.ToolStripMenuItem menuPackages;
private System.Windows.Forms.ToolStripTextBox menuPackagesInfo;
private System.Windows.Forms.LinkLabel lnkStargazers;
}
}

145
src/Bloatynosy/MainForm.cs Normal file
View File

@ -0,0 +1,145 @@
using Bloatynosy.Views;
using HelperTool;
using System;
using System.Diagnostics;
using System.Drawing;
using System.Windows.Forms;
namespace Bloatynosy
{
public partial class MainForm : Form
{
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private Stargazers github;
// Declare nosyPage field
private NosyPageView nosyPage;
public MainForm()
{
InitializeComponent();
// Initialize NosyPageView
nosyPage = new NosyPageView(this);
// Fetch Github Stargazers
github = new Stargazers();
github.StargazersCountFetched += (sender, count) =>
{
if (count >= 0)
lnkStargazers.Text = $"{count} Stars on Github";
else
lnkStargazers.Text = "Error fetching stargazers";
};
}
private void MainForm_Load(object sender, EventArgs e)
{
// Stargazers link Event listener
lnkStargazers_LinkClicked(lnkStargazers, new LinkLabelLinkClickedEventArgs(lnkStargazers.Links[0]));
}
private void MainForm_Shown(object sender, EventArgs e)
{
// Refer to instance NosyPageView
pnlMain.Controls.Add(nosyPage);
nosyPage.Anchor = (AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right | AnchorStyles.Bottom);
nosyPage.Dock = DockStyle.Fill;
// Refer Main and default NavPage
ViewHelper.SwitchView.INavPage = pnlForm.Controls[0];
ViewHelper.SwitchView.mainForm = this;
// Get versioning
checkVersion.Text = GetMinorVersion(Program.GetCurrentVersionTostring());
// Load styling
this.SetStyle();
}
private void SetStyle()
{
// Segoe MDL2 Assets
btnGithub.Text += "\uEB52";
// Some color styling
BackColor = Color.FromArgb(243, 243, 243);
pnlRight.BackColor =
pnlRightSettings.BackColor = Color.White;
// Ref. SplitterContainer scaling bugs in .Net https://github.com/dotnet/winforms/issues/3168 OBSOLETE!
// this.sc.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
}
public bool CheckIgnoreLowIssuesChecked
{
get { return checkIgnoreLowIssues.Checked; }
}
private void checkIgnoreLowIssues_CheckedChanged(object sender, EventArgs e)
{
if (checkIgnoreLowIssues.Checked)
{
nosyPage.SelectFeatureNodes(nosyPage.tvwFeatures.Nodes, true);
}
}
private string GetMinorVersion(string version)
{
// Display everything until the second dot without the dot
int secondDotIndex = version.IndexOf('.', version.IndexOf('.') + 1);
if (secondDotIndex != -1)
{
version = version.Substring(0, secondDotIndex);
}
return $"Version {version}";
}
// Switch between minor and full app version
private void checkVersion_CheckedChanged(object sender, EventArgs e)
{
// Get full version
string fullVersion = Program.GetCurrentVersionTostring();
// Display version based on the CheckBox state
checkVersion.Text = checkVersion.Checked ? fullVersion : GetMinorVersion(fullVersion);
// Optionally, check for updates when checked
if (checkVersion.Checked)
{
HelperTool.Utils.CheckForUpdates();
}
}
private void richLog_LinkClicked(object sender, LinkClickedEventArgs e)
=> Utils.LaunchUri(e.LinkText);
private void lnkURLDev_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
=> Process.Start(HelperTool.Utils.Uri.URL_BUILTBYBEL);
private void lnkURLTwitter_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
=> Process.Start(HelperTool.Utils.Uri.URL_TWITTER);
private void lnkURLReddit_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
=> Process.Start(HelperTool.Utils.Uri.URL_HELP);
private void lnkURLPayPal_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
=> Process.Start(HelperTool.Utils.Uri.URL_DONATE);
private void btnGithub_Click(object sender, EventArgs e)
=> Process.Start(HelperTool.Utils.Uri.URL_GITREPO);
private void btnMenuChevronDown_Click(object sender, EventArgs e)
=> this.contextMenuChevron.Show(Cursor.Position.X, Cursor.Position.Y);
private void btnAppBloatpilot_Click(object sender, EventArgs e)
=> ViewHelper.SwitchView.SetView(new BloatyPageView());
private void menuWizard_Click(object sender, EventArgs e)
=> ViewHelper.SwitchView.SetView(new WizardPageView(this));
private void menuPackages_Click(object sender, EventArgs e)
=> ViewHelper.SwitchView.SetView(new PackagesPageView());
private async void lnkStargazers_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
{
//e.Link.Visited = true;
await github.FetchStargazersAsync();
}
}
}

View File

@ -0,0 +1,132 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="tt.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>14, 20</value>
</metadata>
<metadata name="tt.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>14, 20</value>
</metadata>
<metadata name="contextMenuChevron.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>70, 21</value>
</metadata>
<metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>81</value>
</metadata>
</root>

View File

@ -0,0 +1,26 @@
namespace Bloatynosy.Setup
{
public enum PageTitle
{
Setup = 0,
NewLook,
StartMenu,
Apps,
Privacy,
MicrosoftStore,
ActionCenter,
FileExplorer,
SettingsApp,
WindowsUpdates,
SnapLayouts,
Widgets,
GestureControls,
WallpapersNSounds,
LockScreen,
TouchKeyboard,
AndroidApps,
Gaming,
Finish,
Custom
}
}

31
src/Bloatynosy/Program.cs Normal file
View File

@ -0,0 +1,31 @@
using System;
using System.Windows.Forms;
namespace Bloatynosy
{
internal static class Program
{
/// <summary>
/// Get app version
/// </summary>
internal static string GetCurrentVersionTostring() => new Version(Application.ProductVersion).ToString(3);
/// <summary>
/// The main entry point for the application.
/// </summary>
[STAThread]
private static void Main()
{
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
if (!HelperTool.OsHelper.IsWin11())
{
MessageBox.Show("You are running Bloaty&Nosy on a system older than Windows 11.\nBloatynosy is limited to Windows 11 ONLY.", "OS not supported", MessageBoxButtons.OK, MessageBoxIcon.Information);
Application.Exit();
}
else Application.Run(new MainForm());
}
}
}

View File

@ -0,0 +1,35 @@
using System.Reflection;
using System.Runtime.InteropServices;
// Allgemeine Informationen über eine Assembly werden über die folgenden
// Attribute gesteuert. Ändern Sie diese Attributwerte, um die Informationen zu ändern,
// die einer Assembly zugeordnet sind.
[assembly: AssemblyTitle("Bloatynosy")]
[assembly: AssemblyDescription("The real Windows 11 Copilot")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Builtbybel")]
[assembly: AssemblyProduct("Bloatynosy")]
[assembly: AssemblyCopyright("Copyright © 2023 Builtbybel")]
[assembly: AssemblyTrademark("Builtbybel")]
[assembly: AssemblyCulture("")]
// Durch Festlegen von ComVisible auf FALSE werden die Typen in dieser Assembly
// für COM-Komponenten unsichtbar. Wenn Sie auf einen Typ in dieser Assembly von
// COM aus zugreifen müssen, sollten Sie das ComVisible-Attribut für diesen Typ auf "True" festlegen.
[assembly: ComVisible(false)]
// Die folgende GUID bestimmt die ID der Typbibliothek, wenn dieses Projekt für COM verfügbar gemacht wird
[assembly: Guid("44cafceb-0f6d-487f-9f5f-63f230dbb069")]
// Versionsinformationen für eine Assembly bestehen aus den folgenden vier Werten:
//
// Hauptversion
// Nebenversion
// Buildnummer
// Revision
//
// Sie können alle Werte angeben oder Standardwerte für die Build- und Revisionsnummern verwenden,
// indem Sie "*" wie unten gezeigt eingeben:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.2.12")]
[assembly: AssemblyFileVersion("1.2.12")]

View File

@ -0,0 +1,90 @@
//------------------------------------------------------------------------------
// <auto-generated>
// Dieser Code wurde von einem Tool generiert.
// Laufzeitversion:4.0.30319.42000
//
// Änderungen an dieser Datei können falsches Verhalten verursachen und gehen verloren, wenn
// der Code erneut generiert wird.
// </auto-generated>
//------------------------------------------------------------------------------
namespace Bloatynosy.Properties {
using System;
/// <summary>
/// Eine stark typisierte Ressourcenklasse zum Suchen von lokalisierten Zeichenfolgen usw.
/// </summary>
// Diese Klasse wurde von der StronglyTypedResourceBuilder automatisch generiert
// -Klasse über ein Tool wie ResGen oder Visual Studio automatisch generiert.
// Um einen Member hinzuzufügen oder zu entfernen, bearbeiten Sie die .ResX-Datei und führen dann ResGen
// mit der /str-Option erneut aus, oder Sie erstellen Ihr VS-Projekt neu.
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "17.0.0.0")]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
internal class Resources {
private static global::System.Resources.ResourceManager resourceMan;
private static global::System.Globalization.CultureInfo resourceCulture;
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
internal Resources() {
}
/// <summary>
/// Gibt die zwischengespeicherte ResourceManager-Instanz zurück, die von dieser Klasse verwendet wird.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Resources.ResourceManager ResourceManager {
get {
if (object.ReferenceEquals(resourceMan, null)) {
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Bloatynosy.Properties.Resources", typeof(Resources).Assembly);
resourceMan = temp;
}
return resourceMan;
}
}
/// <summary>
/// Überschreibt die CurrentUICulture-Eigenschaft des aktuellen Threads für alle
/// Ressourcenzuordnungen, die diese stark typisierte Ressourcenklasse verwenden.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Globalization.CultureInfo Culture {
get {
return resourceCulture;
}
set {
resourceCulture = value;
}
}
/// <summary>
/// Sucht eine lokalisierte Zeichenfolge, die 1527c705-839a-4832-9118-54d4Bd6a0c89
///c5e2524a-ea46-4f67-841f-6a9465d9d515
///E2A4F912-2574-4A75-9BB0-0D023378592B
///F46D4000-FD22-4DB4-AC8E-4E1DDDE828FE
///InputApp
///Microsoft.AAD.BrokerPlugin
///Microsoft.AccountsControl
///Microsoft.Advertising.Xaml
///Microsoft.AsyncTextService
///Microsoft.BioEnrollment
///Microsoft.CredDialogHost
///Microsoft.ECApp
///Microsoft.LockApp
///Microsoft.MicrosoftEdge
///Microsoft.MicrosoftEdgeDevToolsClient
///Microsoft.NET
///Microsoft.PPIProjection
///Microsoft.Services.Store.Engagement
///Microsoft.V [Rest der Zeichenfolge wurde abgeschnitten]&quot;; ähnelt.
/// </summary>
internal static string systemApps {
get {
return ResourceManager.GetString("systemApps", resourceCulture);
}
}
}
}

View File

@ -0,0 +1,126 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<data name="systemApps" type="System.Resources.ResXFileRef, System.Windows.Forms">
<value>..\Resources\systemApps.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;Windows-1252</value>
</data>
</root>

View File

@ -0,0 +1,26 @@
//------------------------------------------------------------------------------
// <auto-generated>
// Dieser Code wurde von einem Tool generiert.
// Laufzeitversion:4.0.30319.42000
//
// Änderungen an dieser Datei können falsches Verhalten verursachen und gehen verloren, wenn
// der Code erneut generiert wird.
// </auto-generated>
//------------------------------------------------------------------------------
namespace Bloatynosy.Properties {
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "17.8.0.0")]
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
public static Settings Default {
get {
return defaultInstance;
}
}
}
}

View File

@ -0,0 +1,7 @@
<?xml version='1.0' encoding='utf-8'?>
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)">
<Profiles>
<Profile Name="(Default)" />
</Profiles>
<Settings />
</SettingsFile>

View File

@ -0,0 +1,41 @@
1527c705-839a-4832-9118-54d4Bd6a0c89
c5e2524a-ea46-4f67-841f-6a9465d9d515
E2A4F912-2574-4A75-9BB0-0D023378592B
F46D4000-FD22-4DB4-AC8E-4E1DDDE828FE
InputApp
Microsoft.AAD.BrokerPlugin
Microsoft.AccountsControl
Microsoft.Advertising.Xaml
Microsoft.AsyncTextService
Microsoft.BioEnrollment
Microsoft.CredDialogHost
Microsoft.ECApp
Microsoft.LockApp
Microsoft.MicrosoftEdge
Microsoft.MicrosoftEdgeDevToolsClient
Microsoft.NET
Microsoft.PPIProjection
Microsoft.Services.Store.Engagement
Microsoft.VCLibs
Microsoft.Win32WebViewHost
Microsoft.WindowsStore
Microsoft.WindowsCalculator
Microsoft.XboxGameCallableUI
Microsoft.Windows.Apprep.ChxApp
Microsoft.Windows.AssignedAccessLockApp
Microsoft.Windows.CapturePicker
Microsoft.Windows.CloudExperienceHost
Microsoft.Windows.ContentDeliveryManager
Microsoft.Windows.NarratorQuickStart
Microsoft.Windows.OOBENetworkCaptivePortal
Microsoft.Windows.OOBENetworkConnectionFlow
Microsoft.Windows.ParentalControls
Microsoft.Windows.PeopleExperienceHost
Microsoft.Windows.PinningConfirmationDialog
Microsoft.Windows.SecHealthUI
Microsoft.Windows.SecureAssessmentBrowser
Microsoft.Windows.ShellExperienceHost
Microsoft.Windows.XGpuEjectDialog
Windows.CBSPreview
windows.immersivecontrolpanel
Windows.PrintDialog

37
src/Bloatynosy/Views/Bloat-E.Designer.cs generated Normal file
View File

@ -0,0 +1,37 @@
namespace BloatyNosy.Views
{
partial class Bloat_E
{
/// <summary>
/// Erforderliche Designervariable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Verwendete Ressourcen bereinigen.
/// </summary>
/// <param name="disposing">True, wenn verwaltete Ressourcen gelöscht werden sollen; andernfalls False.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Vom Komponenten-Designer generierter Code
/// <summary>
/// Erforderliche Methode für die Designerunterstützung.
/// Der Inhalt der Methode darf nicht mit dem Code-Editor geändert werden.
/// </summary>
private void InitializeComponent()
{
components = new System.ComponentModel.Container();
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
}
#endregion
}
}

View File

@ -0,0 +1,20 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace BloatyNosy.Views
{
public partial class Bloat_E : UserControl
{
public Bloat_E()
{
InitializeComponent();
}
}
}

View File

@ -0,0 +1,120 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@ -0,0 +1,438 @@
namespace Bloatynosy.Views
{
partial class BloatyPageView
{
/// <summary>
/// Erforderliche Designervariable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Verwendete Ressourcen bereinigen.
/// </summary>
/// <param name="disposing">True, wenn verwaltete Ressourcen gelöscht werden sollen; andernfalls False.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Vom Komponenten-Designer generierter Code
/// <summary>
/// Erforderliche Methode für die Designerunterstützung.
/// Der Inhalt der Methode darf nicht mit dem Code-Editor geändert werden.
/// </summary>
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
System.Windows.Forms.ToolStripMenuItem menuAppsExport;
this.listRemove = new System.Windows.Forms.ListBox();
this.rtbStatus = new System.Windows.Forms.RichTextBox();
this.btnRestoreAll = new System.Windows.Forms.Button();
this.btnRestore = new System.Windows.Forms.Button();
this.btnMoveAll = new System.Windows.Forms.Button();
this.btnMove = new System.Windows.Forms.Button();
this.btnUninstall = new System.Windows.Forms.Button();
this.btnBack = new System.Windows.Forms.Button();
this.lblHeader = new System.Windows.Forms.Label();
this.listApps = new System.Windows.Forms.ListBox();
this.checkAppsSystem = new System.Windows.Forms.CheckBox();
this.picAppsPoster = new System.Windows.Forms.PictureBox();
this.lblBloatOpt1 = new System.Windows.Forms.LinkLabel();
this.textSearch = new System.Windows.Forms.TextBox();
this.btnHMenu = new System.Windows.Forms.Button();
this.contextAppMenu = new System.Windows.Forms.ContextMenuStrip(this.components);
this.menuAppsImport = new System.Windows.Forms.ToolStripMenuItem();
this.menuAppsRemoveAll = new System.Windows.Forms.ToolStripMenuItem();
this.lblInstalled = new System.Windows.Forms.Label();
this.lblBin = new System.Windows.Forms.Label();
this.lblBloatOpt2 = new System.Windows.Forms.LinkLabel();
this.btnRefresh = new System.Windows.Forms.Button();
menuAppsExport = new System.Windows.Forms.ToolStripMenuItem();
((System.ComponentModel.ISupportInitialize)(this.picAppsPoster)).BeginInit();
this.contextAppMenu.SuspendLayout();
this.SuspendLayout();
//
// menuAppsExport
//
menuAppsExport.Name = "menuAppsExport";
menuAppsExport.Size = new System.Drawing.Size(193, 22);
menuAppsExport.Text = "Export bloatware in bin";
menuAppsExport.Click += new System.EventHandler(this.menuAppsExport_Click);
//
// listRemove
//
this.listRemove.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Right)));
this.listRemove.BackColor = System.Drawing.Color.White;
this.listRemove.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.listRemove.Font = new System.Drawing.Font("Segoe UI Variable Text Semiligh", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.listRemove.FormattingEnabled = true;
this.listRemove.ItemHeight = 17;
this.listRemove.Location = new System.Drawing.Point(823, 107);
this.listRemove.Name = "listRemove";
this.listRemove.SelectionMode = System.Windows.Forms.SelectionMode.MultiExtended;
this.listRemove.Size = new System.Drawing.Size(270, 646);
this.listRemove.Sorted = true;
this.listRemove.TabIndex = 13;
//
// rtbStatus
//
this.rtbStatus.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Right)));
this.rtbStatus.BackColor = System.Drawing.Color.White;
this.rtbStatus.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.rtbStatus.Font = new System.Drawing.Font("Segoe UI Variable Text", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.rtbStatus.ForeColor = System.Drawing.Color.Black;
this.rtbStatus.HideSelection = false;
this.rtbStatus.Location = new System.Drawing.Point(823, 107);
this.rtbStatus.Name = "rtbStatus";
this.rtbStatus.ReadOnly = true;
this.rtbStatus.ScrollBars = System.Windows.Forms.RichTextBoxScrollBars.Vertical;
this.rtbStatus.Size = new System.Drawing.Size(270, 656);
this.rtbStatus.TabIndex = 139;
this.rtbStatus.Text = "";
this.rtbStatus.Visible = false;
//
// btnRestoreAll
//
this.btnRestoreAll.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.btnRestoreAll.AutoEllipsis = true;
this.btnRestoreAll.Font = new System.Drawing.Font("Segoe UI Variable Text", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnRestoreAll.ForeColor = System.Drawing.Color.Black;
this.btnRestoreAll.Location = new System.Drawing.Point(449, 493);
this.btnRestoreAll.Name = "btnRestoreAll";
this.btnRestoreAll.Size = new System.Drawing.Size(239, 23);
this.btnRestoreAll.TabIndex = 34;
this.btnRestoreAll.Text = "<< Restore all";
this.btnRestoreAll.UseVisualStyleBackColor = true;
this.btnRestoreAll.Click += new System.EventHandler(this.btnRestoreAll_Click);
//
// btnRestore
//
this.btnRestore.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.btnRestore.AutoEllipsis = true;
this.btnRestore.Font = new System.Drawing.Font("Segoe UI Variable Text", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnRestore.ForeColor = System.Drawing.Color.Black;
this.btnRestore.Location = new System.Drawing.Point(449, 464);
this.btnRestore.Name = "btnRestore";
this.btnRestore.Size = new System.Drawing.Size(239, 23);
this.btnRestore.TabIndex = 32;
this.btnRestore.Text = "< Restore";
this.btnRestore.UseVisualStyleBackColor = true;
this.btnRestore.Click += new System.EventHandler(this.btnRestore_Click);
//
// btnMoveAll
//
this.btnMoveAll.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.btnMoveAll.AutoEllipsis = true;
this.btnMoveAll.Font = new System.Drawing.Font("Segoe UI Variable Text", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnMoveAll.ForeColor = System.Drawing.Color.Black;
this.btnMoveAll.Location = new System.Drawing.Point(449, 406);
this.btnMoveAll.Name = "btnMoveAll";
this.btnMoveAll.Size = new System.Drawing.Size(239, 23);
this.btnMoveAll.TabIndex = 35;
this.btnMoveAll.Text = "Move all >>";
this.btnMoveAll.UseVisualStyleBackColor = true;
this.btnMoveAll.Click += new System.EventHandler(this.btnMoveAll_Click);
//
// btnMove
//
this.btnMove.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.btnMove.AutoEllipsis = true;
this.btnMove.Font = new System.Drawing.Font("Segoe UI Variable Text", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnMove.ForeColor = System.Drawing.Color.Black;
this.btnMove.Location = new System.Drawing.Point(449, 377);
this.btnMove.Name = "btnMove";
this.btnMove.Size = new System.Drawing.Size(239, 23);
this.btnMove.TabIndex = 31;
this.btnMove.Text = "Move >";
this.btnMove.UseVisualStyleBackColor = true;
this.btnMove.Click += new System.EventHandler(this.btnMove_Click);
//
// btnUninstall
//
this.btnUninstall.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.btnUninstall.BackColor = System.Drawing.Color.MediumVioletRed;
this.btnUninstall.FlatAppearance.BorderSize = 0;
this.btnUninstall.Font = new System.Drawing.Font("Segoe UI Variable Display", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnUninstall.ForeColor = System.Drawing.Color.White;
this.btnUninstall.Location = new System.Drawing.Point(815, 34);
this.btnUninstall.Name = "btnUninstall";
this.btnUninstall.Size = new System.Drawing.Size(181, 35);
this.btnUninstall.TabIndex = 41;
this.btnUninstall.Text = "Empty bin";
this.btnUninstall.UseVisualStyleBackColor = false;
this.btnUninstall.Click += new System.EventHandler(this.btnUninstall_Click);
//
// btnBack
//
this.btnBack.FlatAppearance.BorderSize = 0;
this.btnBack.FlatAppearance.MouseOverBackColor = System.Drawing.Color.WhiteSmoke;
this.btnBack.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnBack.Font = new System.Drawing.Font("Segoe Fluent Icons", 9.75F, System.Drawing.FontStyle.Bold);
this.btnBack.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.btnBack.Location = new System.Drawing.Point(0, 0);
this.btnBack.Name = "btnBack";
this.btnBack.Size = new System.Drawing.Size(42, 38);
this.btnBack.TabIndex = 176;
this.btnBack.Text = "...";
this.btnBack.UseVisualStyleBackColor = true;
this.btnBack.Click += new System.EventHandler(this.btnBack_Click);
//
// lblHeader
//
this.lblHeader.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.lblHeader.AutoEllipsis = true;
this.lblHeader.Font = new System.Drawing.Font("Segoe UI Variable Text Semibold", 18.25F, System.Drawing.FontStyle.Bold);
this.lblHeader.ForeColor = System.Drawing.Color.Black;
this.lblHeader.Location = new System.Drawing.Point(294, 31);
this.lblHeader.Name = "lblHeader";
this.lblHeader.Size = new System.Drawing.Size(515, 32);
this.lblHeader.TabIndex = 177;
this.lblHeader.Text = "Bloatpilot";
this.lblHeader.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// listApps
//
this.listApps.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)));
this.listApps.BackColor = System.Drawing.Color.White;
this.listApps.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.listApps.Font = new System.Drawing.Font("Segoe UI Variable Text Semiligh", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.listApps.FormattingEnabled = true;
this.listApps.ItemHeight = 17;
this.listApps.Location = new System.Drawing.Point(44, 99);
this.listApps.Name = "listApps";
this.listApps.SelectionMode = System.Windows.Forms.SelectionMode.MultiExtended;
this.listApps.Size = new System.Drawing.Size(270, 629);
this.listApps.Sorted = true;
this.listApps.TabIndex = 13;
//
// checkAppsSystem
//
this.checkAppsSystem.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.checkAppsSystem.AutoSize = true;
this.checkAppsSystem.FlatAppearance.BorderSize = 0;
this.checkAppsSystem.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.checkAppsSystem.Font = new System.Drawing.Font("Segoe UI Variable Text", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.checkAppsSystem.ForeColor = System.Drawing.Color.DeepPink;
this.checkAppsSystem.Location = new System.Drawing.Point(44, 754);
this.checkAppsSystem.Name = "checkAppsSystem";
this.checkAppsSystem.Size = new System.Drawing.Size(132, 21);
this.checkAppsSystem.TabIndex = 16;
this.checkAppsSystem.Text = "Show system apps";
this.checkAppsSystem.UseVisualStyleBackColor = true;
this.checkAppsSystem.CheckedChanged += new System.EventHandler(this.checkAppsSystem_CheckedChanged);
//
// picAppsPoster
//
this.picAppsPoster.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.picAppsPoster.ErrorImage = null;
this.picAppsPoster.InitialImage = null;
this.picAppsPoster.Location = new System.Drawing.Point(320, 136);
this.picAppsPoster.Name = "picAppsPoster";
this.picAppsPoster.Size = new System.Drawing.Size(497, 235);
this.picAppsPoster.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
this.picAppsPoster.TabIndex = 161;
this.picAppsPoster.TabStop = false;
//
// lblBloatOpt1
//
this.lblBloatOpt1.ActiveLinkColor = System.Drawing.Color.MediumVioletRed;
this.lblBloatOpt1.AutoEllipsis = true;
this.lblBloatOpt1.AutoSize = true;
this.lblBloatOpt1.Font = new System.Drawing.Font("Segoe UI Variable Display", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.lblBloatOpt1.LinkBehavior = System.Windows.Forms.LinkBehavior.AlwaysUnderline;
this.lblBloatOpt1.LinkColor = System.Drawing.Color.MediumVioletRed;
this.lblBloatOpt1.Location = new System.Drawing.Point(339, 110);
this.lblBloatOpt1.Name = "lblBloatOpt1";
this.lblBloatOpt1.Size = new System.Drawing.Size(121, 17);
this.lblBloatOpt1.TabIndex = 159;
this.lblBloatOpt1.TabStop = true;
this.lblBloatOpt1.Text = "Try these bloatware";
this.lblBloatOpt1.VisitedLinkColor = System.Drawing.Color.MediumVioletRed;
this.lblBloatOpt1.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.lblBloatOpt1_LinkClicked);
//
// textSearch
//
this.textSearch.Anchor = System.Windows.Forms.AnchorStyles.Top;
this.textSearch.BackColor = System.Drawing.Color.WhiteSmoke;
this.textSearch.Font = new System.Drawing.Font("Segoe UI Variable Display", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.textSearch.ForeColor = System.Drawing.Color.Gray;
this.textSearch.Location = new System.Drawing.Point(485, 66);
this.textSearch.Name = "textSearch";
this.textSearch.Size = new System.Drawing.Size(149, 25);
this.textSearch.TabIndex = 181;
this.textSearch.Text = "Search";
this.textSearch.Click += new System.EventHandler(this.textSearch_Click);
this.textSearch.TextChanged += new System.EventHandler(this.textSearch_TextChanged);
//
// btnHMenu
//
this.btnHMenu.FlatAppearance.BorderSize = 0;
this.btnHMenu.FlatAppearance.MouseOverBackColor = System.Drawing.Color.Gainsboro;
this.btnHMenu.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnHMenu.Font = new System.Drawing.Font("Segoe Fluent Icons", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnHMenu.ForeColor = System.Drawing.Color.Black;
this.btnHMenu.Location = new System.Drawing.Point(35, 0);
this.btnHMenu.Name = "btnHMenu";
this.btnHMenu.Size = new System.Drawing.Size(42, 38);
this.btnHMenu.TabIndex = 184;
this.btnHMenu.Text = "...";
this.btnHMenu.UseVisualStyleBackColor = true;
this.btnHMenu.Click += new System.EventHandler(this.btnHMenu_Click);
//
// contextAppMenu
//
this.contextAppMenu.BackColor = System.Drawing.Color.WhiteSmoke;
this.contextAppMenu.Font = new System.Drawing.Font("Segoe UI Variable Text Semiligh", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.contextAppMenu.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.menuAppsImport,
menuAppsExport,
this.menuAppsRemoveAll});
this.contextAppMenu.Name = "menuMain";
this.contextAppMenu.RenderMode = System.Windows.Forms.ToolStripRenderMode.System;
this.contextAppMenu.Size = new System.Drawing.Size(194, 70);
this.contextAppMenu.Text = "Info";
//
// menuAppsImport
//
this.menuAppsImport.Name = "menuAppsImport";
this.menuAppsImport.Size = new System.Drawing.Size(193, 22);
this.menuAppsImport.Text = "Import bloatware list";
this.menuAppsImport.Click += new System.EventHandler(this.menuAppsImport_Click);
//
// menuAppsRemoveAll
//
this.menuAppsRemoveAll.Name = "menuAppsRemoveAll";
this.menuAppsRemoveAll.Size = new System.Drawing.Size(193, 22);
this.menuAppsRemoveAll.Text = "Uninstall all apps";
this.menuAppsRemoveAll.Click += new System.EventHandler(this.menuAppsRemoveAll_Click);
//
// lblInstalled
//
this.lblInstalled.AutoSize = true;
this.lblInstalled.Font = new System.Drawing.Font("Segoe UI Variable Display", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.lblInstalled.ForeColor = System.Drawing.Color.Black;
this.lblInstalled.Location = new System.Drawing.Point(41, 70);
this.lblInstalled.Name = "lblInstalled";
this.lblInstalled.Size = new System.Drawing.Size(56, 17);
this.lblInstalled.TabIndex = 185;
this.lblInstalled.Text = "Installed";
//
// lblBin
//
this.lblBin.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.lblBin.AutoSize = true;
this.lblBin.Font = new System.Drawing.Font("Segoe UI Variable Display", 9.75F);
this.lblBin.ForeColor = System.Drawing.Color.Black;
this.lblBin.Location = new System.Drawing.Point(820, 79);
this.lblBin.Name = "lblBin";
this.lblBin.Size = new System.Drawing.Size(74, 17);
this.lblBin.TabIndex = 186;
this.lblBin.Text = "Recycle Bin";
//
// lblBloatOpt2
//
this.lblBloatOpt2.ActiveLinkColor = System.Drawing.Color.MediumVioletRed;
this.lblBloatOpt2.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.lblBloatOpt2.AutoEllipsis = true;
this.lblBloatOpt2.Font = new System.Drawing.Font("Segoe UI Variable Display", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.lblBloatOpt2.LinkBehavior = System.Windows.Forms.LinkBehavior.HoverUnderline;
this.lblBloatOpt2.LinkColor = System.Drawing.Color.DimGray;
this.lblBloatOpt2.Location = new System.Drawing.Point(467, 110);
this.lblBloatOpt2.Name = "lblBloatOpt2";
this.lblBloatOpt2.Size = new System.Drawing.Size(347, 23);
this.lblBloatOpt2.TabIndex = 187;
this.lblBloatOpt2.TabStop = true;
this.lblBloatOpt2.Text = "Add most hated";
this.lblBloatOpt2.VisitedLinkColor = System.Drawing.Color.MediumVioletRed;
this.lblBloatOpt2.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.lblBloatOpt2_LinkClicked);
//
// btnRefresh
//
this.btnRefresh.BackColor = System.Drawing.Color.Transparent;
this.btnRefresh.FlatAppearance.BorderColor = System.Drawing.Color.White;
this.btnRefresh.FlatAppearance.BorderSize = 0;
this.btnRefresh.Font = new System.Drawing.Font("Segoe Fluent Icons", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnRefresh.ForeColor = System.Drawing.Color.Black;
this.btnRefresh.Location = new System.Drawing.Point(75, 0);
this.btnRefresh.Name = "btnRefresh";
this.btnRefresh.Size = new System.Drawing.Size(42, 38);
this.btnRefresh.TabIndex = 191;
this.btnRefresh.Text = "...";
this.btnRefresh.UseVisualStyleBackColor = false;
this.btnRefresh.Click += new System.EventHandler(this.btnRefresh_Click);
//
// BloatyPageView
//
this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Dpi;
this.AutoScroll = true;
this.BackColor = System.Drawing.Color.White;
this.Controls.Add(this.btnRefresh);
this.Controls.Add(this.lblBloatOpt2);
this.Controls.Add(this.picAppsPoster);
this.Controls.Add(this.lblBloatOpt1);
this.Controls.Add(this.lblBin);
this.Controls.Add(this.lblInstalled);
this.Controls.Add(this.listApps);
this.Controls.Add(this.checkAppsSystem);
this.Controls.Add(this.btnHMenu);
this.Controls.Add(this.textSearch);
this.Controls.Add(this.lblHeader);
this.Controls.Add(this.btnBack);
this.Controls.Add(this.btnUninstall);
this.Controls.Add(this.btnRestoreAll);
this.Controls.Add(this.btnRestore);
this.Controls.Add(this.btnMoveAll);
this.Controls.Add(this.btnMove);
this.Controls.Add(this.listRemove);
this.Controls.Add(this.rtbStatus);
this.Name = "BloatyPageView";
this.Size = new System.Drawing.Size(1107, 805);
((System.ComponentModel.ISupportInitialize)(this.picAppsPoster)).EndInit();
this.contextAppMenu.ResumeLayout(false);
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.ListBox listRemove;
private System.Windows.Forms.Button btnRestoreAll;
private System.Windows.Forms.Button btnRestore;
private System.Windows.Forms.Button btnMoveAll;
private System.Windows.Forms.Button btnMove;
private System.Windows.Forms.Button btnUninstall;
public System.Windows.Forms.RichTextBox rtbStatus;
private System.Windows.Forms.Button btnBack;
private System.Windows.Forms.Label lblHeader;
private System.Windows.Forms.ListBox listApps;
private System.Windows.Forms.CheckBox checkAppsSystem;
private System.Windows.Forms.TextBox textSearch;
private System.Windows.Forms.LinkLabel lblBloatOpt1;
private System.Windows.Forms.Button btnHMenu;
private System.Windows.Forms.ContextMenuStrip contextAppMenu;
private System.Windows.Forms.ToolStripMenuItem menuAppsImport;
private System.Windows.Forms.ToolStripMenuItem menuAppsRemoveAll;
private System.Windows.Forms.PictureBox picAppsPoster;
private System.Windows.Forms.Label lblInstalled;
private System.Windows.Forms.Label lblBin;
private System.Windows.Forms.LinkLabel lblBloatOpt2;
private System.Windows.Forms.Button btnRefresh;
}
}

View File

@ -0,0 +1,439 @@
using System;
using System.Collections.Generic;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Management.Automation;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace Bloatynosy.Views
{
public partial class BloatyPageView : UserControl
{
private List<string> removeAppsList = new List<string>();
private List<string> removeAppsFailedList = new List<string>();
private List<string> removeAppsSystem = new List<string>();
private readonly PowerShell powerShell = PowerShell.Create();
public BloatyPageView()
{
InitializeComponent();
this.InitializeAppsSystem(); // Retrieve hidden systemapps from resource file
this.InitializeApps(); // Yet just the normal....
SetStyle();
}
// Some UI nicety
private void SetStyle()
{
// Segoe MDL2 Assets
btnHMenu.Text = "\uE700";
btnRefresh.Text = "\uE895";
btnBack.Text = "\uE72B";
// Some color styling
BackColor =
listApps.BackColor =
listRemove.BackColor =
rtbStatus.BackColor =
Color.FromArgb(245, 241, 249);
if (!HelperTool.Utils.IsInet()) picAppsPoster.Visible = false;
else picAppsPoster.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/page-apps.png?raw=true";
}
private void InitializeApps()
{
listApps.Items.Clear();
powerShell.Commands.Clear();
powerShell.AddCommand("get-appxpackage");
powerShell.AddCommand("Select").AddParameter("property", "name");
foreach (PSObject result in powerShell.Invoke())
{
string current = result.ToString();
// Show ONLY NON-SYSTEM apps by comparing found apps with systemapps.txt
if (removeAppsSystem != null) if ((removeAppsSystem.Any(current.Contains)) & !checkAppsSystem.Checked) continue;
if (listApps.Items.Contains(Regex.Replace(current, "(@{Name=)|(})", ""))) continue;
listApps.Items.Add(Regex.Replace(current, "(@{Name=)|(})", ""));
removeAppsList.Add(Regex.Replace(current, "(@{Name=)|(})", ""));
}
// Compare left and rights apps list and remove differences
string compare = listApps.Items.ToString();
foreach (string item in listRemove.Items) if (item.Any(compare.Contains)) listApps.Items.Remove(item);
RefreshApps();
}
private void InitializeAppsSystem()
{
StreamReader Database = null;
try
{
HelperTool.Utils.CreateDataDir();
Database = File.OpenText(HelperTool.Utils.Data.DataRootDir + "systemApps.txt");
}
catch (FileNotFoundException) // Create file if it doesnt exisits
{
StreamWriter sw = File.CreateText(HelperTool.Utils.Data.DataRootDir + "systemApps.txt");
sw.Write(Bloatynosy.Properties.Resources.systemApps); // Populate it with built in preset
sw.Close();
Database = File.OpenText(HelperTool.Utils.Data.DataRootDir + "systemApps.txt");
}
finally
{
if (Database.Peek() > 0) // Exists and not empty
{
string buff;
while ((buff = Database.ReadLine()) != null)
{
removeAppsSystem.Add(buff);
}
};
Database.Close();
}
}
private void RemoveApps(string app)
{
bool error = false;
using (PowerShell script = PowerShell.Create())
{
script.AddScript("Get-AppxPackage " + app + " | Remove-AppxPackage");
script.Invoke();
error = script.HadErrors;
}
if (error)
{
removeAppsFailedList.Add(app);
}
else
{
removeAppsList.Add(app);
}
return;
}
private void RefreshApps()
{
int installed = listApps.Items.Count;
int remove = listRemove.Items.Count;
lblInstalled.Text = installed.ToString() + " apps installed";
lblBin.Text = "Recycle bin" + " (" + remove.ToString() + ")";
if (listRemove.Items.Count == 0)
{
rtbStatus.Visible = true;
listRemove.Visible = false;
}
else
{
rtbStatus.Visible = false;
listRemove.Visible = true;
}
if (installed == 0)
btnMoveAll.Enabled =
btnMove.Enabled =
false;
else
btnMoveAll.Enabled =
btnMove.Enabled =
true;
if (remove == 0)
btnRestoreAll.Enabled =
btnRestore.Enabled =
false;
else
btnRestoreAll.Enabled =
btnRestore.Enabled =
true;
}
private void btnRestoreAll_Click(object sender, EventArgs e)
{
foreach (var item in listRemove.Items)
{
listApps.Items.Add(item);
}
listRemove.Items.Clear();
RefreshApps();
}
private void btnRestore_Click(object sender, EventArgs e)
{
if (listRemove.Items.Count != 0)
{
if (listRemove.SelectedItem == null) listRemove.SelectedIndex = 0;
while (listRemove.SelectedItem != null)
{
listApps.Items.Add(listRemove.SelectedItem);
listRemove.Items.Remove(listRemove.SelectedItem);
}
RefreshApps();
}
}
private void btnMoveAll_Click(object sender, EventArgs e)
{
foreach (var item in listApps.Items)
{
listRemove.Items.Add(item);
}
listApps.Items.Clear();
RefreshApps();
}
private void btnMove_Click(object sender, EventArgs e)
{
if (listApps.Items.Count != 0)
{
if (listApps.SelectedItem == null) listApps.SelectedIndex = 0;
while (listApps.SelectedItem != null)
{
listRemove.Items.Add(listApps.SelectedItem);
listApps.Items.Remove(listApps.SelectedItem);
}
RefreshApps();
}
}
private void checkAppsSystem_CheckedChanged(object sender, EventArgs e)
{
if (checkAppsSystem.Checked)
{
MessageBox.Show("Be picky about which System applications to uninstall." +
"\n\nYou can uninstall most of the built-in apps, even ones that don't normally offer an \"Uninstall\" option." +
"\n\nNote, however, this app won't allow you to remove a few of the most important built-in apps, like Microsoft Edge, .NET framework, UI.Xaml etc. " +
"as these apps are needed for the Windows 11 \"Experience\" and for other programs. If you try, youll see an error message saying the removal failed.");
removeAppsList.Clear();
InitializeAppsSystem();
InitializeApps();
}
else
{
removeAppsList.Clear(); InitializeApps();
}
}
private async void btnUninstall_Click(object sender, EventArgs e)
{
string selectedApps = string.Empty;
string successList = string.Empty;
string failedList = string.Empty;
foreach (string app in listRemove.Items)
{
selectedApps += app + Environment.NewLine;
}
if (MessageBox.Show("Do you want to permanently delete all apps in the bin? ", this.Text, MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes)
{
removeAppsList.Clear();
removeAppsFailedList.Clear();
rtbStatus.Visible = true;
rtbStatus.Clear();
listRemove.Visible = false;
btnUninstall.Enabled = false;
foreach (string app in listRemove.Items)
{
rtbStatus.Text += Environment.NewLine + "Uninstalling " + app.ToString();
await Task.Run(() => RemoveApps(app));
}
foreach (var str in removeAppsList)
{
successList += "-" + str + Environment.NewLine;
}
foreach (var str in removeAppsFailedList)
{
failedList += "-" + str + Environment.NewLine;
}
// Summary removal process
string message = string.Format("Summary:\n{0} app(s) has been selected for removal.\n{1} app(s) has been removed.",
removeAppsList.Count + removeAppsFailedList.Count, removeAppsList.Count) + Environment.NewLine + Environment.NewLine;
if (removeAppsList.Count != 0)
{
message += "The folowing app(s) have been removed successfully:" + Environment.NewLine + successList + Environment.NewLine;
}
if (removeAppsFailedList.Count != 0)
{
message += "The following app(s) could not be removed: " + Environment.NewLine + failedList;
message += Environment.NewLine + "Note, however, this app won't allow you to remove a few of the most important built-in apps, like Microsoft Edge, .NET framework, UI.Xaml etc. " +
"as these apps are needed for the Windows 11 Experience and for other programs. If you try, youll see an error message saying the removal failed.";
}
btnRefresh.PerformClick();
btnUninstall.Enabled = true;
rtbStatus.Text = message + Environment.NewLine;
rtbStatus.Text += Environment.NewLine + listApps.Items.Count + " apps are left.\n";
}
}
private void lblBloatOpt1_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
{
if (MessageBox.Show("This will add all the annoying bloatware apps, " +
"pre-installed on Windows 11 including some apps your PC manufacturer included to the removal list." +
"\r\n\nMost of these apps are garbage, but if you find important stuff on the list just remove it " +
"from the right box before hitting \"Uninstall\".", this.Text, MessageBoxButtons.YesNo, MessageBoxIcon.Information) == DialogResult.Yes)
{
var apps = BloatwareList.GetList();
listRemove.Visible = true;
foreach (string app in apps)
{
listRemove.Items.Add(app);
}
InitializeApps();
RefreshApps();
lblBloatOpt1.Enabled = false;
}
}
private void lblBloatOpt2_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
{
var apps = BloatwareHallOfShame.GetList();
listRemove.Visible = true;
foreach (string app in apps)
{
listRemove.Items.Add(app);
}
InitializeApps();
RefreshApps();
lblBloatOpt2.Enabled = false;
}
private void textSearch_TextChanged(object sender, EventArgs e)
{
listApps.Items.Clear();
foreach (string str in removeAppsList)
{
if (str.IndexOf(textSearch.Text, 0, StringComparison.CurrentCultureIgnoreCase) != -1)
{
listApps.Items.Add(str);
}
}
}
private void textSearch_Click(object sender, EventArgs e)
=> textSearch.Text = "";
private void menuAppsImport_Click(object sender, EventArgs e)
{
OpenFileDialog f = new OpenFileDialog();
f.InitialDirectory = HelperTool.Utils.Data.DataRootDir;
if (f.ShowDialog() == DialogResult.OK)
{
List<string> lines = new List<string>();
using (StreamReader r = new StreamReader(f.OpenFile()))
{
listRemove.Items.Clear();
string line;
while ((line = r.ReadLine()) != null)
{
listRemove.Items.Add(line);
RefreshApps();
string compare = listApps.Items.ToString();
foreach (string item in listRemove.Items) if (item.Any(compare.Contains)) listApps.Items.Remove(item);
}
RefreshApps();
MessageBox.Show("We've synced your import list with the apps in Recycle bin.\n" +
"Please note, that some of these apps may not be installed on your system.", this.Text, MessageBoxButtons.OK, MessageBoxIcon.Information);
}
}
}
private void menuAppsExport_Click(object sender, EventArgs e)
{
if (listRemove.Items.Count == 0)
{
MessageBox.Show("No apps in Recycle bin found.");
return;
}
SaveFileDialog s = new SaveFileDialog();
s.FileName = "my-bloatware-list";
s.Filter = "Text File | *.txt";
if (s.ShowDialog() == DialogResult.OK)
{
StreamWriter writer = new StreamWriter(s.OpenFile());
for (int i = 0; i < listRemove.Items.Count; i++)
{
writer.WriteLine(listRemove.Items[i].ToString());
}
writer.Dispose();
writer.Close();
}
}
private void menuAppsRemoveAll_Click(object sender, EventArgs e)
{
if (MessageBox.Show("This will remove all pre-installed apps for the logged in user, except the Microsoft Store. Do you wish to continue?", this.Text, MessageBoxButtons.YesNo, MessageBoxIcon.Exclamation, MessageBoxDefaultButton.Button2) == DialogResult.Yes)
{
using (PowerShell script = PowerShell.Create())
{
this.Enabled = false;
script.AddScript("Get-appxprovisionedpackage online | where-object {$_.packagename notlike “*store*”} | Remove-AppxProvisionedPackage online");
script.AddScript("Get-AppxPackage | where-object {$_.name notlike “*store*”} | Remove-AppxPackage");
try
{
script.Invoke();
this.Enabled = true;
RefreshApps();
}
catch (Exception ex)
{ MessageBox.Show(ex.Message); }
}
}
}
private void btnRefresh_Click(object sender, EventArgs e)
{
listApps.Items.Clear();
listRemove.Items.Clear();
removeAppsList.Clear();
lblBloatOpt1.Enabled =
lblBloatOpt2.Enabled = true;
InitializeAppsSystem();
InitializeApps();
}
private void btnBack_Click(object sender, EventArgs e)
=> ViewHelper.SwitchView.SetMainFormAsView();
private void btnHMenu_Click(object sender, EventArgs e)
=> this.contextAppMenu.Show(Cursor.Position.X, Cursor.Position.Y);
}
}

View File

@ -0,0 +1,126 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="menuAppsExport.GenerateMember" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>False</value>
</metadata>
<metadata name="contextAppMenu.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
</root>

View File

@ -0,0 +1,410 @@
namespace Bloatynosy.Views
{
partial class NosyPageView
{
/// <summary>
/// Erforderliche Designervariable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Verwendete Ressourcen bereinigen.
/// </summary>
/// <param name="disposing">True, wenn verwaltete Ressourcen gelöscht werden sollen; andernfalls False.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Vom Komponenten-Designer generierter Code
/// <summary>
/// Erforderliche Methode für die Designerunterstützung.
/// Der Inhalt der Methode darf nicht mit dem Code-Editor geändert werden.
/// </summary>
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
this.tvwFeatures = new System.Windows.Forms.TreeView();
this.btnHamburger = new System.Windows.Forms.Button();
this.contextKebapMenu = new System.Windows.Forms.ContextMenuStrip(this.components);
this.textHeaderAppInfo = new System.Windows.Forms.ToolStripTextBox();
this.textHeaderExperience = new System.Windows.Forms.ToolStripTextBox();
this.cbProfiles = new System.Windows.Forms.ToolStripComboBox();
this.menuLoadProfile = new System.Windows.Forms.ToolStripMenuItem();
this.menuExportProfile = new System.Windows.Forms.ToolStripMenuItem();
this.btnNotePlugins = new System.Windows.Forms.Button();
this.contextAppMenuOptions = new System.Windows.Forms.ContextMenuStrip(this.components);
this.menuAnalyzeThis = new System.Windows.Forms.ToolStripMenuItem();
this.sc = new System.Windows.Forms.SplitContainer();
this.btnAnalyze = new System.Windows.Forms.Button();
this.lnkStatus = new System.Windows.Forms.LinkLabel();
this.lblHeader = new System.Windows.Forms.Label();
this.progress = new System.Windows.Forms.ProgressBar();
this.rtbLog = new System.Windows.Forms.RichTextBox();
this.btnApply = new System.Windows.Forms.Button();
this.btnRestore = new System.Windows.Forms.Button();
this.border = new System.Windows.Forms.Button();
this.pnlNav = new System.Windows.Forms.Panel();
this.contextKebapMenu.SuspendLayout();
this.contextAppMenuOptions.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.sc)).BeginInit();
this.sc.Panel1.SuspendLayout();
this.sc.Panel2.SuspendLayout();
this.sc.SuspendLayout();
this.pnlNav.SuspendLayout();
this.SuspendLayout();
//
// tvwFeatures
//
this.tvwFeatures.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.tvwFeatures.BackColor = System.Drawing.Color.White;
this.tvwFeatures.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.tvwFeatures.CheckBoxes = true;
this.tvwFeatures.Font = new System.Drawing.Font("Segoe UI Variable Text Light", 9.75F);
this.tvwFeatures.ForeColor = System.Drawing.Color.Black;
this.tvwFeatures.FullRowSelect = true;
this.tvwFeatures.ItemHeight = 37;
this.tvwFeatures.LineColor = System.Drawing.Color.DodgerBlue;
this.tvwFeatures.Location = new System.Drawing.Point(48, 14);
this.tvwFeatures.Name = "tvwFeatures";
this.tvwFeatures.ShowLines = false;
this.tvwFeatures.ShowNodeToolTips = true;
this.tvwFeatures.ShowRootLines = false;
this.tvwFeatures.Size = new System.Drawing.Size(195, 692);
this.tvwFeatures.TabIndex = 169;
this.tvwFeatures.AfterCheck += new System.Windows.Forms.TreeViewEventHandler(this.tvwFeatures_AfterCheck);
this.tvwFeatures.AfterSelect += new System.Windows.Forms.TreeViewEventHandler(this.tvwFeatures_AfterSelect);
this.tvwFeatures.MouseUp += new System.Windows.Forms.MouseEventHandler(this.tvwFeatures_MouseUp);
//
// btnHamburger
//
this.btnHamburger.FlatAppearance.BorderSize = 0;
this.btnHamburger.FlatAppearance.MouseOverBackColor = System.Drawing.Color.LightSteelBlue;
this.btnHamburger.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnHamburger.Font = new System.Drawing.Font("Segoe Fluent Icons", 9.75F, System.Drawing.FontStyle.Bold);
this.btnHamburger.ForeColor = System.Drawing.Color.Black;
this.btnHamburger.Location = new System.Drawing.Point(3, 2);
this.btnHamburger.Name = "btnHamburger";
this.btnHamburger.Size = new System.Drawing.Size(42, 38);
this.btnHamburger.TabIndex = 176;
this.btnHamburger.Text = "...";
this.btnHamburger.UseVisualStyleBackColor = true;
this.btnHamburger.Click += new System.EventHandler(this.btnHamburger_Click);
//
// contextKebapMenu
//
this.contextKebapMenu.BackColor = System.Drawing.Color.WhiteSmoke;
this.contextKebapMenu.Font = new System.Drawing.Font("Segoe UI Variable Text Semiligh", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.contextKebapMenu.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.textHeaderAppInfo,
this.textHeaderExperience,
this.cbProfiles,
this.menuLoadProfile,
this.menuExportProfile});
this.contextKebapMenu.Name = "menuMain";
this.contextKebapMenu.RenderMode = System.Windows.Forms.ToolStripRenderMode.System;
this.contextKebapMenu.Size = new System.Drawing.Size(261, 139);
//
// textHeaderAppInfo
//
this.textHeaderAppInfo.BackColor = System.Drawing.Color.WhiteSmoke;
this.textHeaderAppInfo.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.textHeaderAppInfo.Font = new System.Drawing.Font("Segoe UI Variable Text Semibold", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.textHeaderAppInfo.ForeColor = System.Drawing.Color.Gray;
this.textHeaderAppInfo.Margin = new System.Windows.Forms.Padding(5, 5, 0, 10);
this.textHeaderAppInfo.Name = "textHeaderAppInfo";
this.textHeaderAppInfo.ReadOnly = true;
this.textHeaderAppInfo.Size = new System.Drawing.Size(200, 18);
this.textHeaderAppInfo.Text = "App-Settings";
//
// textHeaderExperience
//
this.textHeaderExperience.BackColor = System.Drawing.Color.WhiteSmoke;
this.textHeaderExperience.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.textHeaderExperience.Font = new System.Drawing.Font("Segoe UI Variable Text Semibold", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.textHeaderExperience.ForeColor = System.Drawing.Color.MediumVioletRed;
this.textHeaderExperience.Margin = new System.Windows.Forms.Padding(5, 5, 0, 0);
this.textHeaderExperience.Name = "textHeaderExperience";
this.textHeaderExperience.Size = new System.Drawing.Size(200, 16);
this.textHeaderExperience.Text = "Choose Experience profile";
//
// cbProfiles
//
this.cbProfiles.AutoToolTip = true;
this.cbProfiles.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.cbProfiles.FlatStyle = System.Windows.Forms.FlatStyle.System;
this.cbProfiles.Font = new System.Drawing.Font("Segoe UI Variable Text", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.cbProfiles.Name = "cbProfiles";
this.cbProfiles.Size = new System.Drawing.Size(200, 25);
//
// menuLoadProfile
//
this.menuLoadProfile.Font = new System.Drawing.Font("Segoe UI Variable Text Semibold", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.menuLoadProfile.Name = "menuLoadProfile";
this.menuLoadProfile.Size = new System.Drawing.Size(260, 26);
this.menuLoadProfile.Text = "Load profile";
this.menuLoadProfile.Click += new System.EventHandler(this.menuLoadProfile_Click);
//
// menuExportProfile
//
this.menuExportProfile.Name = "menuExportProfile";
this.menuExportProfile.Size = new System.Drawing.Size(260, 26);
this.menuExportProfile.Text = "Export profile";
this.menuExportProfile.Click += new System.EventHandler(this.menuExportProfile_Click);
//
// btnNotePlugins
//
this.btnNotePlugins.AutoSize = true;
this.btnNotePlugins.FlatAppearance.BorderSize = 0;
this.btnNotePlugins.FlatAppearance.MouseOverBackColor = System.Drawing.Color.LightSteelBlue;
this.btnNotePlugins.Font = new System.Drawing.Font("Segoe Fluent Icons", 10.25F);
this.btnNotePlugins.ForeColor = System.Drawing.Color.DeepPink;
this.btnNotePlugins.Location = new System.Drawing.Point(3, 44);
this.btnNotePlugins.Name = "btnNotePlugins";
this.btnNotePlugins.Size = new System.Drawing.Size(42, 38);
this.btnNotePlugins.TabIndex = 177;
this.btnNotePlugins.Text = "...";
this.btnNotePlugins.UseVisualStyleBackColor = true;
this.btnNotePlugins.Click += new System.EventHandler(this.btnNotePlugins_Click);
//
// contextAppMenuOptions
//
this.contextAppMenuOptions.BackColor = System.Drawing.Color.WhiteSmoke;
this.contextAppMenuOptions.Font = new System.Drawing.Font("Segoe UI Variable Text Semiligh", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.contextAppMenuOptions.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.menuAnalyzeThis});
this.contextAppMenuOptions.Name = "menuMain";
this.contextAppMenuOptions.RenderMode = System.Windows.Forms.ToolStripRenderMode.System;
this.contextAppMenuOptions.Size = new System.Drawing.Size(163, 30);
//
// menuAnalyzeThis
//
this.menuAnalyzeThis.Name = "menuAnalyzeThis";
this.menuAnalyzeThis.Size = new System.Drawing.Size(162, 26);
this.menuAnalyzeThis.Text = "Analyze this";
this.menuAnalyzeThis.Click += new System.EventHandler(this.menuAnalyzeThis_Click);
//
// sc
//
this.sc.Dock = System.Windows.Forms.DockStyle.Fill;
this.sc.Location = new System.Drawing.Point(0, 0);
this.sc.Name = "sc";
//
// sc.Panel1
//
this.sc.Panel1.AutoScroll = true;
this.sc.Panel1.Controls.Add(this.btnAnalyze);
this.sc.Panel1.Controls.Add(this.tvwFeatures);
//
// sc.Panel2
//
this.sc.Panel2.AutoScroll = true;
this.sc.Panel2.BackColor = System.Drawing.SystemColors.Control;
this.sc.Panel2.Controls.Add(this.lnkStatus);
this.sc.Panel2.Controls.Add(this.lblHeader);
this.sc.Panel2.Controls.Add(this.progress);
this.sc.Panel2.Controls.Add(this.rtbLog);
this.sc.Panel2.Controls.Add(this.btnApply);
this.sc.Panel2.Controls.Add(this.btnRestore);
this.sc.Panel2.Controls.Add(this.border);
this.sc.Size = new System.Drawing.Size(942, 759);
this.sc.SplitterDistance = 246;
this.sc.TabIndex = 208;
this.sc.TabStop = false;
//
// btnAnalyze
//
this.btnAnalyze.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.btnAnalyze.AutoEllipsis = true;
this.btnAnalyze.BackColor = System.Drawing.Color.MediumVioletRed;
this.btnAnalyze.FlatAppearance.BorderColor = System.Drawing.Color.Gray;
this.btnAnalyze.FlatAppearance.BorderSize = 0;
this.btnAnalyze.Font = new System.Drawing.Font("Segoe UI Variable Display", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnAnalyze.ForeColor = System.Drawing.Color.White;
this.btnAnalyze.Location = new System.Drawing.Point(48, 705);
this.btnAnalyze.Name = "btnAnalyze";
this.btnAnalyze.Padding = new System.Windows.Forms.Padding(0, 0, 5, 0);
this.btnAnalyze.Size = new System.Drawing.Size(120, 35);
this.btnAnalyze.TabIndex = 215;
this.btnAnalyze.TabStop = false;
this.btnAnalyze.Text = "Analyze";
this.btnAnalyze.UseVisualStyleBackColor = false;
this.btnAnalyze.Click += new System.EventHandler(this.btnAnalyze_Click);
//
// lnkStatus
//
this.lnkStatus.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.lnkStatus.AutoEllipsis = true;
this.lnkStatus.BackColor = System.Drawing.Color.Transparent;
this.lnkStatus.Font = new System.Drawing.Font("Segoe UI Variable Text Semiligh", 9.75F);
this.lnkStatus.LinkBehavior = System.Windows.Forms.LinkBehavior.HoverUnderline;
this.lnkStatus.LinkColor = System.Drawing.Color.MediumVioletRed;
this.lnkStatus.Location = new System.Drawing.Point(16, 645);
this.lnkStatus.Name = "lnkStatus";
this.lnkStatus.Size = new System.Drawing.Size(437, 19);
this.lnkStatus.TabIndex = 214;
this.lnkStatus.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.lnkStatus_LinkClicked);
//
// lblHeader
//
this.lblHeader.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.lblHeader.AutoEllipsis = true;
this.lblHeader.BackColor = System.Drawing.Color.Transparent;
this.lblHeader.Font = new System.Drawing.Font("Segoe UI Variable Display Semib", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.lblHeader.ForeColor = System.Drawing.Color.Black;
this.lblHeader.Location = new System.Drawing.Point(14, 25);
this.lblHeader.Name = "lblHeader";
this.lblHeader.Size = new System.Drawing.Size(311, 32);
this.lblHeader.TabIndex = 210;
this.lblHeader.Text = "Dashboard";
//
// progress
//
this.progress.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.progress.Location = new System.Drawing.Point(9, 667);
this.progress.Name = "progress";
this.progress.Size = new System.Drawing.Size(427, 5);
this.progress.TabIndex = 166;
this.progress.Visible = false;
//
// rtbLog
//
this.rtbLog.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.rtbLog.BackColor = System.Drawing.Color.White;
this.rtbLog.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.rtbLog.Cursor = System.Windows.Forms.Cursors.IBeam;
this.rtbLog.Font = new System.Drawing.Font("Segoe UI Variable Display", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.rtbLog.ForeColor = System.Drawing.Color.DimGray;
this.rtbLog.HideSelection = false;
this.rtbLog.Location = new System.Drawing.Point(20, 106);
this.rtbLog.Name = "rtbLog";
this.rtbLog.ReadOnly = true;
this.rtbLog.Size = new System.Drawing.Size(433, 536);
this.rtbLog.TabIndex = 138;
this.rtbLog.Text = "Select all the ways you don\'t plan to use your device to get personalized tip, ad" +
"s, recommendation within Microsoft expericences. You can always revert these Set" +
"tings to default.";
//
// btnApply
//
this.btnApply.Anchor = System.Windows.Forms.AnchorStyles.Bottom;
this.btnApply.AutoEllipsis = true;
this.btnApply.BackColor = System.Drawing.Color.LightSteelBlue;
this.btnApply.FlatAppearance.BorderSize = 0;
this.btnApply.FlatStyle = System.Windows.Forms.FlatStyle.System;
this.btnApply.Font = new System.Drawing.Font("Segoe UI Variable Display", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnApply.ForeColor = System.Drawing.Color.Black;
this.btnApply.Location = new System.Drawing.Point(104, 705);
this.btnApply.Name = "btnApply";
this.btnApply.Size = new System.Drawing.Size(120, 35);
this.btnApply.TabIndex = 27;
this.btnApply.TabStop = false;
this.btnApply.Text = "Apply";
this.btnApply.UseVisualStyleBackColor = false;
this.btnApply.Click += new System.EventHandler(this.btnApply_Click);
//
// btnRestore
//
this.btnRestore.Anchor = System.Windows.Forms.AnchorStyles.Bottom;
this.btnRestore.AutoEllipsis = true;
this.btnRestore.BackColor = System.Drawing.Color.LightSteelBlue;
this.btnRestore.FlatAppearance.BorderSize = 0;
this.btnRestore.FlatStyle = System.Windows.Forms.FlatStyle.System;
this.btnRestore.Font = new System.Drawing.Font("Segoe UI Variable Display", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnRestore.ForeColor = System.Drawing.Color.Black;
this.btnRestore.Location = new System.Drawing.Point(230, 705);
this.btnRestore.Name = "btnRestore";
this.btnRestore.Padding = new System.Windows.Forms.Padding(0, 0, 5, 0);
this.btnRestore.Size = new System.Drawing.Size(120, 35);
this.btnRestore.TabIndex = 178;
this.btnRestore.TabStop = false;
this.btnRestore.Text = "Restore";
this.btnRestore.UseVisualStyleBackColor = false;
this.btnRestore.Click += new System.EventHandler(this.btnRestore_Click);
//
// border
//
this.border.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.border.BackColor = System.Drawing.SystemColors.Control;
this.border.FlatAppearance.BorderColor = System.Drawing.Color.Gainsboro;
this.border.FlatAppearance.BorderSize = 0;
this.border.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.border.Font = new System.Drawing.Font("Segoe UI Variable Text Semiligh", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.border.Location = new System.Drawing.Point(3, 14);
this.border.Name = "border";
this.border.Size = new System.Drawing.Size(462, 677);
this.border.TabIndex = 204;
this.border.TabStop = false;
this.border.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.border.UseVisualStyleBackColor = false;
//
// pnlNav
//
this.pnlNav.Controls.Add(this.btnNotePlugins);
this.pnlNav.Controls.Add(this.btnHamburger);
this.pnlNav.Dock = System.Windows.Forms.DockStyle.Left;
this.pnlNav.Location = new System.Drawing.Point(0, 0);
this.pnlNav.Name = "pnlNav";
this.pnlNav.Size = new System.Drawing.Size(49, 759);
this.pnlNav.TabIndex = 209;
//
// NosyPageView
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.Controls.Add(this.pnlNav);
this.Controls.Add(this.sc);
this.Name = "NosyPageView";
this.Size = new System.Drawing.Size(942, 759);
this.contextKebapMenu.ResumeLayout(false);
this.contextKebapMenu.PerformLayout();
this.contextAppMenuOptions.ResumeLayout(false);
this.sc.Panel1.ResumeLayout(false);
this.sc.Panel2.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.sc)).EndInit();
this.sc.ResumeLayout(false);
this.pnlNav.ResumeLayout(false);
this.pnlNav.PerformLayout();
this.ResumeLayout(false);
}
#endregion
internal System.Windows.Forms.TreeView tvwFeatures;
private System.Windows.Forms.Button btnHamburger;
private System.Windows.Forms.ContextMenuStrip contextKebapMenu;
private System.Windows.Forms.ToolStripTextBox textHeaderAppInfo;
private System.Windows.Forms.ToolStripTextBox textHeaderExperience;
private System.Windows.Forms.ToolStripComboBox cbProfiles;
private System.Windows.Forms.ToolStripMenuItem menuLoadProfile;
private System.Windows.Forms.ToolStripMenuItem menuExportProfile;
private System.Windows.Forms.Button btnNotePlugins;
private System.Windows.Forms.ContextMenuStrip contextAppMenuOptions;
private System.Windows.Forms.ToolStripMenuItem menuAnalyzeThis;
public System.Windows.Forms.SplitContainer sc;
private System.Windows.Forms.Label lblHeader;
private System.Windows.Forms.ProgressBar progress;
private System.Windows.Forms.Button btnApply;
private System.Windows.Forms.Button btnRestore;
private System.Windows.Forms.Button border;
private System.Windows.Forms.Panel pnlNav;
private System.Windows.Forms.LinkLabel lnkStatus;
private System.Windows.Forms.Button btnAnalyze;
private System.Windows.Forms.RichTextBox rtbLog;
}
}

View File

@ -0,0 +1,681 @@
using Bloatynosy.ITreeNode;
using Features.Feature;
using HelperTool;
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Runtime.CompilerServices;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace Bloatynosy.Views
{
public partial class NosyPageView : UserControl
{
private MainForm mainForm;
private static readonly ErrorHelper logger = ErrorHelper.Instance;
private int progression = 0;
private int progressionIncrease = 0;
public NosyPageView(MainForm mainForm)
{
InitializeComponent();
this.mainForm = mainForm;
this.AddDefaultFeatures();
this.SetStyle();
this.SetProfile();
}
private void SetStyle()
{
// Segoe MDL2 Assets
btnHamburger.Text = "\uE700";
btnNotePlugins.Text = "\uE8C3";
// Some color styling
pnlNav.BackColor = Color.FromArgb(245, 241, 249);
BackColor =
border.BackColor =
sc.Panel1.BackColor =
sc.Panel2.BackColor =
lblHeader.BackColor =
lnkStatus.BackColor =
rtbLog.BackColor = Color.FromArgb(243, 243, 243);
// Log messages to target richLog
logger.SetTarget(rtbLog);
// Border of middle page navigation
border.FlatAppearance.MouseOverBackColor = border.BackColor;
border.BackColorChanged += (s, e) =>
{
border.FlatAppearance.MouseOverBackColor = border.BackColor;
};
}
private void SetProfile()
{
cbProfiles.Items.Clear();
cbProfiles.Items.Insert(0, "Select profile");
cbProfiles.SelectedIndex = 0;
try
{
string[] files = Directory.GetFiles(HelperTool.Utils.Data.DataRootDir, "*.bloos");
cbProfiles.Items.AddRange(files.Select((string filePath) => Path.GetFileNameWithoutExtension(filePath)).ToArray());
}
catch { cbProfiles.Text = "No profiles found."; }
}
public void Reset()
{
progression = 0;
progressionIncrease = 0;
progress.Value = 0;
progress.Visible = true;
rtbLog.Visible = true;
rtbLog.Text = "";
}
private void DoProgress(int value)
{
progression = value;
progress.Value = progression;
}
private void IncrementProgress()
{
progression += progressionIncrease;
progress.Value = progression;
}
public void AddDefaultFeatures()
{
tvwFeatures.Nodes.Clear();
tvwFeatures.BeginUpdate();
// Root node
TreeNode root = new TreeNode("Potential issues on Windows 11 " + OsHelper.GetVersion())
{
Checked = true,
};
TreeNode browser = new TreeNode("1. Browser", new TreeNode[] {
new FeatureNode(new Features.Feature.Browser.EdgeBingAIButton()),
new FeatureNode(new Features.Feature.Browser.ChromeTelemetry()),
new FeatureNode(new Features.Feature.Browser.FirefoxTelemetry()),
})
{
Checked = true,
};
TreeNode explorer = new TreeNode("2. Explorer", new TreeNode[] {
new FeatureNode(new Features.Feature.Explorer.HiddenFileFolder()),
new FeatureNode(new Features.Feature.Explorer.HiddenFileExt()),
})
{
Checked = true,
};
TreeNode desktop = new TreeNode("3. Desktop", new System.Windows.Forms.TreeNode[] {
new FeatureNode(new Features.Feature.Desktop.AppsTheme()),
new FeatureNode(new Features.Feature.Desktop.WindowsTheme()),
new FeatureNode(new Features.Feature.Desktop.Transparency()),
new FeatureNode(new Features.Feature.Desktop.SnapAssistFlyout()),
new FeatureNode(new Features.Feature.Desktop.Widgets()),
new FeatureNode(new Features.Feature.Desktop.WidgetsRemove()),
new FeatureNode(new Features.Feature.Desktop.Stickers()),
})
{
Checked = true,
};
TreeNode taskbar = new TreeNode("4. Taskbar and Start menu", new System.Windows.Forms.TreeNode[] {
new FeatureNode(new Features.Feature.Taskbar.Copilot()),
new FeatureNode(new Features.Feature.Taskbar.TaskbarSearch()),
new FeatureNode(new Features.Feature.Taskbar.TaskbarChat()),
new FeatureNode(new Features.Feature.Taskbar.TaskView()),
new FeatureNode(new Features.Feature.Taskbar.MostUsedApps()),
new FeatureNode(new Features.Feature.Taskbar.StartmenuLayout()),
new FeatureNode(new Features.Feature.Taskbar.StartmenuSearch()),
})
{
Checked = true,
};
TreeNode system = new TreeNode("5. System", new System.Windows.Forms.TreeNode[] {
new FeatureNode(new Features.Feature.System.FullContextMenus()),
new FeatureNode(new Features.Feature.System.RemoveW11Watermark()),
new FeatureNode(new Features.Feature.System.TeamsAutostart()),
new FeatureNode(new Features.Feature.System.Fax()),
new FeatureNode(new Features.Feature.System.XPSWriter()),
new FeatureNode(new Features.Feature.System.TPMCheck()),
})
{
Checked = true,
};
TreeNode gaming = new TreeNode("6. Gaming", new TreeNode[] {
new FeatureNode(new Features.Feature.Gaming.GameDVR()),
new FeatureNode(new Features.Feature.Gaming.PowerThrottling()),
new FeatureNode(new Features.Feature.Gaming.VisualFX()),
})
{
Checked = true,
};
TreeNode privacy = new TreeNode("7. Privacy", new TreeNode[] {
new FeatureNode(new Features.Feature.Privacy.DiagnosticData()),
new FeatureNode(new Features.Feature.Privacy.Telemetry()),
new FeatureNode(new Features.Feature.Privacy.CompatibilityTelemetry()),
new FeatureNode(new Features.Feature.Privacy.LocationTracking()),
new FeatureNode(new Features.Feature.Privacy.Advertising()),
new FeatureNode(new Features.Feature.Privacy.Feedback()),
new FeatureNode(new Features.Feature.Privacy.SuggestedContent()),
new FeatureNode(new Features.Feature.Privacy.AppsAutoInstall()),
new FeatureNode(new Features.Feature.Privacy.WindowsTips()),
new FeatureNode(new Features.Feature.Privacy.TailoredExperiences()),
new FeatureNode(new Features.Feature.Privacy.BackgroundApps()),
})
{
Checked = true
};
TreeNode bloatware = new TreeNode("8. Bloatware", new TreeNode[] {
new FeatureNode(new Features.Feature.Bloatware.StoreApps()),
new FeatureNode(new Features.Feature.Bloatware.StoreAppsPrivate()),
new FeatureNode(new Features.Feature.Bloatware.OneDriveRemove()),
})
{
Checked = true,
};
root.Nodes.AddRange(new TreeNode[]
{
browser,
explorer,
desktop,
taskbar,
system,
gaming,
privacy,
bloatware,
});
tvwFeatures.Nodes.Add(root);
// 9. Plugins
List<string> pluginFiles = AddPluginFeatures(HelperTool.Utils.Data.PluginsRootDir);
if (pluginFiles.Count > 0)
{
// Create node for the plugins
TreeNode pluginsNode = new TreeNode("9. Plugins");
// Add PowerShell plugin files to the plugins node
foreach (string pluginFile in pluginFiles)
{
string fileName = Path.GetFileNameWithoutExtension(pluginFile);
pluginsNode.Nodes.Add(new TreeNode(fileName));
}
// Add plugins node to the root node
root.Nodes.Add(pluginsNode);
}
// Some tvw nicety
foreach (TreeNode tn in tvwFeatures.Nodes) { tn.Expand(); }
tvwFeatures.Nodes[0].NodeFont = new Font(tvwFeatures.Font, FontStyle.Bold);
tvwFeatures.EndUpdate();
}
private List<string> AddPluginFeatures(string directory)
{
List<string> pluginFiles = new List<string>();
try
{
// Get all PowerShell script files (*.ps1) in Plugins directory
string[] files = Directory.GetFiles(directory, "*.ps1", SearchOption.AllDirectories);
foreach (string file in files)
{
// Add script file path to list
pluginFiles.Add(file);
}
}
catch (Exception ex)
{
logger.Log("Error searching for Plugin files: " + ex.Message);
}
return pluginFiles;
}
public List<TreeNode> GetCheckedPluginNodes()
{
List<TreeNode> checkedNodes = new List<TreeNode>();
// Iterate through all root nodes in the tree view
foreach (TreeNode rootNode in tvwFeatures.Nodes)
{
// Check if root node has child nodes
if (rootNode.Nodes.Count > 0)
{
// Iterate through child nodes of the root
foreach (TreeNode childNode in rootNode.Nodes)
{
// Check if child node is a Plugins node
if (childNode.Text.Contains("Plugins"))
{
// Iterate through child nodes of Plugins node (plugin scripts) and add checked nodes
foreach (TreeNode scriptNode in childNode.Nodes)
{
// Debugging
// Console.WriteLine($"Plugin Node Text: {scriptNode.Text}, Checked: {scriptNode.Checked}");
if (scriptNode.Checked)
{
checkedNodes.Add(scriptNode);
}
}
}
}
}
}
// No checked nodes found?
if (checkedNodes.Count == 0)
{ // Debugging
// Console.WriteLine("No plugin script is checked");
}
return checkedNodes;
}
internal List<FeatureNode> CollectFeatureNodes()
{
List<FeatureNode> selectedFeatures = new List<FeatureNode>();
foreach (TreeNode treeNode in tvwFeatures.Nodes.All())
{
if (treeNode.Checked && treeNode.GetType() == typeof(FeatureNode))
{
selectedFeatures.Add((FeatureNode)treeNode);
}
}
progressionIncrease = (int)Math.Floor(100.0f / selectedFeatures.Count);
return selectedFeatures;
}
private void tvwFeatures_AfterCheck(object sender, TreeViewEventArgs e)
{
tvwFeatures.BeginUpdate();
foreach (TreeNode child in e.Node.Nodes)
{
child.Checked = e.Node.Checked;
}
tvwFeatures.EndUpdate();
}
private void tvwFeatures_AfterSelect(object sender, TreeViewEventArgs e)
{
if (e.Node is FeatureNode featureNode)
{
logger.ClearLog();
logger.Log(featureNode.GetFeatureInfo());
}
}
public void SelectFeatureNodes(TreeNodeCollection trNodeCollection, bool isCheck)
{
foreach (TreeNode trNode in trNodeCollection)
{
trNode.Checked = isCheck;
if (trNode.Nodes.Count > 0)
SelectFeatureNodes(trNode.Nodes, isCheck);
}
}
private void ResetColorNode(TreeNodeCollection nodes, Color Color)
{
foreach (System.Windows.Forms.TreeNode child in nodes)
{
child.BackColor = Color;
if (child.Nodes != null && child.Nodes.Count > 0)
ResetColorNode(child.Nodes, Color);
}
}
private void menuLoadProfile_Click(object sender, EventArgs e)
{
string filePath = HelperTool.Utils.Data.DataRootDir + "\\" + cbProfiles.Text + ".bloos";
ResetColorNode(tvwFeatures.Nodes, Color.White);
SelectFeatureNodes(tvwFeatures.Nodes, false);
tvwFeatures.ExpandAll();
tvwFeatures.Nodes[0].EnsureVisible();
try
{
using (StreamReader reader = new StreamReader(filePath))
{
while (!reader.EndOfStream)
{
string line = reader.ReadLine();
foreach (System.Windows.Forms.TreeNode treeNode in tvwFeatures.Nodes.All())
{
if (treeNode.Text.Contains(line))
{
treeNode.BackColor = Color.Yellow;
treeNode.Checked = true;
tvwFeatures.SelectedNode = treeNode;
}
}
}
if (new FileInfo(filePath).Length == 0) logger.Log("- Empty configuration loaded.");
}
btnAnalyze.PerformClick();
logger.Log($"[{cbProfiles.Text} has been successfully loaded].\nWe have highlighted the configuration that would be enabled (no changes are done yet).");
}
catch { { MessageBox.Show("No profile selected."); } }
}
private void menuExportProfile_Click(object sender, EventArgs e)
{
SaveFileDialog f = new SaveFileDialog();
f.InitialDirectory = HelperTool.Utils.Data.DataRootDir;
f.FileName = "Bloatynosy-profile";
f.Filter = "Bloatynosy files *.bloos|*.bloos";
if (f.ShowDialog() == DialogResult.OK)
{
using (StreamWriter writer = new StreamWriter(f.OpenFile()))
{
foreach (TreeNode treeNode in tvwFeatures.Nodes.All())
{
if (!treeNode.Checked)
continue;
writer.WriteLine(String.Format("{0}", treeNode.Text));
}
writer.Close();
}
MessageBox.Show("Profile has been successfully exported.", this.Text, MessageBoxButtons.OK, MessageBoxIcon.Information);
}
}
private FeatureNode GetSelectedFeatureNode()
{
if (tvwFeatures.SelectedNode is FeatureNode featureNode)
{
return featureNode;
}
return null;
}
private async Task<int> AnalyzeNode(FeatureNode node)
{
var feature = node.Feature;
ConfiguredTaskAwaitable<bool> analyzeTask = Task<bool>.Factory.StartNew(() => feature.CheckFeature()).ConfigureAwait(true);
bool shouldPerform = await analyzeTask;
// Console.WriteLine($"Analyzing feature: {feature.ID()}, shouldPerform: {shouldPerform}, node.Text: {node.Text}");
if (feature != null)
{
lnkStatus.Text = "Check " + feature.ID();
if (shouldPerform && (!mainForm.CheckIgnoreLowIssuesChecked || !node.Text.Contains("LOW")))
{
logger.Log("Problem on " + node.Parent.Text + ": " + feature.ID());
node.ForeColor = Color.MediumVioletRed;
return 1;
}
else
{
// Console.WriteLine($"No action required for feature: {feature.ID()}, shouldPerform: {shouldPerform}, node.Text: {node.Text}");
node.Checked = false;
node.ForeColor = Color.Gray;
}
}
return 0;
}
private async void menuAnalyzeThis_Click(object sender, EventArgs e)
{
Reset();
btnApply.Enabled = false;
int performFeaturesCount = 0;
// Check if any node is selected
FeatureNode selectedNode = GetSelectedFeatureNode();
if (selectedNode != null)
{
performFeaturesCount += await AnalyzeNode(selectedNode);
}
StringBuilder sum = new StringBuilder();
sum.Append(Environment.NewLine);
if (performFeaturesCount > 0)
{
sum.Append($"We've checked the selected feature of your Windows 11 installation.\r\n");
sum.Append($"We recommend to disable this feature.\r\n");
}
else
{
sum.Append($"The selected feature does not require action.\r\n");
}
logger.Log(sum.ToString(), "");
btnApply.Enabled = true;
lnkStatus.Text = $"There are {performFeaturesCount} features that require your attention.\r\n";
}
private void tvwFeatures_MouseUp(object sender, MouseEventArgs e)
{
if (e.Button == MouseButtons.Right)
{
tvwFeatures.SelectedNode = tvwFeatures.GetNodeAt(e.X, e.Y);
contextAppMenuOptions.Show(tvwFeatures, e.Location);
}
}
private async void btnApply_Click(object sender, EventArgs e)
{
if (MessageBox.Show("Do you want to apply selected fixes?", this.Text, MessageBoxButtons.YesNo, MessageBoxIcon.Information, MessageBoxDefaultButton.Button2) == DialogResult.Yes)
{
Reset();
// Apply regular features
List<FeatureNode> regularFeatureNodes = CollectFeatureNodes();
ApplyFeatures(regularFeatureNodes);
// Apply plugin features
List<TreeNode> checkedPluginNodes = GetCheckedPluginNodes();
if (checkedPluginNodes.Count > 0)
{
// Apply features from the checked plugin nodes
await ApplyPlugins(checkedPluginNodes);
}
}
}
private void btnRestore_Click(object sender, EventArgs e)
{
if (MessageBox.Show("Do you want to restore selected fixes to Windows default state?", this.Text, MessageBoxButtons.YesNo, MessageBoxIcon.Exclamation, MessageBoxDefaultButton.Button2) == DialogResult.Yes)
{
Reset();
List<FeatureNode> performNodes = CollectFeatureNodes();
UndoFeatures(performNodes);
}
}
private async Task ApplyPlugins(List<TreeNode> pluginNodes)
{
foreach (TreeNode selectedPluginNode in pluginNodes)
{
string pluginFilePath = Path.Combine(HelperTool.Utils.Data.PluginsRootDir, selectedPluginNode.Text + ".ps1");
try
{
// Call WindowsHelper > RunPowerShellScriptAsync
logger.Log($"Running plugin {selectedPluginNode.Text}...");
await WindowsHelper.RunPowerShellScript(pluginFilePath);
logger.Log($"- Running with plugin {selectedPluginNode.Text} [Done]");
}
catch (Exception ex)
{
logger.Log(ex.Message);
}
}
}
private async void ApplyFeatures(List<FeatureNode> treeNodes)
{
tvwFeatures.Enabled = false;
foreach (FeatureNode node in treeNodes)
{
var assessment = node.Feature;
ConfiguredTaskAwaitable<bool> performTask = Task<bool>.Factory.StartNew(() => assessment.DoFeature()).ConfigureAwait(true);
lnkStatus.Text = "Fixing " + node.Text;
var result = await performTask;
IncrementProgress();
}
DoProgress(100);
lnkStatus.Text = "Fixing complete (click for details).";
tvwFeatures.Enabled = true;
}
private async void UndoFeatures(List<FeatureNode> treeNodes)
{
tvwFeatures.Enabled = false;
foreach (FeatureNode node in treeNodes)
{
var assessment = node.Feature;
ConfiguredTaskAwaitable<bool> performTask = Task<bool>.Factory.StartNew(() => assessment.UndoFeature()).ConfigureAwait(true);
lnkStatus.Text = "Restore " + node.Text;
var result = await performTask;
IncrementProgress();
}
DoProgress(100);
lnkStatus.Text = "Undo complete (click for details).";
tvwFeatures.Enabled = true;
}
private async void btnAnalyze_Click(object sender, EventArgs e)
{
Reset();
btnApply.Enabled = false;
int performFeaturesCount = 0;
List<FeatureNode> selectedFeatures = CollectFeatureNodes();
foreach (FeatureNode node in selectedFeatures)
{
var feature = node.Feature;
ConfiguredTaskAwaitable<bool> analyzeTask = Task<bool>.Factory.StartNew(() => feature.CheckFeature()).ConfigureAwait(true);
bool shouldPerform = await analyzeTask;
if (feature != null)
{
lnkStatus.Text = "Check " + feature.ID();
if (mainForm.CheckIgnoreLowIssuesChecked == true)
if (shouldPerform & !node.Text.Contains("LOW"))
{
logger.Log(node.Parent.Text + ": " + feature.ID());
performFeaturesCount += 1;
node.ForeColor = Color.MediumVioletRed;
}
else
{
node.Checked = false; // Uncheck all fixed
node.ForeColor = Color.Gray;
}
else if (shouldPerform)
{
logger.Log(node.Parent.Text + ": " + feature.ID());
performFeaturesCount += 1;
node.ForeColor = Color.MediumVioletRed;
}
else
{
node.Checked = false;
node.ForeColor = Color.Gray;
}
}
}
tvwFeatures.ExpandAll();
DoProgress(100);
StringBuilder sum = new StringBuilder();
sum.Append(Environment.NewLine);
sum.Append("======= Summary =======\n");
sum.Append($"We've checked {selectedFeatures.Count} features of your Windows 11 installation.\r\n");
sum.Append($"We like {selectedFeatures.Count - performFeaturesCount} of these features (no need for action).\r\n");
sum.Append($"We recommend to disable {performFeaturesCount} of these features (highlighted in color).\r\n");
logger.Log(sum.ToString(), "");
btnApply.Enabled = true;
lnkStatus.Text = $"There are {performFeaturesCount} features which require your attention.\r\n";
}
private void btnHamburger_Click(object sender, EventArgs e)
=> this.contextKebapMenu.Show(Cursor.Position.X, Cursor.Position.Y);
private void btnNotePlugins_Click(object sender, EventArgs e)
{
string message = "This version introduces an integrated plugin function that replaces the old WinModder module. The plugin scripts still rely on PowerShell code. Please note that as of today, no analysis takes place, and the plugins can only be applied.";
MessageBox.Show(message, "Information", MessageBoxButtons.OK, MessageBoxIcon.Information);
}
private void lnkStatus_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
{
// Extract summary from Status text
string summary = lnkStatus.Text.Replace("======= Summary =======", "").Trim();
DialogResult result = MessageBox.Show(
"Summary of problems:\n" + summary + "\n\nDo you want to ask the community for advice on applying these changes?",
"Analysis advice",
MessageBoxButtons.YesNo,
MessageBoxIcon.Question
);
if (result == DialogResult.Yes)
{
Process.Start(HelperTool.Utils.Uri.URL_HELP);
}
}
}
}

View File

@ -0,0 +1,126 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="contextKebapMenu.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
<metadata name="contextAppMenuOptions.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>180, 19</value>
</metadata>
</root>

View File

@ -0,0 +1,273 @@
namespace Bloatynosy.Views
{
partial class PackagesPageView
{
/// <summary>
/// Erforderliche Designervariable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Verwendete Ressourcen bereinigen.
/// </summary>
/// <param name="disposing">True, wenn verwaltete Ressourcen gelöscht werden sollen; andernfalls False.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Vom Komponenten-Designer generierter Code
/// <summary>
/// Erforderliche Methode für die Designerunterstützung.
/// Der Inhalt der Methode darf nicht mit dem Code-Editor geändert werden.
/// </summary>
private void InitializeComponent()
{
this.btnRemoveAll = new System.Windows.Forms.Button();
this.listLocal = new System.Windows.Forms.ListBox();
this.btnRemove = new System.Windows.Forms.Button();
this.btnAddAll = new System.Windows.Forms.Button();
this.btnAdd = new System.Windows.Forms.Button();
this.btnBack = new System.Windows.Forms.Button();
this.textSearch = new System.Windows.Forms.TextBox();
this.lblRemote = new System.Windows.Forms.Label();
this.listRemote = new System.Windows.Forms.ListBox();
this.richStatus = new System.Windows.Forms.RichTextBox();
this.lblHeader = new System.Windows.Forms.Label();
this.lblLocal = new System.Windows.Forms.Label();
this.btnInstall = new System.Windows.Forms.Button();
this.SuspendLayout();
//
// btnRemoveAll
//
this.btnRemoveAll.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right)));
this.btnRemoveAll.AutoEllipsis = true;
this.btnRemoveAll.Font = new System.Drawing.Font("Segoe UI Variable Text", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnRemoveAll.ForeColor = System.Drawing.Color.Black;
this.btnRemoveAll.Location = new System.Drawing.Point(436, 405);
this.btnRemoveAll.Name = "btnRemoveAll";
this.btnRemoveAll.Size = new System.Drawing.Size(239, 23);
this.btnRemoveAll.TabIndex = 45;
this.btnRemoveAll.Text = "<< Remove all";
this.btnRemoveAll.UseVisualStyleBackColor = true;
this.btnRemoveAll.Click += new System.EventHandler(this.btnRemoveAll_Click);
//
// listLocal
//
this.listLocal.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Right)));
this.listLocal.BackColor = System.Drawing.Color.White;
this.listLocal.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.listLocal.Font = new System.Drawing.Font("Segoe UI Variable Text Semiligh", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.listLocal.FormattingEnabled = true;
this.listLocal.ItemHeight = 17;
this.listLocal.Location = new System.Drawing.Point(823, 107);
this.listLocal.Name = "listLocal";
this.listLocal.SelectionMode = System.Windows.Forms.SelectionMode.MultiExtended;
this.listLocal.Size = new System.Drawing.Size(270, 646);
this.listLocal.Sorted = true;
this.listLocal.TabIndex = 13;
//
// btnRemove
//
this.btnRemove.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right)));
this.btnRemove.AutoEllipsis = true;
this.btnRemove.Font = new System.Drawing.Font("Segoe UI Variable Text", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnRemove.ForeColor = System.Drawing.Color.Black;
this.btnRemove.Location = new System.Drawing.Point(436, 376);
this.btnRemove.Name = "btnRemove";
this.btnRemove.Size = new System.Drawing.Size(239, 23);
this.btnRemove.TabIndex = 43;
this.btnRemove.Text = "< Remove";
this.btnRemove.UseVisualStyleBackColor = true;
this.btnRemove.Click += new System.EventHandler(this.btnRemove_Click);
//
// btnAddAll
//
this.btnAddAll.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right)));
this.btnAddAll.AutoEllipsis = true;
this.btnAddAll.Font = new System.Drawing.Font("Segoe UI Variable Text", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnAddAll.ForeColor = System.Drawing.Color.Black;
this.btnAddAll.Location = new System.Drawing.Point(436, 293);
this.btnAddAll.Name = "btnAddAll";
this.btnAddAll.Size = new System.Drawing.Size(239, 23);
this.btnAddAll.TabIndex = 46;
this.btnAddAll.Text = "Add all >>";
this.btnAddAll.Click += new System.EventHandler(this.btnAddAll_Click);
//
// btnAdd
//
this.btnAdd.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right)));
this.btnAdd.AutoEllipsis = true;
this.btnAdd.Font = new System.Drawing.Font("Segoe UI Variable Text", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnAdd.ForeColor = System.Drawing.Color.Black;
this.btnAdd.Location = new System.Drawing.Point(436, 264);
this.btnAdd.Name = "btnAdd";
this.btnAdd.Size = new System.Drawing.Size(239, 23);
this.btnAdd.TabIndex = 42;
this.btnAdd.Text = "Add >";
this.btnAdd.UseVisualStyleBackColor = true;
this.btnAdd.Click += new System.EventHandler(this.btnAdd_Click);
//
// btnBack
//
this.btnBack.FlatAppearance.BorderSize = 0;
this.btnBack.FlatAppearance.MouseOverBackColor = System.Drawing.Color.WhiteSmoke;
this.btnBack.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnBack.Font = new System.Drawing.Font("Segoe Fluent Icons", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnBack.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.btnBack.Location = new System.Drawing.Point(0, 0);
this.btnBack.Name = "btnBack";
this.btnBack.Size = new System.Drawing.Size(42, 38);
this.btnBack.TabIndex = 177;
this.btnBack.Text = "...";
this.btnBack.UseVisualStyleBackColor = true;
this.btnBack.Click += new System.EventHandler(this.btnBack_Click);
//
// textSearch
//
this.textSearch.Anchor = System.Windows.Forms.AnchorStyles.Top;
this.textSearch.BackColor = System.Drawing.Color.WhiteSmoke;
this.textSearch.Font = new System.Drawing.Font("Segoe UI Variable Display", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.textSearch.ForeColor = System.Drawing.Color.Gray;
this.textSearch.Location = new System.Drawing.Point(485, 66);
this.textSearch.Name = "textSearch";
this.textSearch.Size = new System.Drawing.Size(149, 25);
this.textSearch.TabIndex = 180;
this.textSearch.Text = "Search";
this.textSearch.Click += new System.EventHandler(this.textSearch_Click);
this.textSearch.TextChanged += new System.EventHandler(this.textSearch_TextChanged);
//
// lblRemote
//
this.lblRemote.AutoSize = true;
this.lblRemote.Font = new System.Drawing.Font("Segoe UI Variable Display", 9.75F);
this.lblRemote.ForeColor = System.Drawing.Color.Black;
this.lblRemote.Location = new System.Drawing.Point(42, 70);
this.lblRemote.Name = "lblRemote";
this.lblRemote.Size = new System.Drawing.Size(54, 17);
this.lblRemote.TabIndex = 186;
this.lblRemote.Text = "Remote";
//
// listRemote
//
this.listRemote.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)));
this.listRemote.BackColor = System.Drawing.Color.White;
this.listRemote.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.listRemote.Font = new System.Drawing.Font("Segoe UI Variable Text Semiligh", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.listRemote.FormattingEnabled = true;
this.listRemote.ItemHeight = 17;
this.listRemote.Location = new System.Drawing.Point(44, 99);
this.listRemote.Name = "listRemote";
this.listRemote.SelectionMode = System.Windows.Forms.SelectionMode.MultiExtended;
this.listRemote.Size = new System.Drawing.Size(270, 629);
this.listRemote.Sorted = true;
this.listRemote.TabIndex = 13;
//
// richStatus
//
this.richStatus.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Right)));
this.richStatus.BackColor = System.Drawing.Color.White;
this.richStatus.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.richStatus.Font = new System.Drawing.Font("Segoe UI Variable Text", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.richStatus.ForeColor = System.Drawing.Color.Black;
this.richStatus.HideSelection = false;
this.richStatus.Location = new System.Drawing.Point(823, 107);
this.richStatus.Name = "richStatus";
this.richStatus.ReadOnly = true;
this.richStatus.ScrollBars = System.Windows.Forms.RichTextBoxScrollBars.Vertical;
this.richStatus.Size = new System.Drawing.Size(270, 646);
this.richStatus.TabIndex = 140;
this.richStatus.Text = "";
this.richStatus.Visible = false;
//
// lblHeader
//
this.lblHeader.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.lblHeader.AutoEllipsis = true;
this.lblHeader.Font = new System.Drawing.Font("Segoe UI Variable Text Semibold", 18.25F, System.Drawing.FontStyle.Bold);
this.lblHeader.ForeColor = System.Drawing.Color.Black;
this.lblHeader.Location = new System.Drawing.Point(286, 31);
this.lblHeader.Name = "lblHeader";
this.lblHeader.Size = new System.Drawing.Size(523, 32);
this.lblHeader.TabIndex = 188;
this.lblHeader.Text = "Packages";
this.lblHeader.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// lblLocal
//
this.lblLocal.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.lblLocal.AutoSize = true;
this.lblLocal.Font = new System.Drawing.Font("Segoe UI Variable Display", 9.75F);
this.lblLocal.ForeColor = System.Drawing.Color.Black;
this.lblLocal.Location = new System.Drawing.Point(820, 79);
this.lblLocal.Name = "lblLocal";
this.lblLocal.Size = new System.Drawing.Size(38, 17);
this.lblLocal.TabIndex = 189;
this.lblLocal.Text = "Local";
//
// btnInstall
//
this.btnInstall.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.btnInstall.BackColor = System.Drawing.Color.MediumVioletRed;
this.btnInstall.FlatAppearance.BorderSize = 0;
this.btnInstall.Font = new System.Drawing.Font("Segoe UI Variable Display", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnInstall.ForeColor = System.Drawing.Color.White;
this.btnInstall.Location = new System.Drawing.Point(815, 34);
this.btnInstall.Name = "btnInstall";
this.btnInstall.Size = new System.Drawing.Size(181, 35);
this.btnInstall.TabIndex = 191;
this.btnInstall.Text = "Install packages";
this.btnInstall.UseVisualStyleBackColor = false;
this.btnInstall.Click += new System.EventHandler(this.btnInstall_Click);
//
// PackagesPageView
//
this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Dpi;
this.AutoScroll = true;
this.BackColor = System.Drawing.Color.White;
this.Controls.Add(this.btnInstall);
this.Controls.Add(this.lblLocal);
this.Controls.Add(this.lblHeader);
this.Controls.Add(this.listRemote);
this.Controls.Add(this.lblRemote);
this.Controls.Add(this.textSearch);
this.Controls.Add(this.btnBack);
this.Controls.Add(this.btnRemove);
this.Controls.Add(this.btnAdd);
this.Controls.Add(this.richStatus);
this.Controls.Add(this.listLocal);
this.Controls.Add(this.btnAddAll);
this.Controls.Add(this.btnRemoveAll);
this.Name = "PackagesPageView";
this.Size = new System.Drawing.Size(1107, 805);
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.Button btnRemoveAll;
private System.Windows.Forms.ListBox listLocal;
private System.Windows.Forms.Button btnRemove;
private System.Windows.Forms.Button btnAddAll;
private System.Windows.Forms.Button btnAdd;
private System.Windows.Forms.Button btnBack;
private System.Windows.Forms.TextBox textSearch;
private System.Windows.Forms.Label lblRemote;
private System.Windows.Forms.ListBox listRemote;
public System.Windows.Forms.RichTextBox richStatus;
private System.Windows.Forms.Label lblHeader;
private System.Windows.Forms.Label lblLocal;
private System.Windows.Forms.Button btnInstall;
}
}

View File

@ -0,0 +1,212 @@
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Drawing;
using System.IO;
using System.Net;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace Bloatynosy.Views
{
public partial class PackagesPageView : UserControl
{
private List<string> Packages = new List<string>();
private List<string> remoteApps = new List<string>();
private string fPackagesLocal = HelperTool.Utils.Data.DataRootDir + "Packages.app";
public PackagesPageView()
{
InitializeComponent();
RequestPackagesRemote();
listRemote.Items.AddRange(remoteApps.ToArray());
GetPackagesLocal();
SetStyle();
}
// Some UI nicety
private void SetStyle()
{
// Segoe MDL2 Assets
btnBack.Text = "\uE72B";
// Some color styling
BackColor =
listRemote.BackColor =
listLocal.BackColor =
richStatus.BackColor =
Color.FromArgb(245, 241, 249);
}
public void RequestPackagesRemote()
{
try
{
var webRequest = WebRequest.Create(@"https://raw.githubusercontent.com/builtbybel/Bloatynosy/main/assets/packages.git");
string app;
using (var response = webRequest.GetResponse())
using (var content = response.GetResponseStream())
using (var sr = new StreamReader(content))
{
while ((app = sr.ReadLine()) != null)
{
{
if (!app.StartsWith("#") && (!string.IsNullOrEmpty(app)))
{
remoteApps.Add(app);
}
}
}
}
}
catch (Exception ex)
{ MessageBox.Show(ex.Message); }
}
public void GetPackagesLocal()
{
if (File.Exists(fPackagesLocal))
{
string[] appsInstall = File.ReadAllLines(fPackagesLocal);
listRemote.Items.Clear();
lblRemote.Text = "Offline packages";
foreach (var currentApp in appsInstall)
{
if (!currentApp.StartsWith("#") && (!string.IsNullOrEmpty(currentApp)))
{
listRemote.Items.Add(currentApp.ToString());
}
}
}
else return;
}
private void textSearch_TextChanged(object sender, EventArgs e)
{
listRemote.Items.Clear();
foreach (string str in remoteApps)
{
if (str.IndexOf(textSearch.Text, 0, StringComparison.CurrentCultureIgnoreCase) != -1)
{
listRemote.Items.Add(str);
}
}
}
private void btnAddAll_Click(object sender, EventArgs e)
{
foreach (var item in listRemote.Items)
{
listLocal.Items.Add(item);
}
listRemote.Items.Clear();
RefreshPackages();
}
private void btnAdd_Click(object sender, EventArgs e)
{
if (listRemote.Items.Count != 0)
{
if (listRemote.SelectedItem == null) listRemote.SelectedIndex = 0;
while (listRemote.SelectedItem != null)
{
listLocal.Items.Add(listRemote.SelectedItem);
listRemote.Items.Remove(listRemote.SelectedItem);
}
RefreshPackages();
}
}
private void btnRemove_Click(object sender, EventArgs e)
{
if (listLocal.Items.Count != 0)
{
if (listLocal.SelectedItem == null) listLocal.SelectedIndex = 0;
while (listLocal.SelectedItem != null)
{
listRemote.Items.Add(listLocal.SelectedItem);
listLocal.Items.Remove(listLocal.SelectedItem);
}
RefreshPackages();
}
}
private void btnRemoveAll_Click(object sender, EventArgs e)
{
foreach (var item in listLocal.Items)
{
listRemote.Items.Add(item);
}
listLocal.Items.Clear();
RefreshPackages();
}
public void WingetInstallPackage(string packageid)
{
var proc = new Process
{
StartInfo = new ProcessStartInfo
{
FileName = HelperTool.Utils.Paths.ShellPS,
Arguments = "winget install --id " + packageid + " --silent --accept-source-agreements --accept-package-agreements",
UseShellExecute = false,
CreateNoWindow = true,
}
};
proc.Start();
proc.WaitForExit();
}
private void RefreshPackages()
{
if (listLocal.Items.Count == 0)
{
richStatus.Visible = true;
listLocal.Visible = false;
}
else
{
listLocal.Visible = true;
richStatus.Visible = false;
}
}
private async void btnInstall_Click(object sender, EventArgs e)
{
richStatus.Visible = true;
listLocal.Visible = false;
btnInstall.Enabled = false;
StringBuilder message = new StringBuilder();
foreach (string p in listLocal.Items)
{
Packages.Add(p);
}
foreach (string p in Packages)
{
richStatus.Text += Environment.NewLine + "Installing -" + p;
await Task.Run(() => WingetInstallPackage(p));
}
lblLocal.Text = "The following apps have been installed";
listLocal.Visible = true;
btnInstall.Enabled = true;
richStatus.Visible = false;
}
private void btnBack_Click(object sender, EventArgs e)
=> ViewHelper.SwitchView.SetMainFormAsView();
private void textSearch_Click(object sender, EventArgs e)
=> textSearch.Text = "";
}
}

View File

@ -0,0 +1,120 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@ -0,0 +1,243 @@
namespace Bloatynosy.Views
{
partial class WizardPageView
{
/// <summary>
/// Erforderliche Designervariable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Verwendete Ressourcen bereinigen.
/// </summary>
/// <param name="disposing">True, wenn verwaltete Ressourcen gelöscht werden sollen; andernfalls False.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Vom Komponenten-Designer generierter Code
/// <summary>
/// Erforderliche Methode für die Designerunterstützung.
/// Der Inhalt der Methode darf nicht mit dem Code-Editor geändert werden.
/// </summary>
private void InitializeComponent()
{
this.lblHeader = new System.Windows.Forms.Label();
this.btnBack = new System.Windows.Forms.Button();
this.btnHome = new System.Windows.Forms.Button();
this.btnNext = new System.Windows.Forms.Button();
this.btnPrev = new System.Windows.Forms.Button();
this.cbTable = new System.Windows.Forms.ComboBox();
this.pbView = new System.Windows.Forms.PictureBox();
this.label1 = new System.Windows.Forms.Label();
this.btnAssist = new System.Windows.Forms.Button();
this.lnkConfigure = new System.Windows.Forms.LinkLabel();
this.btnCustomize = new System.Windows.Forms.Button();
((System.ComponentModel.ISupportInitialize)(this.pbView)).BeginInit();
this.SuspendLayout();
//
// lblHeader
//
this.lblHeader.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.lblHeader.AutoEllipsis = true;
this.lblHeader.Font = new System.Drawing.Font("Segoe UI Variable Text Semibold", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.lblHeader.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.lblHeader.Location = new System.Drawing.Point(60, 4);
this.lblHeader.Name = "lblHeader";
this.lblHeader.Size = new System.Drawing.Size(973, 26);
this.lblHeader.TabIndex = 180;
this.lblHeader.Text = "Setup Windows";
//
// btnBack
//
this.btnBack.FlatAppearance.BorderSize = 0;
this.btnBack.FlatAppearance.MouseOverBackColor = System.Drawing.Color.WhiteSmoke;
this.btnBack.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnBack.Font = new System.Drawing.Font("Segoe Fluent Icons", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnBack.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.btnBack.Location = new System.Drawing.Point(0, 0);
this.btnBack.Name = "btnBack";
this.btnBack.Size = new System.Drawing.Size(42, 38);
this.btnBack.TabIndex = 179;
this.btnBack.Text = "...";
this.btnBack.UseVisualStyleBackColor = true;
this.btnBack.Click += new System.EventHandler(this.btnBack_Click);
//
// btnHome
//
this.btnHome.AutoEllipsis = true;
this.btnHome.BackColor = System.Drawing.Color.Gainsboro;
this.btnHome.FlatAppearance.BorderSize = 0;
this.btnHome.Font = new System.Drawing.Font("Segoe UI Variable Display", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnHome.ForeColor = System.Drawing.Color.Black;
this.btnHome.Location = new System.Drawing.Point(42, 82);
this.btnHome.Name = "btnHome";
this.btnHome.Size = new System.Drawing.Size(212, 29);
this.btnHome.TabIndex = 182;
this.btnHome.Text = "Home";
this.btnHome.UseVisualStyleBackColor = false;
this.btnHome.Click += new System.EventHandler(this.btnHome_Click);
//
// btnNext
//
this.btnNext.AutoEllipsis = true;
this.btnNext.BackColor = System.Drawing.Color.Gainsboro;
this.btnNext.FlatAppearance.BorderSize = 0;
this.btnNext.Font = new System.Drawing.Font("Segoe UI Variable Display", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnNext.ForeColor = System.Drawing.Color.Black;
this.btnNext.Location = new System.Drawing.Point(42, 168);
this.btnNext.Name = "btnNext";
this.btnNext.Size = new System.Drawing.Size(212, 29);
this.btnNext.TabIndex = 183;
this.btnNext.Text = "Next";
this.btnNext.UseVisualStyleBackColor = false;
this.btnNext.Click += new System.EventHandler(this.btnNext_Click);
//
// btnPrev
//
this.btnPrev.AutoEllipsis = true;
this.btnPrev.BackColor = System.Drawing.Color.Gainsboro;
this.btnPrev.FlatAppearance.BorderSize = 0;
this.btnPrev.Font = new System.Drawing.Font("Segoe UI Variable Display", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnPrev.ForeColor = System.Drawing.Color.Black;
this.btnPrev.Location = new System.Drawing.Point(42, 133);
this.btnPrev.Name = "btnPrev";
this.btnPrev.Size = new System.Drawing.Size(212, 29);
this.btnPrev.TabIndex = 184;
this.btnPrev.Text = "Previous";
this.btnPrev.UseVisualStyleBackColor = false;
this.btnPrev.Click += new System.EventHandler(this.btnPrev_Click);
//
// cbTable
//
this.cbTable.BackColor = System.Drawing.Color.White;
this.cbTable.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.cbTable.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.cbTable.Font = new System.Drawing.Font("Segoe UI Variable Text Semiligh", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.cbTable.FormattingEnabled = true;
this.cbTable.Location = new System.Drawing.Point(42, 256);
this.cbTable.Name = "cbTable";
this.cbTable.Size = new System.Drawing.Size(212, 25);
this.cbTable.TabIndex = 185;
this.cbTable.SelectedIndexChanged += new System.EventHandler(this.cbTable_SelectedIndexChanged);
//
// pbView
//
this.pbView.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.pbView.BackColor = System.Drawing.Color.Transparent;
this.pbView.ErrorImage = null;
this.pbView.ImeMode = System.Windows.Forms.ImeMode.NoControl;
this.pbView.InitialImage = null;
this.pbView.Location = new System.Drawing.Point(272, 42);
this.pbView.Name = "pbView";
this.pbView.Size = new System.Drawing.Size(779, 437);
this.pbView.SizeMode = System.Windows.Forms.PictureBoxSizeMode.AutoSize;
this.pbView.TabIndex = 186;
this.pbView.TabStop = false;
//
// label1
//
this.label1.AutoSize = true;
this.label1.Font = new System.Drawing.Font("Segoe UI Variable Display Semib", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label1.Location = new System.Drawing.Point(39, 238);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(49, 15);
this.label1.TabIndex = 189;
this.label1.Text = "Jump to";
//
// btnAssist
//
this.btnAssist.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.btnAssist.FlatAppearance.BorderColor = System.Drawing.Color.Gainsboro;
this.btnAssist.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnAssist.Font = new System.Drawing.Font("Segoe UI Variable Text Semiligh", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnAssist.Location = new System.Drawing.Point(289, 447);
this.btnAssist.Name = "btnAssist";
this.btnAssist.Size = new System.Drawing.Size(762, 200);
this.btnAssist.TabIndex = 190;
this.btnAssist.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.btnAssist.UseVisualStyleBackColor = true;
//
// lnkConfigure
//
this.lnkConfigure.ActiveLinkColor = System.Drawing.Color.HotPink;
this.lnkConfigure.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.lnkConfigure.AutoEllipsis = true;
this.lnkConfigure.Font = new System.Drawing.Font("Segoe UI Variable Display", 10.25F);
this.lnkConfigure.LinkBehavior = System.Windows.Forms.LinkBehavior.HoverUnderline;
this.lnkConfigure.LinkColor = System.Drawing.Color.MediumVioletRed;
this.lnkConfigure.Location = new System.Drawing.Point(657, 668);
this.lnkConfigure.Name = "lnkConfigure";
this.lnkConfigure.Size = new System.Drawing.Size(160, 19);
this.lnkConfigure.TabIndex = 192;
this.lnkConfigure.TabStop = true;
this.lnkConfigure.Text = "Configure settings";
this.lnkConfigure.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.lnkConfigure_LinkClicked);
//
// btnCustomize
//
this.btnCustomize.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.btnCustomize.AutoEllipsis = true;
this.btnCustomize.BackColor = System.Drawing.Color.MediumVioletRed;
this.btnCustomize.FlatAppearance.BorderColor = System.Drawing.Color.Gray;
this.btnCustomize.FlatAppearance.BorderSize = 0;
this.btnCustomize.Font = new System.Drawing.Font("Segoe UI Variable Display", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnCustomize.ForeColor = System.Drawing.Color.White;
this.btnCustomize.Location = new System.Drawing.Point(823, 661);
this.btnCustomize.Name = "btnCustomize";
this.btnCustomize.Padding = new System.Windows.Forms.Padding(0, 0, 5, 0);
this.btnCustomize.Size = new System.Drawing.Size(210, 35);
this.btnCustomize.TabIndex = 218;
this.btnCustomize.TabStop = false;
this.btnCustomize.Text = "Customizations available";
this.btnCustomize.UseVisualStyleBackColor = false;
this.btnCustomize.Click += new System.EventHandler(this.btnCustomize_Click);
//
// WizardPageView
//
this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Dpi;
this.AutoScroll = true;
this.Controls.Add(this.btnCustomize);
this.Controls.Add(this.lnkConfigure);
this.Controls.Add(this.btnAssist);
this.Controls.Add(this.label1);
this.Controls.Add(this.cbTable);
this.Controls.Add(this.btnPrev);
this.Controls.Add(this.btnNext);
this.Controls.Add(this.btnHome);
this.Controls.Add(this.lblHeader);
this.Controls.Add(this.btnBack);
this.Controls.Add(this.pbView);
this.Name = "WizardPageView";
this.Size = new System.Drawing.Size(1054, 795);
((System.ComponentModel.ISupportInitialize)(this.pbView)).EndInit();
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.Label lblHeader;
private System.Windows.Forms.Button btnBack;
private System.Windows.Forms.Button btnHome;
private System.Windows.Forms.Button btnNext;
private System.Windows.Forms.Button btnPrev;
private System.Windows.Forms.ComboBox cbTable;
public System.Windows.Forms.PictureBox pbView;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Button btnAssist;
private System.Windows.Forms.LinkLabel lnkConfigure;
private System.Windows.Forms.Button btnCustomize;
}
}

View File

@ -0,0 +1,491 @@
using Bloatynosy.Setup;
using System;
using System.Diagnostics;
using System.Drawing;
using System.IO;
using System.Windows.Forms;
namespace Bloatynosy.Views
{
public partial class WizardPageView : UserControl
{
private PageTitle INavPage = PageTitle.Setup;
private string wallpaperPath = Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData).ToString() + @"\Microsoft\Windows\Themes\TranscodedWallpaper";
private readonly string defaultCustomizerText = "Customizations available";
private MainForm mainForm = null;
public WizardPageView(Form frm)
{
mainForm = frm as MainForm;
InitializeComponent();
NavigationView();
EnumTableOfContents();
SetStyle();
}
// Some UI nicety
private void SetStyle()
{
// Some color styling
BackColor =
Color.FromArgb(245, 241, 249);
btnBack.Text = "\uE72B";
// Border of description
btnAssist.FlatAppearance.MouseOverBackColor = btnAssist.BackColor;
btnAssist.BackColorChanged += (s, e) =>
{
btnAssist.FlatAppearance.MouseOverBackColor = btnAssist.BackColor;
};
}
private void btnHome_Click(object sender, EventArgs e)
{
if (INavPage > PageTitle.Setup)
{
INavPage = 0;
cbTable.SelectedIndex = 0;
}
NavigationView();
}
private void btnPrev_Click(object sender, EventArgs e)
{
if (INavPage > PageTitle.Setup)
{
--INavPage;
cbTable.SelectedItem = INavPage++;
}
NavigationView();
}
private void btnNext_Click(object sender, EventArgs e)
{
if (INavPage == PageTitle.Custom)
{
INavPage = 0;
cbTable.SelectedIndex = 0;
NavigationView();
}
else
{
INavPage++;
NavigationView();
cbTable.SelectedItem = INavPage++;
}
}
// Enum breadcrumbs to cb
private void EnumTableOfContents()
{
cbTable.DataSource = Enum.GetValues(typeof(PageTitle));
}
private void cbTable_SelectedIndexChanged(object sender, EventArgs e)
{
PageTitle index;
Enum.TryParse<PageTitle>(cbTable.SelectedValue.ToString(), out index);
INavPage = index;
NavigationView();
}
public void NavigationView()
{
btnPrev.Enabled = INavPage > PageTitle.Setup;
btnHome.Visible = INavPage > PageTitle.Setup;
switch (INavPage)
{
case PageTitle.Setup:
lnkConfigure.Visible = false;
btnCustomize.Visible = false;
if (!HelperTool.Utils.IsInet())
lblHeader.Text = "We cannot connect to the Internet. Some functions of the Windows 11 Setup module are not available.";
else lblHeader.Text = "Hi " + Environment.UserName;
btnAssist.Text = "Lets make sure everything is set up how you want it." +
"\n\nYou have two options:" +
"\n\n1. Use the <Next> and <Previous> buttons to run a guided tour to Windows 11 and to configure the system step by step." +
"\n\n2. Use the Auto-Analyze feature and Apps provided on the main page to quickly set up Windows 11.";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/startpage.png?raw=true";
break;
case PageTitle.NewLook:
lnkConfigure.Visible = true;
btnCustomize.Visible = true;
btnCustomize.Text = "Customize Windows 11";
lblHeader.Text = "A new look";
btnAssist.Text = "As you already see, Windows 11 features a clean design with rounded corners, pastel shades and a centered Start menu and Taskbar.";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/page-look.png?raw=true";
break;
case PageTitle.StartMenu:
lnkConfigure.Visible = true;
btnCustomize.Visible = true;
btnCustomize.Text = defaultCustomizerText;
lblHeader.Text = "New Start Menu";
btnAssist.Text = "Of all the new Windows 11 features, the new launcher-style floating Start Menu is the most distinctive part of Microsofts next-gen desktop OS.\n\n" +
"Unlike the traditional Start Menu, the new Start — as Microsoft is calling it — sits right at the center of the taskbar.\n\n" +
"It has a flyout design with pinned and recommended apps accompanying each other.";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/page-startmenu.png?raw=true";
break;
case PageTitle.Apps:
lnkConfigure.Visible = true;
btnCustomize.Visible = true;
btnCustomize.Text = "Remove bloatware";
lblHeader.Text = "Apps";
btnAssist.Text = "Apparently Windows 11 is also lighter than Windows 10 as for the preinstalled apps.\n\n" +
"The good thing is that at least some of the Windows 10 apps arent installed. However, you will still have installed all the hoard of apps that belong to Microsoft, such as Mail and Calendar, Your Phone, Mixed Reality Portal, Solitaire Collection, Get Help, Paint 3D, XBox Game Bar, etc.";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/page-apps.png?raw=true";
break;
case PageTitle.Privacy:
lnkConfigure.Visible = true;
btnCustomize.Visible = true;
btnCustomize.Text = "Fix privacy issues";
lblHeader.Text = "Privacy";
btnAssist.Text = "One thing Microsoft didn't discuss is about Windows 11 privacy.\n\n" +
"Since Windows 11 Home will essentially require a Microsoft account for most users, data harvesting is part of the package. \n\n" +
"In Windows 11, you'll be able to continue editing cloud files per its algorithmically populated \"Recommended\" section in the new Start Menu.\n" +
"Your browser history will sync between Edge on PC and Edge on mobile, as it already does. Your Skype and Teams conversations will sync as you'd expect too, and your Windows 11 features will migrate to new PCs if you upgrade.";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/page-privacy.png?raw=true";
break;
case PageTitle.MicrosoftStore:
lnkConfigure.Visible = false;
btnCustomize.Visible = true;
btnCustomize.Text = "Install packages";
lblHeader.Text = "New Microsoft Store";
btnAssist.Text = "Theres a complete UI overhaul on the app store and some speed improvements.\n\n" +
"The key change is allowing more apps into the store. The Microsoft Store is changing on Windows 11, and eventually Windows 10, to include any traditional desktop apps.\n\n" +
"Microsoft previously restricted developers to its Universal Windows Apps, before then allowing some desktop apps that were packaged to use its store for updates. Now any app can be part of the store, a move that aligns with the Windows Package Manager Microsoft released last year.";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/page-msstore.png?raw=true";
break;
case PageTitle.ActionCenter:
lnkConfigure.Visible = true;
btnCustomize.Visible = false;
btnCustomize.Text = defaultCustomizerText;
lblHeader.Text = "Action Center";
btnAssist.Text = "Another great feature of Windows 11 is the revamped Action Center.\n\n" +
"It follows a design language that we have seen on mobile OSes, and I quite like this mobile - first approach to important system toggles\n\n" +
"You can now simply click on the unified “WiFi, volume and battery” button to open the new Action Center. It packs all the necessary controls, including brightness and volume sliders. You can also add more toggles like before.";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/page-actioncenter.png?raw=true";
break;
case PageTitle.FileExplorer:
lnkConfigure.Visible = true;
btnCustomize.Visible = true;
btnCustomize.Text = defaultCustomizerText;
lblHeader.Text = "Modern File Explorer";
btnAssist.Text = "The new experience of file explorer didnt come with multiple Tabs options similar to tabs in the Microsoft Edge browser.\n\n" +
"By default, File Explorer is now optimized for tablet users.\n\n" +
"The File Explorer interface is not changing dramatically, but there are several noticeable changes. For example, Microsoft is replacing the Windows 8-era ribbon toolbar with a redesigned top menu called command bar allowing you quick access to commonly used actions like share, delete, rename, etc";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/page-fileexplorer.png?raw=true";
break;
case PageTitle.SettingsApp:
lnkConfigure.Visible = false;
btnCustomize.Visible = true;
btnCustomize.Text = "Check all settings";
lblHeader.Text = "Redesigned Settings App";
btnAssist.Text = "The Settings app has been redesigned with a radically different look and it is now using a new navigation menu on the left, similar to Control Panel.\n\n" +
"It comes with a slightly reorganized layout which enables easier access to all your PC settings.\n\n" +
"Were also getting new pages to customize the touch keyboard, Windows snapping, multitasking and other advanced features like “Wake on Touch” in the new operating system.";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/page-settingsapp.png?raw=true";
break;
case PageTitle.WindowsUpdates:
lnkConfigure.Visible = true;
btnCustomize.Visible = false;
lblHeader.Text = "Faster Windows Updates";
btnAssist.Text = "Yes, you read that right. With Windows 11, you will have a much faster Windows update process, thanks to the background installation mechanism. Microsoft has promised that Windows updates will now be 40% smaller, making the process even more efficient. ";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/page-windowsupdates.png?raw=true";
break;
case PageTitle.SnapLayouts:
lnkConfigure.Visible = false;
btnCustomize.Visible = true;
btnCustomize.Text = "Disable SnapLayouts feature";
lblHeader.Text = "Snap Layouts";
btnAssist.Text = "Snap is a productivity feature that helps users arrange applications and other windows logically on-screen.\n\n" +
"In 2019, Microsoft relaunched the PowerToys brand with a new utility called FancyZones that extends the Snap experience to allow for more complex and useful on-screen window layouts. A key part of this utility, incredibly, has been integrated into Windows 11 and is now called Snap Layouts.\n\n" +
"When you're working in a bunch of open windows, Windows 11 will let you arrange them in different layouts on the screen, and will save all of those windows in that arrangement. ";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/page-snaplayouts.png?raw=true";
break;
case PageTitle.Widgets:
lnkConfigure.Visible = false;
btnCustomize.Visible = true;
btnCustomize.Text = "Disable Widgets feature";
lblHeader.Text = "Widgets";
btnAssist.Text = "With Windows 11, Microsoft has brought Widgets, where you can find all kinds of information with just a click. Its similar to Google Assistants Snapshot and the “Today View” in Apples iOS 15 or macOS Monterey.";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/page-widgets.png?raw=true";
break;
case PageTitle.GestureControls:
lnkConfigure.Visible = true;
btnCustomize.Visible = false;
lblHeader.Text = "Advanced Gesture Controls";
btnAssist.Text = "Gestures have long been part of Windows 10, but frankly speaking, they were not very smooth, and the transitions between apps and virtual desktops were awful. With the new Advanced Gesture Controls and mandatory precision touchpad requirement for Windows 11, things might get better.\n\n" +
"Now, you can customize three-finger and four-finger swipes according to your preference.";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/page-gestures.png?raw=true";
break;
case PageTitle.WallpapersNSounds:
lnkConfigure.Visible = true;
btnCustomize.Visible = false;
lblHeader.Text = "New Wallpapers && Sounds";
btnAssist.Text = "Along with Windows 11, Microsoft has also brought a series of beautiful wallpapers, sounds, and themes. Wallpapers such as Captured Motion, Flow, Sunrise, Glow are some of the nicest wallpapers you can find on a desktop OS.\n\n" +
"Also, the startup and notification sound is really good.\nPress the Magic Button to listen to the startup sound.\n\n" +
"You will find great new wallpapers for Microsoft products also here https://wallpaperhub.app";
pbView.Visible = true;
pbView.ImageLocation = wallpaperPath;
break;
case PageTitle.LockScreen:
lnkConfigure.Visible = true;
btnCustomize.Visible = false;
lblHeader.Text = "New Minimal Lock Screen";
btnAssist.Text = "Windows 11 supports animated lock-screen background on PCs that have accelerometer.\n\n" +
"It applies an acrylic blur in the background, and the new variable Segoe UI font makes things even better. If you dont want all the links and recommendations on the lock screen, you can disable them from Settings for a clean lock screen.";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/page-lockscreen.png?raw=true";
break;
case PageTitle.TouchKeyboard:
lnkConfigure.Visible = true;
btnCustomize.Visible = false;
lblHeader.Text = "Touch Keyboard Improvements";
btnAssist.Text = "Windows 11 comes with a Touch Keyboard feature that remains turned off by default. You can use this touch keyboard on a computer or laptop, which is not a touch screen. It is a handy application if your physical keyboard is totally not working or a few keys are not working.\n\n" +
"Microsoft made it more intuitive to use by drawing inspiration from smartphone keyboards.\n\nEven you can use this Touch Keyboard as a substitute for a mechanical keyboard.";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/page-touchkeyboard.png?raw=true";
break;
case PageTitle.AndroidApps:
lnkConfigure.Visible = false;
btnCustomize.Visible = true;
btnCustomize.Text = "Install Windows Subsystem for Android";
lblHeader.Text = "Android Apps Support";
btnAssist.Text = "Microsoft has released Android apps support in the Beta Channel of Windows 11.\n\n" +
"The experience of installing apps is very simple. Microsoft has partnered with Amazon, so the Microsoft Store will list apps but send you over to Amazons Appstore app to get them installed or updated.\n\n" +
"The best part is that you can even sideload APKs on your Windows 11 PC and pin them to the Start menu or taskbar and use all of the windowing and multitasking features of Windows 11 just like a regular desktop app.";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/page-androidapps.png?raw=true";
break;
case PageTitle.Gaming:
lnkConfigure.Visible = true;
btnCustomize.Visible = true;
lblHeader.Text = "Gaming";
btnCustomize.Text = "Improve Gaming";
btnAssist.Text = "If you're a gamer, Windows 11 was made for you and the following three features will make it great for gaming.\n\n" +
"1. During the Windows 11 unveiling, Microsoft announced support for Auto HDR that would elevate the viewing experience while playing games.\n\n" +
"HDR stands for High Dynamic Range, as opposed to SDR or Standard Dynamic Range. With a higher range of colors, HDR gives more vibrant and realistic colors to your video games and makes the sceneries look even better.\n\n" +
"2. Microsoft also revealed that the DirectStorage API will come to Windows PCs. DirectStorage is an API that allows the GPU to load game data directly from the SSD and skip the CPU processing. With DirectStorage, the GPU processes and decompresses the data itself.\n\n" +
"3. Windows 11 will have an deeper Implementation of the Xbox App. The Xbox app and Game Pass are built-in features, giving Game Pass Ultimate subscribers instant access to a massive catalog of video games along with Xbox Cloud Gaming.";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/page-gaming.png?raw=true";
break;
case PageTitle.Finish:
lnkConfigure.Visible = false;
btnCustomize.Visible = true;
lblHeader.Text = "See you in a bit";
btnCustomize.Text = "We have some tips for you!";
btnAssist.Text = "We're finish setting up your device.";
pbView.Visible = true;
pbView.ImageLocation = "https://github.com/builtbybel/ThisIsWin11/blob/main/assets/pages/endpage.png?raw=true";
break;
case PageTitle.Custom:
lnkConfigure.Visible = false;
btnCustomize.Visible = true;
btnCustomize.Text = "Customize Windows 11";
lblHeader.Text = "Install Plugins for Bloatynosy";
btnAssist.Text = "You will find here Plugins (based on PowerShell script files) to customize Windows 11 according to your wishes.";
pbView.Visible = false;
pbView.ImageLocation = "";
break;
}
}
private void lnkConfigure_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
{
switch (INavPage)
{
case PageTitle.Setup:
break;
case PageTitle.NewLook:
Process.Start("ms-settings:personalization-background");
break;
case PageTitle.StartMenu:
Process.Start("ms-settings:personalization-start");
break;
case PageTitle.Apps:
Process.Start("ms-settings:appsfeatures-app");
break;
case PageTitle.Privacy:
Process.Start("ms-settings:privacy-general");
break;
case PageTitle.MicrosoftStore:
break;
case PageTitle.ActionCenter:
Process.Start("ms-settings:notifications");
break;
case PageTitle.FileExplorer:
try
{
Process proc = new Process();
proc.StartInfo.UseShellExecute = false;
proc.StartInfo.FileName = "rundll32.exe";
proc.StartInfo.Arguments = "shell32.dll,Options_RunDLL 0";
proc.Start();
break;
}
catch { }
break;
case PageTitle.SettingsApp:
break;
case PageTitle.WindowsUpdates:
Process.Start("ms-settings:windowsupdate-options");
break;
case PageTitle.SnapLayouts:
break;
case PageTitle.Widgets:
break;
case PageTitle.GestureControls:
Process.Start("ms-settings:mousetouchpad");
break;
case PageTitle.WallpapersNSounds:
Process.Start("ms-settings:personalization-background");
break;
case PageTitle.LockScreen:
Process.Start("ms-settings:lockscreen");
break;
case PageTitle.TouchKeyboard:
Process.Start("ms-settings:easeofaccess-keyboard");
break;
case PageTitle.AndroidApps:
break;
case PageTitle.Gaming:
Process.Start("ms-settings:gaming-gamebar");
break;
case PageTitle.Finish:
break;
case PageTitle.Custom:
break;
}
}
private void btnBack_Click(object sender, EventArgs e) => ViewHelper.SwitchView.SetMainFormAsView();
private void btnCustomize_Click(object sender, EventArgs e)
{
switch (INavPage)
{
case PageTitle.Apps:
ViewHelper.SwitchView.SetView(new BloatyPageView());
break;
case PageTitle.MicrosoftStore:
ViewHelper.SwitchView.SetView(new PackagesPageView());
break;
case PageTitle.Finish: // Open Microsoft Tips app
bool tipsApp = Directory.Exists(Path.Combine
(Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData),
"Packages\\Microsoft.Getstarted_8wekyb3d8bbwe"));
if (!tipsApp) MessageBox.Show("Microsoft Tips app is not installed on this system :(\nYou can get it on the Microsoft Store.", "We are sorry...", MessageBoxButtons.OK, MessageBoxIcon.Information);
else
{
Process.Start(@"shell:appsfolder\Microsoft.Getstarted_8wekyb3d8bbwe!App");
}
break;
default:
btnBack.PerformClick();
break;
}
}
}
}

View File

@ -0,0 +1,120 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@ -0,0 +1,79 @@
<?xml version="1.0" encoding="utf-8"?>
<assembly manifestVersion="1.0" xmlns="urn:schemas-microsoft-com:asm.v1">
<assemblyIdentity version="1.0.0.0" name="MyApplication.app"/>
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v2">
<security>
<requestedPrivileges xmlns="urn:schemas-microsoft-com:asm.v3">
<!-- UAC-Manifestoptionen
Wenn Sie die Ebene der Benutzerkontensteuerung für Windows ändern möchten, ersetzen Sie den
Knoten "requestedExecutionLevel" wie folgt.
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
<requestedExecutionLevel level="requireAdministrator" uiAccess="false" />
<requestedExecutionLevel level="highestAvailable" uiAccess="false" />
Durch Angabe des Elements "requestedExecutionLevel" wird die Datei- und Registrierungsvirtualisierung deaktiviert.
Entfernen Sie dieses Element, wenn diese Virtualisierung aus Gründen der Abwärtskompatibilität
für die Anwendung erforderlich ist.
-->
<requestedExecutionLevel level="highestAvailable" uiAccess="false" />
</requestedPrivileges>
</security>
</trustInfo>
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
<application>
<!-- Eine Liste der Windows-Versionen, unter denen diese Anwendung getestet
und für die sie entwickelt wurde. Wenn Sie die Auskommentierung der entsprechenden Elemente aufheben,
wird von Windows automatisch die kompatibelste Umgebung ausgewählt. -->
<!-- Windows Vista -->
<!--<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}" />-->
<!-- Windows 7 -->
<!--<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}" />-->
<!-- Windows 8 -->
<!--<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}" />-->
<!-- Windows 8.1 -->
<!--<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}" />-->
<!-- Windows 10 -->
<!--<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}" />-->
</application>
</compatibility>
<!-- Gibt an, dass die Anwendung mit DPI-Werten kompatibel ist und von Windows nicht automatisch auf höhere
DPI-Werte skaliert wird. WPF-Anwendungen (Windows Presentation Foundation) sind automatisch mit DPI-Werten kompatibel, eine Aktivierung
ist nicht erforderlich. Für Windows Forms-Anwendungen für .NET Framework 4.6, die diese Einstellung aktivieren, muss
auch die Einstellung "'EnableWindowsFormsHighDpiAutoResizing" in der Datei "app.config" auf TRUE festgelegt werden.
Hierdurch können für die Anwendung lange Pfade verwendet werden. Weitere Informationen finden Sie unter https://docs.microsoft.com/windows/win32/fileio/maximum-file-path-limitation.-->
<application xmlns="urn:schemas-microsoft-com:asm.v3">
<windowsSettings>
<dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">true</dpiAware>
<longPathAware xmlns="http://schemas.microsoft.com/SMI/2016/WindowsSettings">true</longPathAware>
</windowsSettings>
</application>
<!-- Designs für allgemeine Windows-Steuerelemente und -Dialogfelder (Windows XP und höher) aktivieren -->
<!--
<dependency>
<dependentAssembly>
<assemblyIdentity
type="win32"
name="Microsoft.Windows.Common-Controls"
version="6.0.0.0"
processorArchitecture="*"
publicKeyToken="6595b64144ccf1df"
language="*"
/>
</dependentAssembly>
</dependency>
-->
</assembly>