Showing preview only (702K chars total). Download the full file or copy to clipboard to get everything.
Repository: akshinmustafayev/EasyJob
Branch: main
Commit: 2469fe858a77
Files: 80
Total size: 670.2 KB
Directory structure:
gitextract_cvrmxber/
├── EasyJob/
│ ├── App.xaml
│ ├── App.xaml.cs
│ ├── AssemblyInfo.cs
│ ├── Documentation/
│ │ └── HelpDocumentation.xml
│ ├── EasyJob.csproj
│ ├── EasyJob.csproj.user
│ ├── EasyJobPS/
│ │ ├── EasyJobPS.psd1
│ │ └── EasyJobPS.psm1
│ ├── LICENSE.txt
│ ├── MainWindow.xaml
│ ├── MainWindow.xaml.cs
│ ├── Serialization/
│ │ ├── AnswerDialog/
│ │ │ ├── Answer.cs
│ │ │ └── AnswerData.cs
│ │ ├── Config/
│ │ │ ├── Config.cs
│ │ │ ├── ConfigArgument.cs
│ │ │ ├── ConfigButton.cs
│ │ │ ├── ConfigRestrictions.cs
│ │ │ └── ConfigTab.cs
│ │ ├── TabItems/
│ │ │ ├── ActionButton.cs
│ │ │ └── TabData.cs
│ │ └── TasksList/
│ │ └── TaskListTask.cs
│ ├── Utils/
│ │ ├── CommonUtils.cs
│ │ ├── ConfigUtils.cs
│ │ └── ScrollViewerExtensions.cs
│ ├── Windows/
│ │ ├── AboutDialog.xaml
│ │ ├── AboutDialog.xaml.cs
│ │ ├── AddActionButtonDialog.xaml
│ │ ├── AddActionButtonDialog.xaml.cs
│ │ ├── AnswerDialog.xaml
│ │ ├── AnswerDialog.xaml.cs
│ │ ├── ColorTagsDialog.xaml
│ │ ├── ColorTagsDialog.xaml.cs
│ │ ├── ConfigurationDialog.xaml
│ │ ├── ConfigurationDialog.xaml.cs
│ │ ├── EditActionButtonDialog.xaml
│ │ ├── EditActionButtonDialog.xaml.cs
│ │ ├── HelpDialog.xaml
│ │ ├── HelpDialog.xaml.cs
│ │ ├── NewTabDialog.xaml
│ │ ├── NewTabDialog.xaml.cs
│ │ ├── RenameTabDialog.xaml
│ │ ├── RenameTabDialog.xaml.cs
│ │ ├── ReorderActionButtonsDialog.xaml
│ │ ├── ReorderActionButtonsDialog.xaml.cs
│ │ ├── ReorderTabsDialog.xaml
│ │ ├── ReorderTabsDialog.xaml.cs
│ │ ├── TroubleshootingWindow.xaml
│ │ └── TroubleshootingWindow.xaml.cs
│ └── config.json
├── EasyJob.sln
├── EasyJobPSTools/
│ ├── EasyJobPSTools.csproj
│ ├── EasyJobPSTools.psd1
│ ├── EasyJobPSTools.psm1
│ ├── EasyJobPSTools.sln
│ ├── Program.cs
│ ├── Properties/
│ │ ├── AssemblyInfo.cs
│ │ ├── Resources.Designer.cs
│ │ ├── Resources.resx
│ │ ├── Settings.Designer.cs
│ │ └── Settings.settings
│ ├── Utils/
│ │ └── CommonUtils.cs
│ ├── Windows/
│ │ ├── ShowEJInputBox.xaml
│ │ └── ShowEJInputBox.xaml.cs
│ └── app.config
├── LICENSE.txt
├── README.md
└── WpfRichText/
├── AttachedProperties/
│ └── RichTextboxAssistant.cs
├── Commands/
│ ├── CommandReference.cs
│ └── DelegateCommand.cs
├── Controls/
│ ├── RichTextEditor.xaml
│ └── RichTextEditor.xaml.cs
├── WpfRichText.csproj
├── WpfRichText.sln
└── XamlToHtmlParser/
├── HtmlCssParser.cs
├── HtmlFromXamlConverter.cs
├── HtmlLexicalAnalyzer.cs
├── HtmlParser.cs
├── HtmlSchema.cs
├── HtmlToXamlConverter.cs
└── HtmlTokenType.cs
================================================
FILE CONTENTS
================================================
================================================
FILE: EasyJob/App.xaml
================================================
<Application x:Class="EasyJob.App"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:EasyJob"
xmlns:ui="http://schemas.modernwpf.com/2019"
StartupUri="MainWindow.xaml">
<Application.Resources>
<ResourceDictionary>
<ResourceDictionary.MergedDictionaries>
<ui:ThemeResources />
<ui:XamlControlsResources />
</ResourceDictionary.MergedDictionaries>
</ResourceDictionary>
</Application.Resources>
</Application>
================================================
FILE: EasyJob/App.xaml.cs
================================================
using System;
using System.Collections.Generic;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Reflection;
using System.Threading.Tasks;
using System.Windows;
namespace EasyJob
{
/// <summary>
/// Interaction logic for App.xaml
/// </summary>
public partial class App : Application
{
protected override void OnStartup(StartupEventArgs e)
{
base.OnStartup(e);
SetDropDownMenuToBeRightAligned();
}
private static void SetDropDownMenuToBeRightAligned()
{
var menuDropAlignmentField = typeof(SystemParameters).GetField("_menuDropAlignment", BindingFlags.NonPublic | BindingFlags.Static);
Action setAlignmentValue = () =>
{
if (SystemParameters.MenuDropAlignment && menuDropAlignmentField != null) menuDropAlignmentField.SetValue(null, false);
};
setAlignmentValue();
SystemParameters.StaticPropertyChanged += (sender, e) =>
{
setAlignmentValue();
};
}
}
}
================================================
FILE: EasyJob/AssemblyInfo.cs
================================================
using System.Windows;
[assembly: ThemeInfo(
ResourceDictionaryLocation.None, //where theme specific resource dictionaries are located
//(used if a resource is not found in the page,
// or application resource dictionaries)
ResourceDictionaryLocation.SourceAssembly //where the generic resource dictionary is located
//(used if a resource is not found in the page,
// app, or any theme specific resource dictionaries)
)]
================================================
FILE: EasyJob/Documentation/HelpDocumentation.xml
================================================
<?xml version="1.0" encoding="utf-8" ?>
<items>
<item>
<name>HelpAddActionButtonText</name>
<heading>Text</heading>
<description>The button text. This is an actual name of your button which will be shown on the panel. Example: "Restart server"</description>
<used>Adding button</used>
<video>HelpAddActionButtonText.mp4</video>
</item>
<item>
<name>HelpAddActionButtonDescription</name>
<heading>Description</heading>
<description>The button description. This parameter sets the description for the button which will be shown in tooltip when mouse is on the button. Example: "This button restarts specified server"</description>
<used>Adding button</used>
<video>HelpAddActionButtonDescription.mp4</video>
</item>
<item>
<name>HelpAddActionButtonScript</name>
<heading>Script</heading>
<description>The button script file. This is used to set path to the script. Value may differ based on the Script Path Type parameter. Example: If Script Path Type parameter is Relative then script file must be put to the direction where is EasyJob is located and should look like: "restart_server.ps1". If Script Path Type parameter is Absolute then script file must be put to any other direction and should look like: "C:\your\folder\name\restart_server.ps1"</description>
<used>Adding button</used>
<video>HelpAddActionButtonScript.mp4</video>
</item>
<item>
<name>HelpAddActionButtonScriptPathType</name>
<heading>Script path type</heading>
<description>The button script path type. My be set to Relative or Absolute. Relative means that your script is in the same folder with an application executable. Absolute means that your script is located in any other folder in your system. Example: "Relative"</description>
<used>Adding button</used>
<video>HelpAddActionButtonScriptPathType.mp4</video>
</item>
<item>
<name>HelpAddActionButtonScriptType</name>
<heading>Script type</heading>
<description>The button script type. My be set to PowerShell or Batch script. Example: "PowerShell"</description>
<used>Adding button</used>
<video>HelpAddActionButtonScriptType.mp4</video>
</item>
<item>
<name>HelpAddActionButtonArguments</name>
<heading>Arguments</heading>
<description>The button arguments. You have to specify list of questions which will be asked when executiong your script. Example: "Please specify server DNS name or IP address"</description>
<used>Adding button</used>
<video>HelpAddActionButtonArguments.mp4</video>
</item>
<item>
<name>HelpConfigurationDefaultPowershellPath</name>
<heading>Default PowerShell path</heading>
<description>Absolute path to PowerShell.exe. You can specify path to new versions of PowerShell. Example: "C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe"</description>
<used>Configuration</used>
<video>HelpConfigurationDefaultPowershellPath.mp4</video>
</item>
<item>
<name>HelpConfigurationDefaultCMDPath</name>
<heading>Default CMD path</heading>
<description>Absolute path to command promt. Example: "C:\Windows\System32\cmd.exe"</description>
<used>Configuration</used>
<video>HelpConfigurationDefaultCMDPath.mp4</video>
</item>
<item>
<name>HelpConfigurationPowerShellArguments</name>
<heading>PowerShell arguments</heading>
<description>Additional parameters sent to PowerShell. Example: -ExecutionPolicy Unrestricted</description>
<used>Configuration</used>
<video>HelpConfigurationPowerShellArguments.mp4</video>
</item>
<item>
<name>HelpConfigurationConsoleBackground</name>
<heading>Console background</heading>
<description>Background color of the console. Example: Black</description>
<used>Configuration</used>
<video>HelpConfigurationConsoleBackground.mp4</video>
</item>
<item>
<name>HelpConfigurationConsoleForeground</name>
<heading>Console foreground</heading>
<description>Color of the text in the console. Example: Red</description>
<used>Configuration</used>
<video>HelpConfigurationConsoleForeground.mp4</video>
</item>
<item>
<name>HelpConfigurationConsoleIgnoreColorTags</name>
<heading>Console ignore color tags</heading>
<description>Determines if special color tags are ignored during output. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationConsoleIgnoreColorTags.mp4</video>
</item>
<item>
<name>HelpConfigurationClearEventsWhenReload</name>
<heading>Clear events when reload</heading>
<description>Clear events on Events list after configuration reload from the File-> Reload config menu. Example: Yes</description>
<used>Configuration</used>
<video>HelpConfigurationClearEventsWhenReload.mp4</video>
</item>
<item>
<name>HelpConfigurationBlockTabsRemove</name>
<heading>Block tabs remove</heading>
<description>Hides "Remove Tab" context menu item from when Right click on the Tab. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationBlockTabsRemove.mp4</video>
</item>
<item>
<name>HelpConfigurationBlockButtonsRemove</name>
<heading>Block buttons remove</heading>
<description>Hides "Remove button" context menu item when Right click on the buttons bar. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationBlockButtonsRemove.mp4</video>
</item>
<item>
<name>HelpConfigurationBlockTabsAdd</name>
<heading>Block tabs add</heading>
<description>Hides "Add tab" context menu item when Right Click on the Tab. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationBlockTabsAdd.mp4</video>
</item>
<item>
<name>HelpConfigurationBlockButtonsAdd</name>
<heading>Block buttons add</heading>
<description>Hides "Add button" context menu item when Right click on the buttons bar. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationBlockButtonsAdd.mp4</video>
</item>
<item>
<name>HelpConfigurationBlockButtonsReorder</name>
<heading>Block buttons reorder</heading>
<description>Hides "Reorder buttons" context menu item when Right click on the buttons bar. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationBlockButtonsReorder.mp4</video>
</item>
<item>
<name>HelpConfigurationBlockButtonsEdit</name>
<heading>Block buttons edit</heading>
<description>Hides "Edit button" context menu item when Right click on the button. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationBlockButtonsEdit.mp4</video>
</item>
<item>
<name>HelpConfigurationBlockTabsRename</name>
<heading>Block tabs rename</heading>
<description>Hides "Rename tab" context menu item when Right click on the tab. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationBlockTabsRename.mp4</video>
</item>
<item>
<name>HelpConfigurationBlockButtonsPaste</name>
<heading>Block buttons paste</heading>
<description>Hides "Paste button" context menu item when Right click on the tab. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationBlockButtonsPaste.mp4</video>
</item>
<item>
<name>HelpConfigurationBlockButtonsCopy</name>
<heading>Block buttons copy</heading>
<description>Hides "Copy button" context menu item when Right click on the tab. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationBlockButtonsCopy.mp4</video>
</item>
<item>
<name>HelpConfigurationHideFileReloadConfig</name>
<heading>Hide File->Reload config</heading>
<description>Hides "File->Reload config" main menu item. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationHideFileReloadConfig.mp4</video>
</item>
<item>
<name>HelpConfigurationHideFileOpenAppFolder</name>
<heading>Hide File->Open app folder</heading>
<description>Hides "File->Open app folder" main menu item. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationHideFileOpenAppFolder.mp4</video>
</item>
<item>
<name>HelpConfigurationHideClearEventsList</name>
<heading>Hide File->Clear events list</heading>
<description>Hides "Hide File->Clear events list" main menu item. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationHideClearEventsList.mp4</video>
</item>
<item>
<name>HelpConfigurationHideSettings</name>
<heading>Hide Settings</heading>
<description>Hides "Hide Settings" main menu item. Example: No Note: In order to bring back Settings menu, you have to manually find "hide_menu_item_settings" parameter in config.json and change its value to "false"</description>
<used>Configuration</used>
<video>HelpConfigurationHideSettings.mp4</video>
</item>
<item>
<name>HelpConfigurationHideSettingsWorkflow</name>
<heading>Hide Settings->Workflow</heading>
<description>Hides "Hide Settings->Workflow" main menu item. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationHideSettingsWorkflow.mp4</video>
</item>
<item>
<name>HelpConfigurationHideSettingsWorkflowReorderTabs</name>
<heading>Hide Settings->Workflow->Reorder tabs</heading>
<description>Hides "Hide Settings->Workflow->Reorder tabs" main menu item. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationHideSettingsWorkflowReorderTabs.mp4</video>
</item>
<item>
<name>HelpConfigurationHideSettingsWorkflowAddTab</name>
<heading>Hide Settings->Workflow->Add tab</heading>
<description>Hides "Hide Settings->Workflow->Add tab" main menu item. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationHideSettingsWorkflowAddTab.mp4</video>
</item>
<item>
<name>HelpConfigurationHideSettingsWorkflowRemoveCurrentTab</name>
<heading>Hide Settings->Workflow->Remove current tab</heading>
<description>Hides "Hide Settings->Workflow->Remove current tab" main menu item. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationHideSettingsWorkflowRemoveCurrentTab.mp4</video>
</item>
<item>
<name>HelpConfigurationHideSettingsWorkflowRenameCurrentTab</name>
<heading>Hide Settings->Workflow->Rename current tab</heading>
<description>Hides "Hide Settings->Workflow->Rename current tab" main menu item. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationHideSettingsWorkflowRenameCurrentTab.mp4</video>
</item>
<item>
<name>HelpConfigurationHideSettingsWorkflowAddButtonToCurrentTab</name>
<heading>Hide Settings->Workflow->Add button to current tab" main menu item. Example: No</heading>
<description>Hides "Hide Settings->Workflow->Add button to current tab</description>
<used>Configuration</used>
<video>HelpConfigurationHideSettingsWorkflowAddButtonToCurrentTab.mp4</video>
</item>
<item>
<name>HelpConfigurationHideSettingsWorkflowReorderButtonsInCurrentTab</name>
<heading>Hide Settings->Workflow->Reorder buttons in current tab</heading>
<description>Hides "Hide Settings->Workflow->Reorder buttons in current tab" main menu item. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationHideSettingsWorkflowReorderButtonsInCurrentTab.mp4</video>
</item>
<item>
<name>HelpConfigurationHideSettingsConfiguration</name>
<heading>Hide Settings->Configuration</heading>
<description>Hides "Hide Settings->Configuration" main menu item. Example: No Note: In order to bring back Configuration menu, you have to manually find "hide_menu_item_settings_configuration" parameter in config.json and change its value to "false"</description>
<used>Configuration</used>
<video>HelpConfigurationHideSettingsConfiguration.mp4</video>
</item>
<item>
<name>HelpConfigurationHideHelp</name>
<heading>Hide Help</heading>
<description>Hides "Hide Help" main menu item. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationHideHelp.mp4</video>
</item>
<item>
<name>HelpConfigurationHideTroubleshooting</name>
<heading>Hide Help->Troubleshooting</heading>
<description>Hides "Hide Help->Troubleshooting" main menu item. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationHideTroubleshooting.mp4</video>
</item>
<item>
<name>HelpConfigurationHideColorTags</name>
<heading>Hide Help->Troubleshooting</heading>
<description>Hides "Hide Help->Color tags" main menu item. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationHideColorTags.mp4</video>
</item>
<item>
<name>HelpConfigurationHideAbout</name>
<heading>Hide Help->About</heading>
<description>Hides "Hide Help->About" main menu item. Example: No</description>
<used>Configuration</used>
<video>HelpConfigurationHideAbout.mp4</video>
</item>
</items>
================================================
FILE: EasyJob/EasyJob.csproj
================================================
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>WinExe</OutputType>
<TargetFramework>net5.0-windows</TargetFramework>
<UseWPF>true</UseWPF>
<ApplicationIcon>Images\icon.ico</ApplicationIcon>
<Version>1.1.9</Version>
<Authors>Akshin Mustafayev</Authors>
<Description>Keep and execute your PowerShell scripts from one interface</Description>
<Copyright>Akshin Mustafayev</Copyright>
<PackageProjectUrl>https://github.com/akshinmustafayev/EasyJob</PackageProjectUrl>
<RepositoryUrl>https://github.com/akshinmustafayev/EasyJob</RepositoryUrl>
<RepositoryType>Git</RepositoryType>
<AssemblyVersion>1.1.9.0</AssemblyVersion>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
<GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies>
<OutputPath>..\bin\Debug\</OutputPath>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
<OutputPath>..\bin\Release\</OutputPath>
</PropertyGroup>
<ItemGroup>
<None Remove="HelpDocumentation.xml" />
<None Remove="Images\about.png" />
<None Remove="Images\add.png" />
<None Remove="Images\addbutton.png" />
<None Remove="Images\addtab.png" />
<None Remove="Images\clear.png" />
<None Remove="Images\close.png" />
<None Remove="Images\colortags.png" />
<None Remove="Images\ColorTags\tag01.png" />
<None Remove="Images\ColorTags\tag02.png" />
<None Remove="Images\ColorTags\tag03.png" />
<None Remove="Images\ColorTags\tag04.png" />
<None Remove="Images\ColorTags\tag05.png" />
<None Remove="Images\ColorTags\tag06.png" />
<None Remove="Images\ColorTags\tag07.png" />
<None Remove="Images\ColorTags\tag08.png" />
<None Remove="Images\ColorTags\tag09.png" />
<None Remove="Images\ColorTags\tag10.png" />
<None Remove="Images\ColorTags\tag11.png" />
<None Remove="Images\ColorTags\tag12.png" />
<None Remove="Images\ColorTags\tag13.png" />
<None Remove="Images\ColorTags\tag14.png" />
<None Remove="Images\configuration.png" />
<None Remove="Images\convert.png" />
<None Remove="Images\copy.png" />
<None Remove="Images\down.png" />
<None Remove="Images\editbutton.png" />
<None Remove="Images\exit.png" />
<None Remove="Images\find.png" />
<None Remove="Images\folder.png" />
<None Remove="Images\github.png" />
<None Remove="Images\help.png" />
<None Remove="Images\icon.ico" />
<None Remove="Images\paste.png" />
<None Remove="Images\play.png" />
<None Remove="Images\reload.png" />
<None Remove="Images\removebutton.png" />
<None Remove="Images\removetab.png" />
<None Remove="Images\renametab.png" />
<None Remove="Images\reorderbuttons.png" />
<None Remove="Images\reordertabs.png" />
<None Remove="Images\stop.png" />
<None Remove="Images\troubleshoot.png" />
<None Remove="Images\up.png" />
<None Remove="Images\workflow.png" />
<None Remove="LICENSE.txt" />
</ItemGroup>
<ItemGroup>
<EmbeddedResource Include="Documentation\HelpDocumentation.xml" />
<EmbeddedResource Include="LICENSE.txt" />
</ItemGroup>
<ItemGroup>
<Resource Include="Images\about.png" />
<Resource Include="Images\add.png" />
<Resource Include="Images\addbutton.png" />
<Resource Include="Images\addtab.png" />
<Resource Include="Images\clear.png" />
<Resource Include="Images\close.png" />
<Resource Include="Images\colortags.png" />
<Resource Include="Images\ColorTags\tag01.png" />
<Resource Include="Images\ColorTags\tag02.png" />
<Resource Include="Images\ColorTags\tag03.png" />
<Resource Include="Images\ColorTags\tag04.png" />
<Resource Include="Images\ColorTags\tag05.png" />
<Resource Include="Images\ColorTags\tag06.png" />
<Resource Include="Images\ColorTags\tag07.png" />
<Resource Include="Images\ColorTags\tag08.png" />
<Resource Include="Images\ColorTags\tag09.png" />
<Resource Include="Images\ColorTags\tag10.png" />
<Resource Include="Images\ColorTags\tag11.png" />
<Resource Include="Images\ColorTags\tag12.png" />
<Resource Include="Images\ColorTags\tag13.png" />
<Resource Include="Images\ColorTags\tag14.png" />
<Resource Include="Images\convert.png" />
<Resource Include="Images\copy.png" />
<Resource Include="Images\down.png" />
<Resource Include="Images\editbutton.png" />
<Resource Include="Images\exit.png" />
<Resource Include="Images\find.png" />
<Resource Include="Images\folder.png" />
<Resource Include="Images\github.png" />
<Resource Include="Images\help.png" />
<Resource Include="Images\icon.ico" />
<Resource Include="Images\paste.png" />
<Resource Include="Images\play.png" />
<Resource Include="Images\reload.png" />
<Resource Include="Images\removebutton.png" />
<Resource Include="Images\removetab.png" />
<Resource Include="Images\renametab.png" />
<Resource Include="Images\reorderbuttons.png" />
<Resource Include="Images\reordertabs.png" />
<Resource Include="Images\configuration.png" />
<Resource Include="Images\stop.png" />
<Resource Include="Images\troubleshoot.png" />
<Resource Include="Images\up.png" />
<Resource Include="Images\workflow.png" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="HtmlAgilityPack" Version="1.11.37" />
<PackageReference Include="ModernWpfUis" Version="1.2.0" />
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
</ItemGroup>
<ItemGroup>
<None Update="config.json">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpAddActionButtonArguments.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpAddActionButtonDescription.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpAddActionButtonScript.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpAddActionButtonScriptPathType.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpAddActionButtonScriptType.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpAddActionButtonText.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationBlockButtonsAdd.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationBlockButtonsCopy.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationBlockButtonsEdit.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationBlockButtonsPaste.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationBlockButtonsRemove.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationBlockButtonsReorder.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationBlockTabsAdd.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationBlockTabsRemove.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationBlockTabsRename.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationClearEventsWhenReload.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationConsoleBackground.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationConsoleForeground.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationConsoleIgnoreColorTags.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationDefaultCMDPath.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationDefaultPowershellPath.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationHideAbout.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationHideClearEventsList.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationHideColorTags.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationHideFileOpenAppFolder.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationHideFileReloadConfig.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationHideHelp.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationHideSettings.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationHideSettingsConfiguration.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationHideSettingsWorkflow.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationHideSettingsWorkflowAddButtonToCurrentTab.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationHideSettingsWorkflowAddTab.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationHideSettingsWorkflowRemoveCurrentTab.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationHideSettingsWorkflowRenameCurrentTab.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationHideSettingsWorkflowReorderButtonsInCurrentTab.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationHideSettingsWorkflowReorderTabs.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationHideTroubleshooting.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Documentation\Videos\HelpConfigurationPowerShellArguments.mp4">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\WpfRichText\WpfRichText.csproj" />
</ItemGroup>
</Project>
================================================
FILE: EasyJob/EasyJob.csproj.user
================================================
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup />
<ItemGroup>
<ApplicationDefinition Update="App.xaml">
<SubType>Designer</SubType>
</ApplicationDefinition>
</ItemGroup>
<ItemGroup>
<Compile Update="Windows\AddActionButtonDialog.xaml.cs">
<SubType>Code</SubType>
</Compile>
<Compile Update="Windows\AnswerDialog.xaml.cs">
<SubType>Code</SubType>
</Compile>
<Compile Update="Windows\ColorTagsDialog.xaml.cs">
<SubType>Code</SubType>
</Compile>
<Compile Update="Windows\ConfigurationDialog.xaml.cs">
<SubType>Code</SubType>
</Compile>
<Compile Update="Windows\EditActionButtonDialog.xaml.cs">
<SubType>Code</SubType>
</Compile>
<Compile Update="Windows\HelpDialog.xaml.cs">
<SubType>Code</SubType>
</Compile>
<Compile Update="Windows\NewTabDialog.xaml.cs">
<SubType>Code</SubType>
</Compile>
<Compile Update="Windows\RenameTabDialog.xaml.cs">
<SubType>Code</SubType>
</Compile>
<Compile Update="Windows\ReorderActionButtonsDialog.xaml.cs">
<SubType>Code</SubType>
</Compile>
<Compile Update="Windows\ReorderTabsDialog.xaml.cs">
<SubType>Code</SubType>
</Compile>
<Compile Update="Windows\TroubleshootingWindow.xaml.cs">
<SubType>Code</SubType>
</Compile>
</ItemGroup>
<ItemGroup>
<Page Update="MainWindow.xaml">
<SubType>Designer</SubType>
</Page>
<Page Update="Windows\AboutDialog.xaml">
<SubType>Designer</SubType>
</Page>
<Page Update="Windows\AddActionButtonDialog.xaml">
<SubType>Designer</SubType>
</Page>
<Page Update="Windows\AnswerDialog.xaml">
<SubType>Designer</SubType>
</Page>
<Page Update="Windows\ColorTagsDialog.xaml">
<SubType>Designer</SubType>
</Page>
<Page Update="Windows\ConfigurationDialog.xaml">
<SubType>Designer</SubType>
</Page>
<Page Update="Windows\EditActionButtonDialog.xaml">
<SubType>Designer</SubType>
</Page>
<Page Update="Windows\HelpDialog.xaml">
<SubType>Designer</SubType>
</Page>
<Page Update="Windows\NewTabDialog.xaml">
<SubType>Designer</SubType>
</Page>
<Page Update="Windows\RenameTabDialog.xaml">
<SubType>Designer</SubType>
</Page>
<Page Update="Windows\ReorderActionButtonsDialog.xaml">
<SubType>Designer</SubType>
</Page>
<Page Update="Windows\ReorderTabsDialog.xaml">
<SubType>Designer</SubType>
</Page>
<Page Update="Windows\TroubleshootingWindow.xaml">
<SubType>Designer</SubType>
</Page>
</ItemGroup>
</Project>
================================================
FILE: EasyJob/EasyJobPS/EasyJobPS.psd1
================================================
# Module manifest for module 'EasyJobPS'
# Generated by: Akshin Mustafayev
# Generated on: 10/8/2021
@{
# Script module or binary module file associated with this manifest.
RootModule = 'EasyJobPS.psm1'
# Version number of this module.
ModuleVersion = '1.0'
# ID used to uniquely identify this module
GUID = 'd6c56376-ae08-4c23-b901-9bc75144e0c6'
# Author of this module
Author = 'Akshin Mustafayev'
# Company or vendor of this module
CompanyName = 'Akshin Mustafayev'
# Copyright statement for this module
Copyright = '(c) 2021 Akshin Mustafayev. Apache-2.0 license.'
# Description of the functionality provided by this module
Description = 'Module for implementing EasyJob additional helper functions'
# Functions to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no functions to export.
FunctionsToExport = 'Show-EJInputBox'
}
================================================
FILE: EasyJob/EasyJobPS/EasyJobPS.psm1
================================================
[void][Reflection.Assembly]::LoadWithPartialName('Microsoft.VisualBasic')
function Show-EJInputBox {
<#
.SYNOPSIS
Shows Input-Box for you script.
.DESCRIPTION
Shows Input-Box for you script. This might be necessary
when you want to get som input while executing your script,
since EasyJob does not support Read from console.
.PARAMETER Title
Specifies Title for message box.
.PARAMETER Message
Specifies Message for message box.
.INPUTS
None.
.OUTPUTS
String value of the input from the box.
.EXAMPLE
C:\PS> $Result = Show-EJInputBox -Title "Specify your name" -Message "What is your name?"
C:\PS> Write-Host "Your name is $Result"
Your name is test
.LINK
https://github.com/akshinmustafayev/EasyJob
#>
param (
[Parameter(Mandatory = $true)][ValidateNotNullOrEmpty()] [string]$Title,
[Parameter(Mandatory = $true)][ValidateNotNullOrEmpty()] [string]$Message
)
$Result = [Microsoft.VisualBasic.Interaction]::InputBox($Message, $Title)
return $Result
}
================================================
FILE: EasyJob/LICENSE.txt
================================================
GNU AFFERO GENERAL PUBLIC LICENSE
Version 3, 19 November 2007
Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The GNU Affero General Public License is a free, copyleft license for
software and other kinds of works, specifically designed to ensure
cooperation with the community in the case of network server software.
The licenses for most software and other practical works are designed
to take away your freedom to share and change the works. By contrast,
our General Public Licenses are intended to guarantee your freedom to
share and change all versions of a program--to make sure it remains free
software for all its users.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
them if you wish), that you receive source code or can get it if you
want it, that you can change the software or use pieces of it in new
free programs, and that you know you can do these things.
Developers that use our General Public Licenses protect your rights
with two steps: (1) assert copyright on the software, and (2) offer
you this License which gives you legal permission to copy, distribute
and/or modify the software.
A secondary benefit of defending all users' freedom is that
improvements made in alternate versions of the program, if they
receive widespread use, become available for other developers to
incorporate. Many developers of free software are heartened and
encouraged by the resulting cooperation. However, in the case of
software used on network servers, this result may fail to come about.
The GNU General Public License permits making a modified version and
letting the public access it on a server without ever releasing its
source code to the public.
The GNU Affero General Public License is designed specifically to
ensure that, in such cases, the modified source code becomes available
to the community. It requires the operator of a network server to
provide the source code of the modified version running there to the
users of that server. Therefore, public use of a modified version, on
a publicly accessible server, gives the public access to the source
code of the modified version.
An older license, called the Affero General Public License and
published by Affero, was designed to accomplish similar goals. This is
a different license, not a version of the Affero GPL, but Affero has
released a new version of the Affero GPL which permits relicensing under
this license.
The precise terms and conditions for copying, distribution and
modification follow.
TERMS AND CONDITIONS
0. Definitions.
"This License" refers to version 3 of the GNU Affero General Public License.
"Copyright" also means copyright-like laws that apply to other kinds of
works, such as semiconductor masks.
"The Program" refers to any copyrightable work licensed under this
License. Each licensee is addressed as "you". "Licensees" and
"recipients" may be individuals or organizations.
To "modify" a work means to copy from or adapt all or part of the work
in a fashion requiring copyright permission, other than the making of an
exact copy. The resulting work is called a "modified version" of the
earlier work or a work "based on" the earlier work.
A "covered work" means either the unmodified Program or a work based
on the Program.
To "propagate" a work means to do anything with it that, without
permission, would make you directly or secondarily liable for
infringement under applicable copyright law, except executing it on a
computer or modifying a private copy. Propagation includes copying,
distribution (with or without modification), making available to the
public, and in some countries other activities as well.
To "convey" a work means any kind of propagation that enables other
parties to make or receive copies. Mere interaction with a user through
a computer network, with no transfer of a copy, is not conveying.
An interactive user interface displays "Appropriate Legal Notices"
to the extent that it includes a convenient and prominently visible
feature that (1) displays an appropriate copyright notice, and (2)
tells the user that there is no warranty for the work (except to the
extent that warranties are provided), that licensees may convey the
work under this License, and how to view a copy of this License. If
the interface presents a list of user commands or options, such as a
menu, a prominent item in the list meets this criterion.
1. Source Code.
The "source code" for a work means the preferred form of the work
for making modifications to it. "Object code" means any non-source
form of a work.
A "Standard Interface" means an interface that either is an official
standard defined by a recognized standards body, or, in the case of
interfaces specified for a particular programming language, one that
is widely used among developers working in that language.
The "System Libraries" of an executable work include anything, other
than the work as a whole, that (a) is included in the normal form of
packaging a Major Component, but which is not part of that Major
Component, and (b) serves only to enable use of the work with that
Major Component, or to implement a Standard Interface for which an
implementation is available to the public in source code form. A
"Major Component", in this context, means a major essential component
(kernel, window system, and so on) of the specific operating system
(if any) on which the executable work runs, or a compiler used to
produce the work, or an object code interpreter used to run it.
The "Corresponding Source" for a work in object code form means all
the source code needed to generate, install, and (for an executable
work) run the object code and to modify the work, including scripts to
control those activities. However, it does not include the work's
System Libraries, or general-purpose tools or generally available free
programs which are used unmodified in performing those activities but
which are not part of the work. For example, Corresponding Source
includes interface definition files associated with source files for
the work, and the source code for shared libraries and dynamically
linked subprograms that the work is specifically designed to require,
such as by intimate data communication or control flow between those
subprograms and other parts of the work.
The Corresponding Source need not include anything that users
can regenerate automatically from other parts of the Corresponding
Source.
The Corresponding Source for a work in source code form is that
same work.
2. Basic Permissions.
All rights granted under this License are granted for the term of
copyright on the Program, and are irrevocable provided the stated
conditions are met. This License explicitly affirms your unlimited
permission to run the unmodified Program. The output from running a
covered work is covered by this License only if the output, given its
content, constitutes a covered work. This License acknowledges your
rights of fair use or other equivalent, as provided by copyright law.
You may make, run and propagate covered works that you do not
convey, without conditions so long as your license otherwise remains
in force. You may convey covered works to others for the sole purpose
of having them make modifications exclusively for you, or provide you
with facilities for running those works, provided that you comply with
the terms of this License in conveying all material for which you do
not control copyright. Those thus making or running the covered works
for you must do so exclusively on your behalf, under your direction
and control, on terms that prohibit them from making any copies of
your copyrighted material outside their relationship with you.
Conveying under any other circumstances is permitted solely under
the conditions stated below. Sublicensing is not allowed; section 10
makes it unnecessary.
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
No covered work shall be deemed part of an effective technological
measure under any applicable law fulfilling obligations under article
11 of the WIPO copyright treaty adopted on 20 December 1996, or
similar laws prohibiting or restricting circumvention of such
measures.
When you convey a covered work, you waive any legal power to forbid
circumvention of technological measures to the extent such circumvention
is effected by exercising rights under this License with respect to
the covered work, and you disclaim any intention to limit operation or
modification of the work as a means of enforcing, against the work's
users, your or third parties' legal rights to forbid circumvention of
technological measures.
4. Conveying Verbatim Copies.
You may convey verbatim copies of the Program's source code as you
receive it, in any medium, provided that you conspicuously and
appropriately publish on each copy an appropriate copyright notice;
keep intact all notices stating that this License and any
non-permissive terms added in accord with section 7 apply to the code;
keep intact all notices of the absence of any warranty; and give all
recipients a copy of this License along with the Program.
You may charge any price or no price for each copy that you convey,
and you may offer support or warranty protection for a fee.
5. Conveying Modified Source Versions.
You may convey a work based on the Program, or the modifications to
produce it from the Program, in the form of source code under the
terms of section 4, provided that you also meet all of these conditions:
a) The work must carry prominent notices stating that you modified
it, and giving a relevant date.
b) The work must carry prominent notices stating that it is
released under this License and any conditions added under section
7. This requirement modifies the requirement in section 4 to
"keep intact all notices".
c) You must license the entire work, as a whole, under this
License to anyone who comes into possession of a copy. This
License will therefore apply, along with any applicable section 7
additional terms, to the whole of the work, and all its parts,
regardless of how they are packaged. This License gives no
permission to license the work in any other way, but it does not
invalidate such permission if you have separately received it.
d) If the work has interactive user interfaces, each must display
Appropriate Legal Notices; however, if the Program has interactive
interfaces that do not display Appropriate Legal Notices, your
work need not make them do so.
A compilation of a covered work with other separate and independent
works, which are not by their nature extensions of the covered work,
and which are not combined with it such as to form a larger program,
in or on a volume of a storage or distribution medium, is called an
"aggregate" if the compilation and its resulting copyright are not
used to limit the access or legal rights of the compilation's users
beyond what the individual works permit. Inclusion of a covered work
in an aggregate does not cause this License to apply to the other
parts of the aggregate.
6. Conveying Non-Source Forms.
You may convey a covered work in object code form under the terms
of sections 4 and 5, provided that you also convey the
machine-readable Corresponding Source under the terms of this License,
in one of these ways:
a) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by the
Corresponding Source fixed on a durable physical medium
customarily used for software interchange.
b) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by a
written offer, valid for at least three years and valid for as
long as you offer spare parts or customer support for that product
model, to give anyone who possesses the object code either (1) a
copy of the Corresponding Source for all the software in the
product that is covered by this License, on a durable physical
medium customarily used for software interchange, for a price no
more than your reasonable cost of physically performing this
conveying of source, or (2) access to copy the
Corresponding Source from a network server at no charge.
c) Convey individual copies of the object code with a copy of the
written offer to provide the Corresponding Source. This
alternative is allowed only occasionally and noncommercially, and
only if you received the object code with such an offer, in accord
with subsection 6b.
d) Convey the object code by offering access from a designated
place (gratis or for a charge), and offer equivalent access to the
Corresponding Source in the same way through the same place at no
further charge. You need not require recipients to copy the
Corresponding Source along with the object code. If the place to
copy the object code is a network server, the Corresponding Source
may be on a different server (operated by you or a third party)
that supports equivalent copying facilities, provided you maintain
clear directions next to the object code saying where to find the
Corresponding Source. Regardless of what server hosts the
Corresponding Source, you remain obligated to ensure that it is
available for as long as needed to satisfy these requirements.
e) Convey the object code using peer-to-peer transmission, provided
you inform other peers where the object code and Corresponding
Source of the work are being offered to the general public at no
charge under subsection 6d.
A separable portion of the object code, whose source code is excluded
from the Corresponding Source as a System Library, need not be
included in conveying the object code work.
A "User Product" is either (1) a "consumer product", which means any
tangible personal property which is normally used for personal, family,
or household purposes, or (2) anything designed or sold for incorporation
into a dwelling. In determining whether a product is a consumer product,
doubtful cases shall be resolved in favor of coverage. For a particular
product received by a particular user, "normally used" refers to a
typical or common use of that class of product, regardless of the status
of the particular user or of the way in which the particular user
actually uses, or expects or is expected to use, the product. A product
is a consumer product regardless of whether the product has substantial
commercial, industrial or non-consumer uses, unless such uses represent
the only significant mode of use of the product.
"Installation Information" for a User Product means any methods,
procedures, authorization keys, or other information required to install
and execute modified versions of a covered work in that User Product from
a modified version of its Corresponding Source. The information must
suffice to ensure that the continued functioning of the modified object
code is in no case prevented or interfered with solely because
modification has been made.
If you convey an object code work under this section in, or with, or
specifically for use in, a User Product, and the conveying occurs as
part of a transaction in which the right of possession and use of the
User Product is transferred to the recipient in perpetuity or for a
fixed term (regardless of how the transaction is characterized), the
Corresponding Source conveyed under this section must be accompanied
by the Installation Information. But this requirement does not apply
if neither you nor any third party retains the ability to install
modified object code on the User Product (for example, the work has
been installed in ROM).
The requirement to provide Installation Information does not include a
requirement to continue to provide support service, warranty, or updates
for a work that has been modified or installed by the recipient, or for
the User Product in which it has been modified or installed. Access to a
network may be denied when the modification itself materially and
adversely affects the operation of the network or violates the rules and
protocols for communication across the network.
Corresponding Source conveyed, and Installation Information provided,
in accord with this section must be in a format that is publicly
documented (and with an implementation available to the public in
source code form), and must require no special password or key for
unpacking, reading or copying.
7. Additional Terms.
"Additional permissions" are terms that supplement the terms of this
License by making exceptions from one or more of its conditions.
Additional permissions that are applicable to the entire Program shall
be treated as though they were included in this License, to the extent
that they are valid under applicable law. If additional permissions
apply only to part of the Program, that part may be used separately
under those permissions, but the entire Program remains governed by
this License without regard to the additional permissions.
When you convey a copy of a covered work, you may at your option
remove any additional permissions from that copy, or from any part of
it. (Additional permissions may be written to require their own
removal in certain cases when you modify the work.) You may place
additional permissions on material, added by you to a covered work,
for which you have or can give appropriate copyright permission.
Notwithstanding any other provision of this License, for material you
add to a covered work, you may (if authorized by the copyright holders of
that material) supplement the terms of this License with terms:
a) Disclaiming warranty or limiting liability differently from the
terms of sections 15 and 16 of this License; or
b) Requiring preservation of specified reasonable legal notices or
author attributions in that material or in the Appropriate Legal
Notices displayed by works containing it; or
c) Prohibiting misrepresentation of the origin of that material, or
requiring that modified versions of such material be marked in
reasonable ways as different from the original version; or
d) Limiting the use for publicity purposes of names of licensors or
authors of the material; or
e) Declining to grant rights under trademark law for use of some
trade names, trademarks, or service marks; or
f) Requiring indemnification of licensors and authors of that
material by anyone who conveys the material (or modified versions of
it) with contractual assumptions of liability to the recipient, for
any liability that these contractual assumptions directly impose on
those licensors and authors.
All other non-permissive additional terms are considered "further
restrictions" within the meaning of section 10. If the Program as you
received it, or any part of it, contains a notice stating that it is
governed by this License along with a term that is a further
restriction, you may remove that term. If a license document contains
a further restriction but permits relicensing or conveying under this
License, you may add to a covered work material governed by the terms
of that license document, provided that the further restriction does
not survive such relicensing or conveying.
If you add terms to a covered work in accord with this section, you
must place, in the relevant source files, a statement of the
additional terms that apply to those files, or a notice indicating
where to find the applicable terms.
Additional terms, permissive or non-permissive, may be stated in the
form of a separately written license, or stated as exceptions;
the above requirements apply either way.
8. Termination.
You may not propagate or modify a covered work except as expressly
provided under this License. Any attempt otherwise to propagate or
modify it is void, and will automatically terminate your rights under
this License (including any patent licenses granted under the third
paragraph of section 11).
However, if you cease all violation of this License, then your
license from a particular copyright holder is reinstated (a)
provisionally, unless and until the copyright holder explicitly and
finally terminates your license, and (b) permanently, if the copyright
holder fails to notify you of the violation by some reasonable means
prior to 60 days after the cessation.
Moreover, your license from a particular copyright holder is
reinstated permanently if the copyright holder notifies you of the
violation by some reasonable means, this is the first time you have
received notice of violation of this License (for any work) from that
copyright holder, and you cure the violation prior to 30 days after
your receipt of the notice.
Termination of your rights under this section does not terminate the
licenses of parties who have received copies or rights from you under
this License. If your rights have been terminated and not permanently
reinstated, you do not qualify to receive new licenses for the same
material under section 10.
9. Acceptance Not Required for Having Copies.
You are not required to accept this License in order to receive or
run a copy of the Program. Ancillary propagation of a covered work
occurring solely as a consequence of using peer-to-peer transmission
to receive a copy likewise does not require acceptance. However,
nothing other than this License grants you permission to propagate or
modify any covered work. These actions infringe copyright if you do
not accept this License. Therefore, by modifying or propagating a
covered work, you indicate your acceptance of this License to do so.
10. Automatic Licensing of Downstream Recipients.
Each time you convey a covered work, the recipient automatically
receives a license from the original licensors, to run, modify and
propagate that work, subject to this License. You are not responsible
for enforcing compliance by third parties with this License.
An "entity transaction" is a transaction transferring control of an
organization, or substantially all assets of one, or subdividing an
organization, or merging organizations. If propagation of a covered
work results from an entity transaction, each party to that
transaction who receives a copy of the work also receives whatever
licenses to the work the party's predecessor in interest had or could
give under the previous paragraph, plus a right to possession of the
Corresponding Source of the work from the predecessor in interest, if
the predecessor has it or can get it with reasonable efforts.
You may not impose any further restrictions on the exercise of the
rights granted or affirmed under this License. For example, you may
not impose a license fee, royalty, or other charge for exercise of
rights granted under this License, and you may not initiate litigation
(including a cross-claim or counterclaim in a lawsuit) alleging that
any patent claim is infringed by making, using, selling, offering for
sale, or importing the Program or any portion of it.
11. Patents.
A "contributor" is a copyright holder who authorizes use under this
License of the Program or a work on which the Program is based. The
work thus licensed is called the contributor's "contributor version".
A contributor's "essential patent claims" are all patent claims
owned or controlled by the contributor, whether already acquired or
hereafter acquired, that would be infringed by some manner, permitted
by this License, of making, using, or selling its contributor version,
but do not include claims that would be infringed only as a
consequence of further modification of the contributor version. For
purposes of this definition, "control" includes the right to grant
patent sublicenses in a manner consistent with the requirements of
this License.
Each contributor grants you a non-exclusive, worldwide, royalty-free
patent license under the contributor's essential patent claims, to
make, use, sell, offer for sale, import and otherwise run, modify and
propagate the contents of its contributor version.
In the following three paragraphs, a "patent license" is any express
agreement or commitment, however denominated, not to enforce a patent
(such as an express permission to practice a patent or covenant not to
sue for patent infringement). To "grant" such a patent license to a
party means to make such an agreement or commitment not to enforce a
patent against the party.
If you convey a covered work, knowingly relying on a patent license,
and the Corresponding Source of the work is not available for anyone
to copy, free of charge and under the terms of this License, through a
publicly available network server or other readily accessible means,
then you must either (1) cause the Corresponding Source to be so
available, or (2) arrange to deprive yourself of the benefit of the
patent license for this particular work, or (3) arrange, in a manner
consistent with the requirements of this License, to extend the patent
license to downstream recipients. "Knowingly relying" means you have
actual knowledge that, but for the patent license, your conveying the
covered work in a country, or your recipient's use of the covered work
in a country, would infringe one or more identifiable patents in that
country that you have reason to believe are valid.
If, pursuant to or in connection with a single transaction or
arrangement, you convey, or propagate by procuring conveyance of, a
covered work, and grant a patent license to some of the parties
receiving the covered work authorizing them to use, propagate, modify
or convey a specific copy of the covered work, then the patent license
you grant is automatically extended to all recipients of the covered
work and works based on it.
A patent license is "discriminatory" if it does not include within
the scope of its coverage, prohibits the exercise of, or is
conditioned on the non-exercise of one or more of the rights that are
specifically granted under this License. You may not convey a covered
work if you are a party to an arrangement with a third party that is
in the business of distributing software, under which you make payment
to the third party based on the extent of your activity of conveying
the work, and under which the third party grants, to any of the
parties who would receive the covered work from you, a discriminatory
patent license (a) in connection with copies of the covered work
conveyed by you (or copies made from those copies), or (b) primarily
for and in connection with specific products or compilations that
contain the covered work, unless you entered into that arrangement,
or that patent license was granted, prior to 28 March 2007.
Nothing in this License shall be construed as excluding or limiting
any implied license or other defenses to infringement that may
otherwise be available to you under applicable patent law.
12. No Surrender of Others' Freedom.
If conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot convey a
covered work so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you may
not convey it at all. For example, if you agree to terms that obligate you
to collect a royalty for further conveying from those to whom you convey
the Program, the only way you could satisfy both those terms and this
License would be to refrain entirely from conveying the Program.
13. Remote Network Interaction; Use with the GNU General Public License.
Notwithstanding any other provision of this License, if you modify the
Program, your modified version must prominently offer all users
interacting with it remotely through a computer network (if your version
supports such interaction) an opportunity to receive the Corresponding
Source of your version by providing access to the Corresponding Source
from a network server at no charge, through some standard or customary
means of facilitating copying of software. This Corresponding Source
shall include the Corresponding Source for any work covered by version 3
of the GNU General Public License that is incorporated pursuant to the
following paragraph.
Notwithstanding any other provision of this License, you have
permission to link or combine any covered work with a work licensed
under version 3 of the GNU General Public License into a single
combined work, and to convey the resulting work. The terms of this
License will continue to apply to the part which is the covered work,
but the work with which it is combined will remain governed by version
3 of the GNU General Public License.
14. Revised Versions of this License.
The Free Software Foundation may publish revised and/or new versions of
the GNU Affero General Public License from time to time. Such new versions
will be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the
Program specifies that a certain numbered version of the GNU Affero General
Public License "or any later version" applies to it, you have the
option of following the terms and conditions either of that numbered
version or of any later version published by the Free Software
Foundation. If the Program does not specify a version number of the
GNU Affero General Public License, you may choose any version ever published
by the Free Software Foundation.
If the Program specifies that a proxy can decide which future
versions of the GNU Affero General Public License can be used, that proxy's
public statement of acceptance of a version permanently authorizes you
to choose that version for the Program.
Later license versions may give you additional or different
permissions. However, no additional obligations are imposed on any
author or copyright holder as a result of your choosing to follow a
later version.
15. Disclaimer of Warranty.
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
16. Limitation of Liability.
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
SUCH DAMAGES.
17. Interpretation of Sections 15 and 16.
If the disclaimer of warranty and limitation of liability provided
above cannot be given local legal effect according to their terms,
reviewing courts shall apply local law that most closely approximates
an absolute waiver of all civil liability in connection with the
Program, unless a warranty or assumption of liability accompanies a
copy of the Program in return for a fee.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
state the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published
by the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <https://www.gnu.org/licenses/>.
Also add information on how to contact you by electronic and paper mail.
If your software can interact with users remotely through a computer
network, you should also make sure that it provides a way for users to
get its source. For example, if your program is a web application, its
interface could display a "Source" link that leads users to an archive
of the code. There are many ways you could offer source, and different
solutions will be better for different programs; see section 13 for the
specific requirements.
You should also get your employer (if you work as a programmer) or school,
if any, to sign a "copyright disclaimer" for the program, if necessary.
For more information on this, and how to apply and follow the GNU AGPL, see
<https://www.gnu.org/licenses/>.
================================================
FILE: EasyJob/MainWindow.xaml
================================================
<Window x:Class="EasyJob.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:wpfRichTextBox="clr-namespace:WpfRichText;assembly=WpfRichText"
xmlns:ej="clr-namespace:EasyJob.Windows"
xmlns:local="clr-namespace:EasyJob"
xmlns:myAttachedProperties="clr-namespace:EasyJob.Utils"
xmlns:ui="http://schemas.modernwpf.com/2019"
ui:WindowHelper.UseModernWindowStyle="True"
mc:Ignorable="d" Icon="pack://application:,,,/Images/icon.ico"
Title="EasyJob Executor" Height="450" Width="800" WindowStartupLocation="CenterScreen">
<Window.Resources>
<ContextMenu x:Key="OnTabContextMenu">
<MenuItem Header="_Add tab" Click="ContextMenuAddTab_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/addtab.png"/>
</MenuItem.Icon>
</MenuItem>
<MenuItem Header="_Remove tab" Click="ContextMenuRemoveTab_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/removetab.png"/>
</MenuItem.Icon>
</MenuItem>
<MenuItem Header="Re_name tab" Click="ContextMenuRenameTab_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/renametab.png"/>
</MenuItem.Icon>
</MenuItem>
</ContextMenu>
<ContextMenu x:Key="OnActionButtonPannelContextMenu">
<MenuItem Header="_Add button" Click="ContextMenuAddActionButton_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/addbutton.png"/>
</MenuItem.Icon>
</MenuItem>
<MenuItem Header="Re_order buttons" Click="ContextMenuReorderActionButtons_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/reorderbuttons.png"/>
</MenuItem.Icon>
</MenuItem>
<MenuItem Header="_Paste button" IsEnabled="False" Click="ContextMenuPasteActionButton_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/paste.png"/>
</MenuItem.Icon>
</MenuItem>
</ContextMenu>
<ContextMenu x:Key="OnActionButtonContextMenu">
<MenuItem Header="_Edit button" Click="ContextMenuEditActionButton_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/editbutton.png"/>
</MenuItem.Icon>
</MenuItem>
<MenuItem Header="_Remove button" Click="ContextMenuRemoveActionButton_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/removebutton.png"/>
</MenuItem.Icon>
</MenuItem>
<MenuItem Header="_Copy button" Click="ContextMenuCopyActionButton_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/copy.png"/>
</MenuItem.Icon>
</MenuItem>
</ContextMenu>
</Window.Resources>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="*"/>
<RowDefinition Height="7"/>
<RowDefinition Height="84"/>
</Grid.RowDefinitions>
<Menu Grid.Row="0" FlowDirection="LeftToRight" IsMainMenu="True">
<MenuItem Header="_File" Focusable="False" IsTabStop="False">
<MenuItem Name="FileReloadConfigMenuItem" Header="Re_load config" Click="ReloadConfigMenuItem_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/reload.png"/>
</MenuItem.Icon>
</MenuItem>
<MenuItem Name="FileOpenAppFolderMenuItem" Header="_Open app folder" Click="OpenAppFolderMenuItem_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/folder.png"/>
</MenuItem.Icon>
</MenuItem>
<MenuItem Name="FileClearEventsLogListMenuItem" Header="_Clear events list" Click="ClearEventsLogListMenuItem_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/clear.png"/>
</MenuItem.Icon>
</MenuItem>
<Separator Name="FileSeparator1"/>
<MenuItem Name="FileExitMenuItem" Header="E_xit" Click="ExitMenuItem_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/exit.png"/>
</MenuItem.Icon>
</MenuItem>
</MenuItem>
<MenuItem Name="SettingsMenuItem" Header="_Settings" Focusable="False" IsTabStop="False">
<MenuItem Name="SettingsWorkflowMenuItem" Header="_Workflow">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/workflow.png"/>
</MenuItem.Icon>
<MenuItem Name="SettingsWorkflowReorderTabsMenuItem" Header="Re_order tabs" Click="ReorderTabsMenuItem_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/reordertabs.png"/>
</MenuItem.Icon>
</MenuItem>
<MenuItem Name="SettingsWorkflowAddTabMenuItem" Header="_Add tab" Click="AddTabMenuItem_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/addtab.png"/>
</MenuItem.Icon>
</MenuItem>
<MenuItem Name="SettingsWorkflowRemoveCurrentTabMenuItem" Header="Remo_ve current tab" Click="RemoveCurrentTabMenuItem_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/removetab.png"/>
</MenuItem.Icon>
</MenuItem>
<MenuItem Name="SettingsWorkflowRenameCurrentTabMenuItem" Header="_Rename current tab" Click="RenameCurrentTabMenuItem_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/renametab.png"/>
</MenuItem.Icon>
</MenuItem>
<MenuItem Name="SettingsWorkflowAddButtonToCurrentTabMenuItem" Header="Add _button to current tab" Click="AddButtonToCurrentTabMenuItem_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/addbutton.png"/>
</MenuItem.Icon>
</MenuItem>
<MenuItem Name="SettingsWorkflowReorderButtonsInCurrentTabMenuItem" Header="R_eorder buttons in current tab" Click="ReorderButtonsInCurrentTabMenuItem_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/reorderbuttons.png"/>
</MenuItem.Icon>
</MenuItem>
</MenuItem>
<MenuItem Name="SettingsConfigurationMenuItem" Header="_Configuration" Click="ConfigurationMenuItem_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/configuration.png"/>
</MenuItem.Icon>
</MenuItem>
</MenuItem>
<MenuItem Name="HelpMenuItem" Header="_Help" Focusable="False" IsTabStop="False">
<MenuItem Name="HelpTroubleshootingMenuItem" Header="_Troubleshooting" Click="MenuTroubleshooting_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/troubleshoot.png"/>
</MenuItem.Icon>
</MenuItem>
<MenuItem Name="HelpColorTagsMenuItem" Header="_Color tags" Click="MenuColorTags_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/colortags.png"/>
</MenuItem.Icon>
</MenuItem>
<MenuItem Name="HelpAboutMenuItem" Header="_About" Click="MenuAbout_Click">
<MenuItem.Icon>
<Image Source="pack://application:,,,/Images/about.png"/>
</MenuItem.Icon>
</MenuItem>
</MenuItem>
</Menu>
<TabControl x:Name="MainTab" Grid.Row="1">
<TabControl.ItemTemplate>
<DataTemplate>
<Label AutomationProperties.Name="{Binding TabHeader}" Content="{Binding TabHeader}" Name="TabHeaderSelector" PreviewMouseDown="OnTabHeader_PreviewMouseDown"/>
</DataTemplate>
</TabControl.ItemTemplate>
<TabControl.ContentTemplate>
<DataTemplate>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="7"/>
<RowDefinition Height="*"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<ScrollViewer Focusable="False" IsTabStop="False" x:Name="MainScroll" Grid.Row="0" Background="#F7F7F7" VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Auto" PreviewMouseDown="OnActionButtonPannel_PreviewMouseDown">
<ItemsControl ItemsSource="{Binding TabActionButtons}" Margin="8">
<ItemsControl.ItemsPanel>
<ItemsPanelTemplate>
<WrapPanel Orientation="Horizontal" MaxWidth="{Binding ActualWidth, ElementName=MainScroll}" Margin="0,0,-10,0"/>
</ItemsPanelTemplate>
</ItemsControl.ItemsPanel>
<ItemsControl.ItemTemplate>
<DataTemplate>
<Button AutomationProperties.Name="{Binding ButtonText}" Margin="0,5,5,0" Padding="5" Content="{Binding ButtonText}" Click="ActionButton_Click" PreviewMouseDown="ActionButton_PreviewMouseDown">
<Button.ToolTip>
<ToolTip Focusable="False" IsTabStop="False" Content="{Binding ButtonDescription}" />
</Button.ToolTip>
</Button>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
</ScrollViewer>
<GridSplitter Grid.Row="1" Height="5" HorizontalAlignment="Stretch"/>
<ScrollViewer IsTabStop="False" Focusable="False" Grid.Row="2" myAttachedProperties:ScrollViewerExtensions.AlwaysScrollToEnd="True">
<wpfRichTextBox:RichTextEditor Text="{Binding Path=TabTextBoxText, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" AutomationProperties.Name="Content" FontFamily="Consolas" Background="{Binding Path=ConsoleBackground}" Foreground="{Binding Path=ConsoleForeground}"/>
<!--<TextBox Text="{Binding Path=TabTextBoxText, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" TextWrapping="Wrap" AcceptsReturn="True" FontFamily="Consolas" Background="{Binding Path=ConsoleBackground}" Foreground="{Binding Path=ConsoleForeground}" VerticalScrollBarVisibility="Visible" HorizontalScrollBarVisibility="Disabled"/>-->
</ScrollViewer>
<Grid Grid.Row="3" Margin="0,5,0,5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="30"/>
<ColumnDefinition Width="30"/>
</Grid.ColumnDefinitions>
<Button AutomationProperties.Name="Clear content" Grid.Column="0" Margin="10,0,5,0" Padding="5" Content="_Clear Output" Click="ClearOutputButton_Click" />
<Button AutomationProperties.Name="Scroll to top" x:Name="ScrollToTopButton" Grid.Column="2" Margin="0,0,5,0" Padding="5" Click="ScrollToTopButton_Click">
<Image Source="pack://application:,,,/Images/up.png" Margin="-1"/>
</Button>
<Button AutomationProperties.Name="Scroll to bottom" x:Name="ScrollToBottomButton" Grid.Column="3" Margin="0,0,5,0" Padding="5" Click="ScrollToBottomButton_Click">
<Image Source="pack://application:,,,/Images/down.png" Margin="-1"/>
</Button>
</Grid>
</Grid>
</DataTemplate>
</TabControl.ContentTemplate>
</TabControl>
<GridSplitter Focusable="False" IsTabStop="False" Grid.Row="2" Height="5" HorizontalAlignment="Stretch"/>
<Grid Grid.Row="3">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="7"/>
<ColumnDefinition Width="250"/>
</Grid.ColumnDefinitions>
<ListBox AutomationProperties.Name="Events list" Grid.Column="0" x:Name="EventsList" ScrollViewer.HorizontalScrollBarVisibility="Disabled">
<ListBox.ItemTemplate>
<DataTemplate>
<Grid>
<TextBlock Text="{Binding}" TextWrapping="Wrap"/>
</Grid>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
<GridSplitter Focusable="False" IsTabStop="False" Grid.Column="1" Width="5" HorizontalAlignment="Stretch"/>
<ListBox AutomationProperties.Name="Tasks list" x:Name="TasksList" Grid.Column="2">
<ListBox.ItemTemplate>
<DataTemplate>
<StackPanel Margin="2" Orientation="Horizontal">
<Button AutomationProperties.Name="Stop task" Name="TasksListStop" Margin="0" Height="25" Width="25" Click="TasksListStop_Click">
<StackPanel Focusable="False" VerticalAlignment="Center" HorizontalAlignment="Center" Orientation="Horizontal" Background="Transparent">
<Image Source="pack://application:,,,/Images/close.png" Margin="-6,-2,-6,-2" HorizontalAlignment="Center" VerticalAlignment="Center"/>
</StackPanel>
</Button>
<TextBlock Margin="10 0 2 0" Text="{Binding Path=TaskID, Mode=TwoWay}" HorizontalAlignment="Left" Foreground="Blue"/>
<TextBlock Margin="5 0 2 0" Text="{Binding Path=TaskFile, Mode=TwoWay}" HorizontalAlignment="Left"/>
</StackPanel>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
</Grid>
</Grid>
</Window>
================================================
FILE: EasyJob/MainWindow.xaml.cs
================================================
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Input;
using System.Windows.Media;
using EasyJob.Serialization;
using EasyJob.Serialization.AnswerDialog;
using EasyJob.Serialization.TasksList;
using EasyJob.TabItems;
using EasyJob.Utils;
using EasyJob.Windows;
using Newtonsoft.Json;
using WpfRichText;
namespace EasyJob
{
public partial class MainWindow : Window
{
ActionButton actionButtonForCopy = null;
TabData selectedTabItem = null;
ActionButton selectedActionButton = null;
ObservableCollection<TaskListTask> tasksList = new ObservableCollection<TaskListTask>();
public Config config;
public MainWindow()
{
InitializeComponent();
LoadConfig();
MainMenuItemsVisibility();
}
public void LoadConfig()
{
if (File.Exists(ConfigUtils.ConfigJsonPath))
{
try
{
string configJson = File.ReadAllText(ConfigUtils.ConfigJsonPath);
config = JsonConvert.DeserializeObject<Config>(configJson);
MainTab.ItemsSource = ConfigUtils.ConvertTabsFromConfigToUI(config);
AddTextToEventsList("Config loaded from file: " + ConfigUtils.ConfigJsonPath, false);
}
catch (Exception ex)
{
MessageBox.Show(ex.Message, "Error", MessageBoxButton.OK, MessageBoxImage.Error);
AddTextToEventsList("Error occured while loading file: " + ex.Message, false);
}
}
else
{
MessageBox.Show("File " + ConfigUtils.ConfigJsonPath + " does not exist.", "Error", MessageBoxButton.OK, MessageBoxImage.Error);
}
}
public bool SaveConfig()
{
if (File.Exists(ConfigUtils.ConfigJsonPath))
{
try
{
IEnumerable<TabData> tabs = (IEnumerable<TabData>)MainTab.ItemsSource;
config.tabs.Clear();
List<ConfigTab> configTabs = new List<ConfigTab>();
List<ConfigButton> buttons = null;
List<ConfigArgument> configArguments = null;
foreach (TabData tab in tabs)
{
buttons = new List<ConfigButton>();
foreach (ActionButton button in tab.TabActionButtons)
{
configArguments = new List<ConfigArgument>();
foreach (Answer answer in button.ButtonArguments)
{
configArguments.Add(new ConfigArgument(answer.AnswerQuestion, answer.AnswerResult));
}
buttons.Add(new ConfigButton(button.ID, button.ButtonText, button.ButtonDescription, button.ButtonScript, button.ButtonScriptPathType, button.ButtonScriptType, configArguments));
}
configTabs.Add(new ConfigTab(tab.ID, tab.TabHeader, buttons));
}
config.tabs = configTabs;
if (ConfigUtils.SaveFromConfigToFile(config) == true)
{
return true;
}
else
{
return false;
}
}
catch (Exception ex)
{
MessageBox.Show(ex.Message, "Error", MessageBoxButton.OK, MessageBoxImage.Error);
return false;
}
}
else
{
SaveConfig();
}
return false;
}
private void MainMenuItemsVisibility()
{
// File
if (config.restrictions.hide_menu_item_file_reload_config == true) { FileReloadConfigMenuItem.Visibility = Visibility.Collapsed; } else { FileReloadConfigMenuItem.Visibility = Visibility.Visible; }
if (config.restrictions.hide_menu_item_file_open_app_folder == true) { FileOpenAppFolderMenuItem.Visibility = Visibility.Collapsed; } else { FileOpenAppFolderMenuItem.Visibility = Visibility.Visible; }
if (config.restrictions.hide_menu_item_file_clear_events_list == true) { FileClearEventsLogListMenuItem.Visibility = Visibility.Collapsed; } else { FileClearEventsLogListMenuItem.Visibility = Visibility.Visible; }
if (config.restrictions.hide_menu_item_file_reload_config == true && config.restrictions.hide_menu_item_file_open_app_folder == true && config.restrictions.hide_menu_item_file_clear_events_list == true) { FileSeparator1.Visibility = Visibility.Collapsed; } else { FileSeparator1.Visibility = Visibility.Visible; }
// Settings
if (config.restrictions.hide_menu_item_settings == true) { SettingsMenuItem.Visibility = Visibility.Collapsed; } else { SettingsMenuItem.Visibility = Visibility.Visible; }
if (config.restrictions.hide_menu_item_settings_workflow == true) { SettingsWorkflowMenuItem.Visibility = Visibility.Collapsed; } else { SettingsWorkflowMenuItem.Visibility = Visibility.Visible; }
if (config.restrictions.hide_menu_item_settings_workflow_reorder_tabs == true) { SettingsWorkflowReorderTabsMenuItem.Visibility = Visibility.Collapsed; } else { SettingsWorkflowReorderTabsMenuItem.Visibility = Visibility.Visible; }
if (config.restrictions.hide_menu_item_settings_workflow_add_tab == true) { SettingsWorkflowAddTabMenuItem.Visibility = Visibility.Collapsed; } else { SettingsWorkflowAddTabMenuItem.Visibility = Visibility.Visible; }
if (config.restrictions.hide_menu_item_settings_workflow_remove_current_tab == true) { SettingsWorkflowRemoveCurrentTabMenuItem.Visibility = Visibility.Collapsed; } else { SettingsWorkflowRemoveCurrentTabMenuItem.Visibility = Visibility.Visible; }
if (config.restrictions.hide_menu_item_settings_workflow_rename_current_tab == true) { SettingsWorkflowRenameCurrentTabMenuItem.Visibility = Visibility.Collapsed; } else { SettingsWorkflowRenameCurrentTabMenuItem.Visibility = Visibility.Visible; }
if (config.restrictions.hide_menu_item_settings_workflow_add_button_to_current_tab == true) { SettingsWorkflowAddButtonToCurrentTabMenuItem.Visibility = Visibility.Collapsed; } else { SettingsWorkflowAddButtonToCurrentTabMenuItem.Visibility = Visibility.Visible; }
if (config.restrictions.hide_menu_item_settings_workflow_reorder_buttons_in_current_tab == true) { SettingsWorkflowReorderButtonsInCurrentTabMenuItem.Visibility = Visibility.Collapsed; } else { SettingsWorkflowReorderButtonsInCurrentTabMenuItem.Visibility = Visibility.Visible; }
if (config.restrictions.hide_menu_item_settings_configuration == true) { SettingsConfigurationMenuItem.Visibility = Visibility.Collapsed; } else { SettingsConfigurationMenuItem.Visibility = Visibility.Visible; }
// Help
if (config.restrictions.hide_menu_item_help == true) { HelpMenuItem.Visibility = Visibility.Collapsed; } else { HelpMenuItem.Visibility = Visibility.Visible; }
if (config.restrictions.hide_menu_item_help_troubleshooting == true) { HelpTroubleshootingMenuItem.Visibility = Visibility.Collapsed; } else { HelpTroubleshootingMenuItem.Visibility = Visibility.Visible; }
if (config.restrictions.hide_menu_item_help_colortags == true) { HelpColorTagsMenuItem.Visibility = Visibility.Collapsed; } else { HelpColorTagsMenuItem.Visibility = Visibility.Visible; }
if (config.restrictions.hide_menu_item_help_about == true) { HelpAboutMenuItem.Visibility = Visibility.Collapsed; } else { HelpAboutMenuItem.Visibility = Visibility.Visible; }
}
private void AddTextToConsole (string Text, int OwnerTab)
{
if(Text == "" || Text == null || Text == "Error: ")
{
return;
}
if (config.console_ignore_color_tags == false)
{
Text = CommonUtils.ApplyConsoleColorTagsToText(Text);
}
//this.Dispatcher.Invoke(() =>
//{
TabData td = (TabData)MainTab.Items[OwnerTab];
td.TabTextBoxText = td.TabTextBoxText + "<br>" + Text;
//});
}
public void AddTextToEventsList(string Text, bool IsAsync)
{
if (Text == "" || Text == null || Text == "Error: ")
{
return;
}
if (IsAsync == true)
{
this.Dispatcher.Invoke(() =>
{
EventsList.Items.Add(Text);
EventsList.ScrollIntoView(EventsList.Items.Count - 1);
});
}
else
{
EventsList.Items.Add(Text);
EventsList.ScrollIntoView(EventsList.Items.Count - 1);
}
}
private void ScrollToBottomListBox(ListBox listBox, bool IsAsync)
{
if(listBox == null && listBox.Items.Count == 0)
{
return;
}
if (IsAsync == true)
{
this.Dispatcher.Invoke(() =>
{
if (listBox != null)
{
var border = (Border)VisualTreeHelper.GetChild(listBox, 0);
var scrollViewer = (ScrollViewer)VisualTreeHelper.GetChild(border, 0);
scrollViewer.ScrollToBottom();
}
});
}
else
{
if (listBox != null)
{
var border = (Border)VisualTreeHelper.GetChild(listBox, 0);
var scrollViewer = (ScrollViewer)VisualTreeHelper.GetChild(border, 0);
scrollViewer.ScrollToBottom();
}
}
}
private void RemoveTaskFromTasksList(int ProcessID, bool IsAsync)
{
if (IsAsync == true)
{
this.Dispatcher.Invoke(() =>
{
ObservableCollection<TaskListTask> taskListsNew = new ObservableCollection<TaskListTask>();
foreach (TaskListTask tlt in tasksList)
{
if (tlt.TaskID == ProcessID)
{
continue;
}
taskListsNew.Add(new TaskListTask { TaskID = tlt.TaskID });
}
tasksList = taskListsNew;
TasksList.ItemsSource = taskListsNew;
});
}
else
{
ObservableCollection<TaskListTask> taskListsNew = new ObservableCollection<TaskListTask>();
foreach (TaskListTask tlt in tasksList)
{
if (tlt.TaskID == ProcessID)
{
continue;
}
taskListsNew.Add(new TaskListTask { TaskID = tlt.TaskID });
}
tasksList = taskListsNew;
TasksList.ItemsSource = taskListsNew;
}
}
private void AddTaskToTasksList(int ProcessID, string ProcessFileName)
{
tasksList.Add(new TaskListTask { TaskID = ProcessID, TaskFile = ProcessFileName });
TasksList.ItemsSource = tasksList;
}
private string GetScriptPath(string ButtonScript, string ButtonScriptPathType)
{
string scriptPath = "";
if (ButtonScriptPathType.ToLower() == "absolute")
{
scriptPath = ButtonScript;
}
else if (ButtonScriptPathType.ToLower() == "relative")
{
scriptPath = AppDomain.CurrentDomain.BaseDirectory + ButtonScript;
}
else
{
scriptPath = ButtonScript;
}
return scriptPath;
}
private string GetPowerShellArguments(string Arguments)
{
string arguments = "";
if(Arguments.Length > 0)
{
arguments = " " + Arguments + " ";
}
return arguments;
}
private void ShowAddButtonDialog()
{
AddActionButtonDialog aabd = new AddActionButtonDialog();
if (aabd.ShowDialog() == true)
{
if (MainTab.Items[MainTab.SelectedIndex] is TabData button)
{
List<Answer> answers = new List<Answer>();
foreach (ConfigArgument ca in aabd.configButton.Arguments)
{
answers.Add(new Answer { AnswerQuestion = ca.ArgumentQuestion, AnswerResult = ca.ArgumentAnswer });
}
button.TabActionButtons.Add(new ActionButton { ButtonText = aabd.configButton.Text, ButtonDescription = aabd.configButton.Description, ButtonScript = aabd.configButton.Script, ButtonScriptPathType = aabd.configButton.ScriptPathType, ButtonScriptType = aabd.configButton.ScriptType, ButtonArguments = answers });
}
if (SaveConfig())
{
MainTab.Items.Refresh();
this.UpdateLayout();
AddTextToEventsList("Button '" + aabd.configButton.Text + "' has been successfully added", false);
}
}
else
{
AddTextToEventsList("Adding button cancelled by user", false);
}
}
private void ShowRenameTabDialog(int SelectedTab, string SelectedTabHeader)
{
RenameTabDialog rtd = new RenameTabDialog(SelectedTabHeader);
if (rtd.ShowDialog() == true)
{
List<TabData> newSourceTabs = new List<TabData>();
foreach (TabData tab in MainTab.Items)
{
TabData currentTab = MainTab.Items[SelectedTab] as TabData;
if (tab == currentTab)
{
tab.TabHeader = rtd.NewTabName;
}
newSourceTabs.Add(tab);
}
MainTab.ItemsSource = null;
MainTab.ItemsSource = newSourceTabs;
if (SaveConfig())
{
MainTab.Items.Refresh();
this.UpdateLayout();
}
}
else
{
AddTextToEventsList("Current tab rename cancelled by user", false);
}
}
private void ShowAddNewTabDialog()
{
NewTabDialog ntd = new NewTabDialog();
if(ntd.ShowDialog() == true)
{
LoadConfig();
MainTab.Items.Refresh();
this.UpdateLayout();
}
else
{
AddTextToEventsList("Adding new Tab cancelled by user", false);
}
}
private void ShowReorderActionButtonsDialog()
{
int currentTab = MainTab.SelectedIndex;
ReorderActionButtonsDialog rabd = new ReorderActionButtonsDialog(MainTab.SelectedIndex, config);
rabd.ShowDialog();
if (rabd.changesOccured)
{
LoadConfig();
MainTab.Items.Refresh();
this.UpdateLayout();
AddTextToEventsList("Reorder action buttons dialog ended!", false);
MainTab.SelectedIndex = currentTab;
}
else
{
AddTextToEventsList("Reorder action buttons dialog ended. No changes occured!", false);
}
}
public void ClearOutputButton_Click(object sender, RoutedEventArgs e)
{
TabData td = (TabData)MainTab.SelectedItem;
td.TabTextBoxText = "";
AddTextToEventsList("Output has been cleared!", false);
}
public AnswerData ConvertArgumentsToAnswers(List<Answer> Answers)
{
AnswerData answerData = new AnswerData();
answerData.Answers = Answers;
return answerData;
}
public string ConvertArgumentsToPowerShell(List<Answer> Answers)
{
string powerShellArguments = "";
foreach (Answer answer in Answers)
{
powerShellArguments = powerShellArguments + answer.AnswerResult + " ";
}
if (powerShellArguments.EndsWith(" "))
{
powerShellArguments = powerShellArguments.Remove(powerShellArguments.Length - 1);
}
return powerShellArguments;
}
public string ConvertArgumentsToCMD(List<Answer> Answers)
{
string powerShellArguments = "";
foreach (Answer answer in Answers)
{
powerShellArguments = powerShellArguments + answer.AnswerResult + " ";
}
if (powerShellArguments.EndsWith(" "))
{
powerShellArguments = powerShellArguments.Remove(powerShellArguments.Length - 1);
}
return powerShellArguments;
}
public string RemoveScriptFileFromPath(string ScriptPath)
{
string[] scriptPathSplits = ScriptPath.Split("\\");
string newScriptPath = "";
if(scriptPathSplits.Length > 0)
{
for (int i = 0; i < scriptPathSplits.Length - 1; i++)
{
newScriptPath += scriptPathSplits[i] + "\\";
}
}
return newScriptPath;
}
public async void ActionButton_Click(object sender, RoutedEventArgs e)
{
Button actionButton = sender as Button;
string buttonScript = ((ActionButton)actionButton.DataContext).ButtonScript;
string buttonScriptPathType = ((ActionButton)actionButton.DataContext).ButtonScriptPathType;
string buttonScriptType = ((ActionButton)actionButton.DataContext).ButtonScriptType;
string scriptPath = GetScriptPath(buttonScript, buttonScriptPathType);
string powershellArguments = GetPowerShellArguments(config.powershell_arguments);
int ownerTab = MainTab.SelectedIndex;
if (Keyboard.IsKeyDown(Key.LeftCtrl) || Keyboard.IsKeyDown(Key.RightCtrl))
{
try
{
Process.Start("explorer.exe", GetScriptPath(RemoveScriptFileFromPath(buttonScript), buttonScriptPathType));
AddTextToEventsList("Opened script location folder: " + GetScriptPath(RemoveScriptFileFromPath(buttonScript), buttonScriptPathType), false);
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
AddTextToEventsList("Could not open script location folder: " + ex.Message, false);
}
return;
}
if (Keyboard.IsKeyDown(Key.LeftShift) || Keyboard.IsKeyDown(Key.RightShift))
{
try
{
Process.Start("explorer.exe", scriptPath);
AddTextToEventsList("Opened script : " + scriptPath, false);
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
AddTextToEventsList("Could not open script: " + ex.Message, false);
}
return;
}
List<Answer> buttonArguments = ((ActionButton)actionButton.DataContext).ButtonArguments;
AddTextToConsole("Start script: " + scriptPath + "<br><span style=\"color:yellow;\">=====================================================================</span><br>", ownerTab);
AddTextToEventsList("Execution of " + scriptPath + " has been started.", false);
if (buttonArguments.Count == 0)
{
AddTextToEventsList("Starting script " + scriptPath, false);
if (buttonScriptType.ToLower() == "powershell")
{
await RunProcessAsync(config.default_powershell_path, powershellArguments + "-File \"" + scriptPath + "\"", ownerTab, buttonScript);
}
else
{
await RunProcessAsync(config.default_cmd_path, "/c \"" + scriptPath + "\"", ownerTab, buttonScript);
}
}
else
{
AnswerDialog dialog = new AnswerDialog(ConvertArgumentsToAnswers(buttonArguments));
if (dialog.ShowDialog() == true)
{
AddTextToEventsList("Starting script" + scriptPath, false);
if (buttonScriptType.ToLower() == "powershell")
{
await RunProcessAsync(config.default_powershell_path, powershellArguments + "-File \"" + scriptPath + "\" " + ConvertArgumentsToPowerShell(dialog.answerData.Answers), ownerTab, buttonScript);
}
else
{
await RunProcessAsync(config.default_cmd_path, powershellArguments + "/c \"" + scriptPath + "\" " + ConvertArgumentsToCMD(dialog.answerData.Answers), ownerTab, buttonScript);
}
}
else
{
AddTextToEventsList("Task cancelled by user", false);
AddTextToConsole("Task cancelled by user!", ownerTab);
}
}
}
public async Task<int> RunProcessAsync(string FileName, string Args, int OwnerTab, string ScriptName)
{
using (var process = new Process
{
StartInfo =
{
FileName = FileName, Arguments = Args,
UseShellExecute = false, CreateNoWindow = true,
RedirectStandardOutput = true, RedirectStandardError = true
},
EnableRaisingEvents = true
})
{
return await RunProcessAsync(process, OwnerTab, ScriptName).ConfigureAwait(false);
}
}
private Task<int> RunProcessAsync(Process process, int OwnerTab, string ScriptName)
{
var tcs = new TaskCompletionSource<int>();
// Process Exited
process.Exited += (s, ea) =>
{
RemoveTaskFromTasksList(process.Id, true);
tcs.SetResult(process.ExitCode);
AddTextToConsole("<br><span style=\"color:yellow;\">Task finished!</span><br>", OwnerTab);
AddTextToEventsList("Task " + process.StartInfo.Arguments.Replace("-File ", "") + " finished", true);
ScrollToBottomListBox(EventsList, true);
};
// Process Output data received
process.OutputDataReceived += (s, ea) => {
AddTextToConsole(ea.Data, OwnerTab);
};
// Process Error output received
process.ErrorDataReceived += (s, ea) => {
if (ea.Data != null)
{
if (ea.Data != "")
{
AddTextToConsole("<span style=\"color:red;\">Error: " + ea.Data + "</span>", OwnerTab);
AddTextToEventsList("Task " + process.StartInfo.Arguments.Replace("-File ", "") + " failed", true);
}
}
};
// Start the process
bool started = process.Start();
if (!started)
{
throw new InvalidOperationException("Could not start process: " + process);
}
// Add to tasks list
AddTaskToTasksList(process.Id, ScriptName.Split("\\")[ScriptName.Split("\\").Length - 1]);
// Begin to read data from the output
process.BeginOutputReadLine();
process.BeginErrorReadLine();
return tcs.Task;
}
private void TasksListStop_Click(object sender, RoutedEventArgs e)
{
try
{
Button buttonStop = sender as Button;
int processID = ((TaskListTask)buttonStop.DataContext).TaskID;
Process.GetProcessById(processID).Kill();
AddTextToEventsList("Process has been cancelled by user!", false);
RemoveTaskFromTasksList(processID, false);
}
catch (Exception ex)
{
MessageBox.Show(ex.Message, "Error", MessageBoxButton.OK, MessageBoxImage.Error);
AddTextToEventsList("Process cancelled failed: " + ex.Message, false);
}
}
private void ScrollToTopButton_Click(object sender, RoutedEventArgs e)
{
try
{
RichTextEditor console = FindVisualChild<RichTextEditor>(MainTab);
console.MoveFocus(new TraversalRequest(FocusNavigationDirection.First));
var scrollViewElement = console.Parent;
ScrollViewer scrollView = scrollViewElement as ScrollViewer;
scrollView.ScrollToTop();
}
catch { }
}
private void ScrollToBottomButton_Click(object sender, RoutedEventArgs e)
{
try
{
RichTextEditor console = FindVisualChild<RichTextEditor>(MainTab);
console.MoveFocus(new TraversalRequest(FocusNavigationDirection.Last));
var scrollViewElement = console.Parent;
ScrollViewer scrollView = scrollViewElement as ScrollViewer;
scrollView.ScrollToBottom();
}
catch { }
}
private static T FindVisualChild<T>(DependencyObject parent) where T : DependencyObject
{
for (int childCount = 0; childCount < VisualTreeHelper.GetChildrenCount(parent); childCount++)
{
DependencyObject child = VisualTreeHelper.GetChild(parent, childCount);
if (child != null && child is T)
return (T)child;
else
{
T childOfChild = FindVisualChild<T>(child);
if (childOfChild != null)
return childOfChild;
}
}
return null;
}
#region MenuItems
private void ReloadConfigMenuItem_Click(object sender, RoutedEventArgs e)
{
try
{
if (config.clear_events_when_reload == true)
{
EventsList.Items.Clear();
}
else
{
AddTextToEventsList("Relading config!", false);
}
MainTab.ItemsSource = null;
LoadConfig();
if(MainTab.Items.Count > 0)
{
MainTab.SelectedIndex = 0;
}
}
catch(Exception ex)
{
MessageBox.Show(ex.Message, "Error", MessageBoxButton.OK, MessageBoxImage.Error);
AddTextToEventsList("Relading config failed: " + ex.Message, false);
}
}
private void OpenAppFolderMenuItem_Click(object sender, RoutedEventArgs e)
{
try
{
Process.Start("explorer.exe", AppDomain.CurrentDomain.BaseDirectory);
}
catch (Exception ex)
{
MessageBox.Show(ex.Message, "Error", MessageBoxButton.OK, MessageBoxImage.Error);
AddTextToEventsList("Opened application running folder", false);
}
}
private void ClearEventsLogListMenuItem_Click(object sender, RoutedEventArgs e)
{
EventsList.Items.Clear();
}
private void ReorderTabsMenuItem_Click(object sender, RoutedEventArgs e)
{
ReorderTabsDialog rtd = new ReorderTabsDialog(config);
rtd.ShowDialog();
if (rtd.changesOccured)
{
LoadConfig();
MainTab.Items.Refresh();
this.UpdateLayout();
AddTextToEventsList("Reorder tabs dialog ended!", false);
}
else
{
AddTextToEventsList("Reorder tabs dialog ended. No changes occured!", false);
}
}
private void ConfigurationMenuItem_Click(object sender, RoutedEventArgs e)
{
ConfigurationDialog cfg = new ConfigurationDialog(config);
cfg.ShowDialog();
LoadConfig();
MainTab.Items.Refresh();
MainMenuItemsVisibility();
this.UpdateLayout();
AddTextToEventsList("Configuration ended!", false);
}
private void AddTabMenuItem_Click(object sender, RoutedEventArgs e)
{
ShowAddNewTabDialog();
}
private void RemoveCurrentTabMenuItem_Click(object sender, RoutedEventArgs e)
{
if (MessageBox.Show("Do you want to delete current tab?", "Please confirm", MessageBoxButton.YesNo) == MessageBoxResult.Yes)
{
List<TabData> newSourceTabs = new List<TabData>();
foreach (TabData tab in MainTab.Items)
{
TabData currentTab = MainTab.Items[MainTab.SelectedIndex] as TabData;
if (tab != currentTab)
{
newSourceTabs.Add(tab);
}
}
MainTab.ItemsSource = null;
MainTab.ItemsSource = newSourceTabs;
if (SaveConfig())
{
MainTab.Items.Refresh();
this.UpdateLayout();
}
}
}
private void RenameCurrentTabMenuItem_Click(object sender, RoutedEventArgs e)
{
TabData tab = (TabData)MainTab.Items[MainTab.SelectedIndex];
ShowRenameTabDialog(MainTab.SelectedIndex, tab.TabHeader);
}
private void AddButtonToCurrentTabMenuItem_Click(object sender, RoutedEventArgs e)
{
ShowAddButtonDialog();
}
private void ReorderButtonsInCurrentTabMenuItem_Click(object sender, RoutedEventArgs e)
{
ShowReorderActionButtonsDialog();
}
private void ExitMenuItem_Click(object sender, RoutedEventArgs e)
{
if(tasksList.Count > 0)
{
if(MessageBox.Show("Task is still going. Do you want to exit? You will have to kill process manually if you exit", "Please confirm", MessageBoxButton.YesNoCancel) == MessageBoxResult.Yes)
{
Application.Current.Shutdown();
}
}
else
{
Application.Current.Shutdown();
}
}
private void MenuAbout_Click(object sender, RoutedEventArgs e)
{
AboutDialog aboutDialog = new AboutDialog();
aboutDialog.ShowDialog();
}
private void MenuTroubleshooting_Click(object sender, RoutedEventArgs e)
{
TroubleshootingWindow troubleshootingDialog = new TroubleshootingWindow(config);
troubleshootingDialog.Show();
}
private void MenuColorTags_Click(object sender, RoutedEventArgs e)
{
ColorTagsDialog colorTagsDialog = new ColorTagsDialog();
colorTagsDialog.Show();
}
#endregion
#region ContextMenuItems
public void ActionButton_PreviewMouseDown(object sender, MouseButtonEventArgs e)
{
if (e.RightButton == MouseButtonState.Pressed)
{
selectedActionButton = ((Button)e.Source).DataContext as ActionButton;
ContextMenu cm = this.FindResource("OnActionButtonContextMenu") as ContextMenu;
if (e.Source is not ScrollViewer && e.OriginalSource is TextBlock)
{
if (config.restrictions.block_buttons_edit == true && config.restrictions.block_buttons_remove == true && config.restrictions.block_buttons_copy == true)
{
return;
}
else
{
if (config.restrictions.block_buttons_edit == false)
{
(cm.Items[0] as MenuItem).Visibility = Visibility.Visible;
}
else
{
(cm.Items[0] as MenuItem).Visibility = Visibility.Collapsed;
}
if (config.restrictions.block_buttons_remove == false)
{
(cm.Items[1] as MenuItem).Visibility = Visibility.Visible;
}
else
{
(cm.Items[1] as MenuItem).Visibility = Visibility.Collapsed;
}
if (config.restrictions.block_buttons_copy == false)
{
(cm.Items[2] as MenuItem).Visibility = Visibility.Visible;
}
else
{
(cm.Items[2] as MenuItem).Visibility = Visibility.Collapsed;
}
}
cm.PlacementTarget = sender as Button;
cm.IsOpen = true;
}
}
}
public void OnActionButtonPannel_PreviewMouseDown(object sender, MouseButtonEventArgs e)
{
if (e.RightButton == MouseButtonState.Pressed)
{
ContextMenu cm = this.FindResource("OnActionButtonPannelContextMenu") as ContextMenu;
if (e.Source is ScrollViewer && e.OriginalSource is not TextBlock)
{
if (config.restrictions.block_buttons_add == true && config.restrictions.block_buttons_reorder == true && config.restrictions.block_buttons_paste == true)
{
return;
}
else
{
if (config.restrictions.block_buttons_add == false)
{
(cm.Items[0] as MenuItem).Visibility = Visibility.Visible;
}
else
{
(cm.Items[0] as MenuItem).Visibility = Visibility.Collapsed;
}
if (config.restrictions.block_buttons_reorder == false)
{
(cm.Items[1] as MenuItem).Visibility = Visibility.Visible;
}
else
{
(cm.Items[1] as MenuItem).Visibility = Visibility.Collapsed;
}
if (config.restrictions.block_buttons_paste == false)
{
(cm.Items[2] as MenuItem).Visibility = Visibility.Visible;
if(actionButtonForCopy != null)
{
(cm.Items[2] as MenuItem).IsEnabled = true;
}
else
{
(cm.Items[2] as MenuItem).IsEnabled = false;
}
}
else
{
(cm.Items[2] as MenuItem).Visibility = Visibility.Collapsed;
}
}
cm.PlacementTarget = sender as ScrollViewer;
cm.IsOpen = true;
}
}
}
private void OnTabHeader_PreviewMouseDown(object sender, MouseButtonEventArgs e)
{
if (e.RightButton == MouseButtonState.Pressed)
{
selectedTabItem = ((Label)e.Source).DataContext as TabData;
ContextMenu cm = this.FindResource("OnTabContextMenu") as ContextMenu;
if (config.restrictions.block_tabs_add == true && config.restrictions.block_tabs_remove == true && config.restrictions.block_tabs_rename == true)
{
return;
}
else
{
if (config.restrictions.block_tabs_add == false)
{
(cm.Items[0] as MenuItem).Visibility = Visibility.Visible;
}
else
{
(cm.Items[0] as MenuItem).Visibility = Visibility.Collapsed;
}
if (config.restrictions.block_tabs_remove == false)
{
(cm.Items[1] as MenuItem).Visibility = Visibility.Visible;
}
else
{
(cm.Items[1] as MenuItem).Visibility = Visibility.Collapsed;
}
if (config.restrictions.block_tabs_rename == false)
{
(cm.Items[2] as MenuItem).Visibility = Visibility.Visible;
}
else
{
(cm.Items[2] as MenuItem).Visibility = Visibility.Collapsed;
}
}
cm.PlacementTarget = sender as Label;
cm.IsOpen = true;
}
}
private void ContextMenuRemoveTab_Click(object sender, RoutedEventArgs e)
{
if (selectedTabItem == null)
{
MessageBox.Show("Selected Tab is still null. Please try again.");
return;
}
List<TabData> newSourceTabs = new List<TabData>();
foreach (TabData tab in MainTab.Items)
{
if (tab != selectedTabItem)
{
newSourceTabs.Add(tab);
}
}
MainTab.ItemsSource = null;
MainTab.ItemsSource = newSourceTabs;
if (SaveConfig())
{
MainTab.Items.Refresh();
this.UpdateLayout();
}
}
private void ContextMenuRenameTab_Click(object sender, RoutedEventArgs e)
{
if (selectedTabItem == null)
{
MessageBox.Show("Selected Tab is still null. Please try again.");
return;
}
int currentTabIndex = 0;
List<TabData> newSourceTabs = new List<TabData>();
foreach (TabData tab in MainTab.Items)
{
if (tab == selectedTabItem)
{
ShowRenameTabDialog(currentTabIndex, selectedTabItem.TabHeader);
return;
}
else
{
currentTabIndex = currentTabIndex + 1;
}
}
}
private void ContextMenuAddTab_Click(object sender, RoutedEventArgs e)
{
ShowAddNewTabDialog();
}
private void ContextMenuRemoveActionButton_Click(object sender, RoutedEventArgs e)
{
if (selectedActionButton == null)
{
MessageBox.Show("Selected Action button is still null. Please try again.");
return;
}
for (int i = 0; i < MainTab.Items.Count; i++)
{
if (MainTab.Items[i] is TabData button)
{
var item = button.TabActionButtons.Where(x => x.Equals(selectedActionButton)).FirstOrDefault();
if (item != null)
{
button.TabActionButtons.Remove(item);
}
}
}
if (SaveConfig())
{
MainTab.Items.Refresh();
this.UpdateLayout();
}
}
private void ContextMenuCopyActionButton_Click(object sender, RoutedEventArgs e)
{
if (selectedActionButton == null)
{
MessageBox.Show("Selected Action button is still null. Please try again.");
return;
}
actionButtonForCopy = selectedActionButton;
}
private void ContextMenuEditActionButton_Click(object sender, RoutedEventArgs e)
{
if (selectedActionButton == null)
{
MessageBox.Show("Selected Action button is still null. Please try again.");
return;
}
EditActionButtonDialog eabd = new EditActionButtonDialog(selectedActionButton);
if(eabd.ShowDialog() == true)
{
for (int i = 0; i < MainTab.Items.Count; i++)
{
if (MainTab.Items[i] is TabData button)
{
var item = button.TabActionButtons.Where(x => x.Equals(selectedActionButton)).FirstOrDefault();
if (item != null)
{
item = eabd.actionButton;
}
}
}
if (SaveConfig())
{
MainTab.Items.Refresh();
this.UpdateLayout();
}
}
else
{
AddTextToEventsList("Edit button cancelled by user", false);
}
}
private void ContextMenuAddActionButton_Click(object sender, RoutedEventArgs e)
{
ShowAddButtonDialog();
}
private void ContextMenuReorderActionButtons_Click(object sender, RoutedEventArgs e)
{
ShowReorderActionButtonsDialog();
}
private void ContextMenuPasteActionButton_Click(object sender, RoutedEventArgs e)
{
if (actionButtonForCopy == null)
{
return;
}
TabData tab = (TabData) MainTab.Items[MainTab.SelectedIndex];
actionButtonForCopy.ID = Guid.NewGuid();
tab.TabActionButtons.Add(actionButtonForCopy);
if (SaveConfig())
{
MainTab.Items.Refresh();
this.UpdateLayout();
}
}
#endregion
}
}
================================================
FILE: EasyJob/Serialization/AnswerDialog/Answer.cs
================================================
namespace EasyJob.Serialization.AnswerDialog
{
public class Answer
{
public string AnswerQuestion { get; set; }
public string AnswerResult { get; set; }
}
}
================================================
FILE: EasyJob/Serialization/AnswerDialog/AnswerData.cs
================================================
using System.Collections.Generic;
namespace EasyJob.Serialization.AnswerDialog
{
public class AnswerData
{
private List<Answer> _Answers = new List<Answer>();
public List<Answer> Answers
{
get { return _Answers; }
set { _Answers = value; }
}
}
}
================================================
FILE: EasyJob/Serialization/Config/Config.cs
================================================
using System.Collections.Generic;
namespace EasyJob.Serialization
{
public class Config
{
public string default_powershell_path { get; set; }
public string default_cmd_path { get; set; }
public string powershell_arguments { get; set; }
public string console_background { get; set; }
public string console_foreground { get; set; }
public bool console_ignore_color_tags { get; set; }
public bool clear_events_when_reload { get; set; }
public ConfigRestrictions restrictions { get; set; }
public List<ConfigTab> tabs { get; set; }
}
}
================================================
FILE: EasyJob/Serialization/Config/ConfigArgument.cs
================================================
namespace EasyJob.Serialization
{
public class ConfigArgument
{
private string _argument_question;
private string _argument_answer;
/// <summary>
/// Initializes a new instance of the <see cref="ConfigArgument"/> class.
/// </summary>
/// <param name="argument_question">The argument question.</param>
/// <param name="argument_answer">The argument answer.</param>
public ConfigArgument(string argument_question, string argument_answer)
{
this._argument_question = argument_question;
this._argument_answer = argument_answer;
}
/// <summary>
/// Gets or sets the argument question.
/// </summary>
/// <value>
/// The argument question.
/// </value>
public string ArgumentQuestion { get => _argument_question; set => _argument_question = value; }
/// <summary>
/// Gets or sets the argument answer.
/// </summary>
/// <value>
/// The argument answer.
/// </value>
public string ArgumentAnswer { get => _argument_answer; set => _argument_answer = value; }
}
}
================================================
FILE: EasyJob/Serialization/Config/ConfigButton.cs
================================================
using System;
using System.Collections.Generic;
namespace EasyJob.Serialization
{
public class ConfigButton
{
private Guid _id;
private string _text;
private string _description;
private string _script;
private string _scriptpathtype;
private string _scripttype;
private List<ConfigArgument> _arguments;
/// <summary>
/// Initializes a new instance of the <see cref="ConfigButton"/> class.
/// </summary>
/// <param name="text">The text.</param>
/// <param name="description">The description.</param>
/// <param name="script">The script.</param>
/// <param name="scriptpathtype">The scriptpathtype.</param>
/// <param name="scripttype">The scripttype.</param>
/// <param name="arguments">The arguments.</param>
/// <summary>
public ConfigButton(Guid id, string text, string description, string script, string scriptpathtype, string scripttype, List<ConfigArgument> arguments)
{
this._id = id.Equals(Guid.Empty) ? Guid.NewGuid() : id;
this._text = text;
this._description = description;
this._script = script;
this._scriptpathtype = scriptpathtype;
this._scripttype = scripttype;
this._arguments = arguments;
}
/// <summary>
/// Gets or sets the identifier.
/// </summary>
/// <value>
/// The identifier.
/// </value>
public Guid Id { get => _id; set => _id = value; }
/// <summary>
/// Gets or sets the text.
/// </summary>
/// <value>
/// The text.
/// </value>
public string Text { get => _text; set => _text = value; }
/// <summary>
/// Gets or sets the description.
/// </summary>
/// <value>
/// The description.
/// </value>
public string Description { get => _description; set => _description = value; }
/// <summary>
/// Gets or sets the script.
/// </summary>
/// <value>
/// The script.
/// </value>
public string Script { get => _script; set => _script = value; }
/// <summary>
/// Gets or sets the type of the script path.
/// </summary>
/// <value>
/// The type of the script path.
/// </value>
public string ScriptPathType { get => _scriptpathtype; set => _scriptpathtype = value; }
/// <summary>
/// Gets or sets the type of the script.
/// </summary>
/// <value>
/// The type of the script.
/// </value>
public string ScriptType { get => _scripttype; set => _scripttype = value; }
/// <summary>
/// Gets or sets the arguments.
/// </summary>
/// <value>
/// The arguments.
/// </value>
public List<ConfigArgument> Arguments { get => _arguments; set => _arguments = value; }
}
}
================================================
FILE: EasyJob/Serialization/Config/ConfigRestrictions.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace EasyJob.Serialization
{
public class ConfigRestrictions
{
public bool block_tabs_remove { get; set; }
public bool block_buttons_remove { get; set; }
public bool block_tabs_add { get; set; }
public bool block_buttons_add { get; set; }
public bool block_buttons_reorder { get; set; }
public bool block_buttons_edit { get; set; }
public bool block_tabs_rename { get; set; }
public bool block_buttons_paste { get; set; }
public bool block_buttons_copy { get; set; }
public bool hide_menu_item_file_reload_config { get; set; }
public bool hide_menu_item_file_open_app_folder { get; set; }
public bool hide_menu_item_file_clear_events_list { get; set; }
public bool hide_menu_item_settings { get; set; }
public bool hide_menu_item_settings_workflow { get; set; }
public bool hide_menu_item_settings_workflow_reorder_tabs { get; set; }
public bool hide_menu_item_settings_workflow_add_tab { get; set; }
public bool hide_menu_item_settings_workflow_remove_current_tab { get; set; }
public bool hide_menu_item_settings_workflow_rename_current_tab { get; set; }
public bool hide_menu_item_settings_workflow_add_button_to_current_tab { get; set; }
public bool hide_menu_item_settings_workflow_reorder_buttons_in_current_tab { get; set; }
public bool hide_menu_item_settings_configuration { get; set; }
public bool hide_menu_item_help { get; set; }
public bool hide_menu_item_help_troubleshooting { get; set; }
public bool hide_menu_item_help_colortags { get; set; }
public bool hide_menu_item_help_about { get; set; }
}
}
================================================
FILE: EasyJob/Serialization/Config/ConfigTab.cs
================================================
using System;
using System.Collections.Generic;
namespace EasyJob.Serialization
{
public class ConfigTab
{
private Guid _id;
private string _header;
private List<ConfigButton> _buttons;
/// <summary>
/// Initializes a new instance of the <see cref="ConfigTab"/> class.
/// </summary>
/// <param name="id">The identifier.</param>
/// <param name="header">The header.</param>
/// <param name="buttons">The buttons.</param>
public ConfigTab(Guid id, string header, List<ConfigButton> buttons)
{
this._id = id.Equals(Guid.Empty) ? Guid.NewGuid() : id;
this._header = header;
this._buttons = buttons;
}
/// <summary>
/// Gets or sets the identifier.
/// </summary>
/// <value>
/// The identifier.
/// </value>
public Guid ID { get => _id; set => _id = value; }
/// <summary>
/// Gets or sets the header.
/// </summary>
/// <value>
/// The header.
/// </value>
public string Header { get => _header; set => _header = value; }
/// <summary>
/// Gets or sets the buttons.
/// </summary>
/// <value>
/// The buttons.
/// </value>
public List<ConfigButton> Buttons { get => _buttons; set => _buttons = value; }
}
}
================================================
FILE: EasyJob/Serialization/TabItems/ActionButton.cs
================================================
using System;
using System.Collections.Generic;
using System.Windows.Controls;
using EasyJob.Serialization.AnswerDialog;
namespace EasyJob.TabItems
{
public class ActionButton
{
/// <summary>
/// Gets or sets the identifier.
/// </summary>
/// <value>
/// The identifier.
/// </value>
public Guid ID { get; set; }
/// <summary>
/// Gets or sets the button text.
/// </summary>
/// <value>
/// The button text.
/// </value>
public string ButtonText { get; set; }
/// <summary>
/// Gets or sets the button description.
/// </summary>
/// <value>
/// The button description.
/// </value>
public string ButtonDescription { get; set; }
/// <summary>
/// Gets or sets the button script.
/// </summary>
/// <value>
/// The button script.
/// </value>
public string ButtonScript { get; set; }
/// <summary>
/// Gets or sets the type of the button script path.
/// </summary>
/// <value>
/// The type of the button script path.
/// </value>
public string ButtonScriptPathType { get; set; }
/// <summary>
/// Gets or sets the type of the button script.
/// </summary>
/// <value>
/// The type of the button script.
/// </value>
public string ButtonScriptType { get; set; }
/// <summary>
/// Gets or sets the button arguments.
/// </summary>
/// <value>
/// The button arguments.
/// </value>
public List<Answer> ButtonArguments { get; set; }
/// <summary>
/// Gets or sets the context menu.
/// </summary>
/// <value>
/// The context menu.
/// </value>
public ContextMenu contextMenu { get; set; }
}
}
================================================
FILE: EasyJob/Serialization/TabItems/TabData.cs
================================================
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Threading.Tasks;
namespace EasyJob.TabItems
{
public class TabData : INotifyPropertyChanged
{
private string _TabTextBoxText;
/// <summary>
/// Initializes a new instance of the <see cref="TabData"/> class.
/// </summary>
public TabData()
{
}
/// <summary>
/// Initializes a new instance of the <see cref="TabData"/> class.
/// </summary>
/// <param name="tabTextBoxText">The tab text box text.</param>
public TabData(string tabTextBoxText)
{
this._TabTextBoxText = tabTextBoxText;
ID = Guid.NewGuid();
TabHeader = tabTextBoxText;
TabActionButtons = new List<ActionButton>();
}
/// <summary>
/// Gets or sets the identifier.
/// </summary>
/// <value>
/// The identifier.
/// </value>
public Guid ID { get; set; }
/// <summary>
/// Gets or sets the tab header.
/// </summary>
/// <value>
/// The tab header.
/// </value>
public string TabHeader { get; set; }
/// <summary>
/// Gets or sets the console background.
/// </summary>
/// <value>
/// The console background.
/// </value>
public string ConsoleBackground { get; set; }
/// <summary>
/// Gets or sets the console foreground.
/// </summary>
/// <value>
/// The console foreground.
/// </value>
public string ConsoleForeground { get; set; }
/// <summary>
/// Gets or sets the tab action buttons.
/// </summary>
/// <value>
/// The tab action buttons.
/// </value>
public List<ActionButton> TabActionButtons { get; set; }
/// <summary>
/// Gets or sets the tab text box text.
/// </summary>
/// <value>
/// The tab text box text.
/// </value>
public string TabTextBoxText {
get
{
return this._TabTextBoxText;
}
set
{
if (_TabTextBoxText != value)
{
_TabTextBoxText = value;
Task.Run(() => {
OnChange("TabTextBoxText");
});
}
}
}
/// <summary>
/// Occurs when a property value changes.
/// </summary>
public event PropertyChangedEventHandler PropertyChanged;
/// <summary>
/// Called when [change].
/// </summary>
/// <param name="info">The information.</param>
protected void OnChange(string info)
{
if (PropertyChanged != null)
{
PropertyChanged(this, new PropertyChangedEventArgs(info));
}
}
}
}
================================================
FILE: EasyJob/Serialization/TasksList/TaskListTask.cs
================================================
namespace EasyJob.Serialization.TasksList
{
public class TaskListTask
{
public int TaskID { get; set; }
public string TaskFile { get; set; }
}
}
================================================
FILE: EasyJob/Utils/CommonUtils.cs
================================================
using System;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Windows;
namespace EasyJob.Utils
{
public class CommonUtils
{
public static void OpenLinkInBrowser(string url)
{
try
{
Process proc = new Process();
proc.StartInfo.UseShellExecute = true;
proc.StartInfo.FileName = url;
proc.Start();
}
catch (Exception ex) { MessageBox.Show(ex.Message); }
}
public static string ReadAssemblyFile(string name)
{
// Determine path
var assembly = Assembly.GetExecutingAssembly();
string resourcePath = name;
// Format: "{Namespace}.{Folder}.{filename}.{Extension}"
if (!name.StartsWith(nameof(EasyJob)))
{
resourcePath = assembly.GetManifestResourceNames()
.Single(str => str.EndsWith(name));
}
using (Stream stream = assembly.GetManifestResourceStream(resourcePath))
using (StreamReader reader = new StreamReader(stream))
{
return reader.ReadToEnd();
}
}
public static string ApplyConsoleColorTagsToText(string Text)
{
string[][] colorCodes = new string[][] {
new string[] { @"\c01EJ", "/c01EJ", "<span style=\"color: #DFFF00;\">" },
new string[] { @"\c02EJ", "/c02EJ", "<span style=\"color: #FFBF00;\">" },
new string[] { @"\c03EJ", "/c03EJ", "<span style=\"color: #FF7F50;\">" },
new string[] { @"\c04EJ", "/c04EJ", "<span style=\"color: #DE3163;\">" },
new string[] { @"\c05EJ", "/c05EJ", "<span style=\"color: #9FE2BF;\">" },
new string[] { @"\c06EJ", "/c06EJ", "<span style=\"color: #40E0D0;\">" },
new string[] { @"\c07EJ", "/c07EJ", "<span style=\"color: #6495ED;\">" },
new string[] { @"\c08EJ", "/c08EJ", "<span style=\"color: #CCCCFF;\">" },
new string[] { @"\c09EJ", "/c09EJ", "<span style=\"color: #800080;\">" },
new string[] { @"\c10EJ", "/c10EJ", "<span style=\"color: #3D3D6B;\">" },
new string[] { @"\c11EJ", "/c11EJ", "<span style=\"color: #ADD45C;\">" },
new string[] { @"\c12EJ", "/c12EJ", "<span style=\"color: #57C785;\">" },
new string[] { @"\c13EJ", "/c13EJ", "<span style=\"color: #00BAAD;\">" },
new string[] { @"\c14EJ", "/c14EJ", "<span style=\"color: #2A7B9B;\">" }
};
for (int i = 0; i <= colorCodes.GetLength(0) - 1; i++)
{
if (Text.Contains(colorCodes[i][0]) == true && Text.Contains(colorCodes[i][1]) == false)
{
Text = Text.Replace(colorCodes[i][0], colorCodes[i][2]);
Text = Text + "</span>";
}
else if (Text.Contains(colorCodes[i][0]) == false && Text.Contains(colorCodes[i][1]) == true)
{
Text = Text.Replace(colorCodes[i][1], "");
}
else if (Text.Contains(colorCodes[i][0]) == true && Text.Contains(colorCodes[i][1]) == true)
{
Text = Text.Replace(colorCodes[i][0], colorCodes[i][2]);
Text = Text.Replace(colorCodes[i][1], "</span>");
}
}
return Text;
}
public static string ConvertPartToRelative(string Path)
{
Path = Path.Replace(AppDomain.CurrentDomain.BaseDirectory, "");
return Path;
}
public static string ApplicationStartupPath()
{
return AppDomain.CurrentDomain.BaseDirectory;
}
}
}
================================================
FILE: EasyJob/Utils/ConfigUtils.cs
================================================
using EasyJob.Serialization;
using EasyJob.Serialization.AnswerDialog;
using EasyJob.TabItems;
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
namespace EasyJob.Utils
{
public class ConfigUtils
{
public static string ConfigJsonPath = AppDomain.CurrentDomain.BaseDirectory + "config.json";
public static ObservableCollection<TabData> ConvertTabsFromConfigToUI(Config config)
{
ObservableCollection<TabData> tabs = new ObservableCollection<TabData>();
foreach (ConfigTab configTab in config.tabs)
{
List<ActionButton> actionButtons = new List<ActionButton>();
foreach (ConfigButton configButton in configTab.Buttons)
{
List<Answer> configArguments = new List<Answer>();
foreach (ConfigArgument configArgument in configButton.Arguments)
{
configArguments.Add(new Answer { AnswerQuestion = configArgument.ArgumentQuestion, AnswerResult = configArgument.ArgumentAnswer });
}
actionButtons.Add(new ActionButton { ID = configButton.Id, ButtonText = configButton.Text, ButtonDescription = configButton.Description, ButtonScript = configButton.Script, ButtonScriptPathType = configButton.ScriptPathType, ButtonScriptType = configButton.ScriptType, ButtonArguments = configArguments });
}
tabs.Add(new TabData { ID = configTab.ID, TabHeader = configTab.Header, ConsoleBackground = config.console_background, ConsoleForeground = config.console_foreground, TabActionButtons = actionButtons, TabTextBoxText = "" });
}
return tabs;
}
/// <summary>
/// Saves the configs.
/// </summary>
/// <param name="tabs">The tabs.</param>
/// <returns></returns>
public static List<ConfigTab> ConvertTabsFromUIToConfig(IEnumerable<TabData> tabs)
{
List<ConfigTab> configTabs = new List<ConfigTab>();
List<ConfigButton> buttons = null;
List<ConfigArgument> configArguments = null;
foreach (TabData tab in tabs)
{
buttons = new List<ConfigButton>();
foreach (ActionButton button in tab.TabActionButtons)
{
configArguments = new List<ConfigArgument>();
foreach (Answer answer in button.ButtonArguments)
{
configArguments.Add(new ConfigArgument(answer.AnswerQuestion, answer.AnswerResult));
}
buttons.Add(new ConfigButton(button.ID, button.ButtonText, button.ButtonDescription, button.ButtonScript, button.ButtonScriptPathType, button.ButtonScriptType, configArguments));
}
configTabs.Add(new ConfigTab(tab.ID, tab.TabHeader, buttons));
}
return configTabs;
}
public static bool SaveFromConfigToFile(Config config)
{
try
{
string confifJson = JsonConvert.SerializeObject(config);
File.WriteAllText(ConfigJsonPath, confifJson, Encoding.UTF8);
return true;
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
return false;
}
}
}
}
================================================
FILE: EasyJob/Utils/ScrollViewerExtensions.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
namespace EasyJob.Utils
{
public class ScrollViewerExtensions
{
public static readonly DependencyProperty AlwaysScrollToEndProperty = DependencyProperty.RegisterAttached("AlwaysScrollToEnd", typeof(bool), typeof(ScrollViewerExtensions), new PropertyMetadata(false, AlwaysScrollToEndChanged));
private static bool _autoScroll;
private static void AlwaysScrollToEndChanged(object sender, DependencyPropertyChangedEventArgs e)
{
ScrollViewer scroll = sender as ScrollViewer;
if (scroll != null)
{
bool alwaysScrollToEnd = (e.NewValue != null) && (bool)e.NewValue;
if (alwaysScrollToEnd)
{
scroll.ScrollToEnd();
scroll.ScrollChanged += ScrollChanged;
}
else { scroll.ScrollChanged -= ScrollChanged; }
}
else { throw new InvalidOperationException("The attached AlwaysScrollToEnd property can only be applied to ScrollViewer instances."); }
}
public static bool GetAlwaysScrollToEnd(ScrollViewer scroll)
{
if (scroll == null) { throw new ArgumentNullException("scroll"); }
return (bool)scroll.GetValue(AlwaysScrollToEndProperty);
}
public static void SetAlwaysScrollToEnd(ScrollViewer scroll, bool alwaysScrollToEnd)
{
if (scroll == null) { throw new ArgumentNullException("scroll"); }
scroll.SetValue(AlwaysScrollToEndProperty, alwaysScrollToEnd);
}
private static void ScrollChanged(object sender, ScrollChangedEventArgs e)
{
ScrollViewer scroll = sender as ScrollViewer;
if (scroll == null) { throw new InvalidOperationException("The attached AlwaysScrollToEnd property can only be applied to ScrollViewer instances."); }
// User scroll event : set or unset autoscroll mode
if (e.ExtentHeightChange == 0) { _autoScroll = scroll.VerticalOffset == scroll.ScrollableHeight; }
// Content scroll event : autoscroll eventually
if (_autoScroll && e.ExtentHeightChange != 0) { scroll.ScrollToVerticalOffset(scroll.ExtentHeight); }
}
}
}
================================================
FILE: EasyJob/Windows/AboutDialog.xaml
================================================
<Window x:Class="EasyJob.Windows.AboutDialog"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:ui="http://schemas.modernwpf.com/2019"
ui:WindowHelper.UseModernWindowStyle="True"
xmlns:local="clr-namespace:EasyJob.Windows"
mc:Ignorable="d"
WindowStyle="SingleBorderWindow" Icon="pack://application:,,,/Images/icon.ico"
Title="About EasyJob" Height="430" Width="640" ResizeMode="NoResize" WindowStartupLocation="CenterScreen">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="90"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid Grid.Row="0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="90"/>
<ColumnDefinition Width="10"/>
</Grid.ColumnDefinitions>
<TextBlock AutomationProperties.Name="About" Padding="12" Grid.Column="0" Text="About" Style="{StaticResource HeaderTextBlockStyle}" Background="#E2E2E2"/>
<Image Grid.Column="1" Source="pack://application:,,,/Images/github.png" Height="Auto" Width="Auto" MouseLeftButtonDown="GithubImage_MouseLeftButtonDown" Cursor="Hand" Stretch="Fill"/>
<DockPanel Grid.Column="2" Background="#E2E2E2"/>
</Grid>
<Grid Grid.Row="1">
<Grid.RowDefinitions>
<RowDefinition Height="32"/>
<RowDefinition Height="32"/>
<RowDefinition Height="32"/>
<RowDefinition Height="*"/>
<RowDefinition Height="55"/>
</Grid.RowDefinitions>
<Label Grid.Row="0" Name="AboutTitle" VerticalAlignment="Center" Margin="10,0,10,0" Content="EasyJob Executor"/>
<Label Grid.Row="1" Name="AboutInfo" VerticalAlignment="Center" Margin="10,0,10,0" Content="Author" />
<Label Grid.Row="2" VerticalAlignment="Center" Margin="10,0,10,0" Content="Licence: GNU AGPLv3" />
<RichTextBox Grid.Row="3" Margin="10,10,10,0" Name="RichTextBox1" HorizontalAlignment="Left" Background="Black" Foreground="White"
BorderThickness="0" IsDocumentEnabled="True" IsReadOnly="True" VerticalScrollBarVisibility="Visible" FontFamily="Consolas">
</RichTextBox>
<Button Grid.Row="4" Content="Get some inspiration" Click="GetInspirationButton_Click" Margin="5,0,10,0" Padding="5" HorizontalAlignment="Right"/>
<Button Grid.Row="4" Content="Check new releases" Click="CheckNewReleasesButton_Click" Margin="5,0,155,0" Padding="5" HorizontalAlignment="Right"/>
</Grid>
</Grid>
</Window>
================================================
FILE: EasyJob/Windows/AboutDialog.xaml.cs
================================================
using EasyJob.Utils;
using HtmlAgilityPack;
using System;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Windows;
namespace EasyJob.Windows
{
/// <summary>
/// Interaction logic for AboutDialog.xaml
/// </summary>
public partial class AboutDialog : Window
{
/// <summary>
/// Initializes a new instance of the <see cref="AboutDialog"/> class.
/// </summary>
public AboutDialog()
{
InitializeComponent();
LoadDataInfoIntoTheForm();
}
public void LoadDataInfoIntoTheForm()
{
AboutTitle.Content = "EasyJob Executor " + Assembly.GetExecutingAssembly().GetName().Version.ToString();
AboutInfo.Content = "Author: Akshin Mustafayev. Contrubutions made to the project by the Github community";
string readme = CommonUtils.ReadAssemblyFile("LICENSE.txt");
RichTextBox1.Document.Blocks.Clear();
var plainText = ConvertToPlainText(readme);
RichTextBox1.AppendText(plainText);
}
private static void ConvertContentTo(HtmlNode node, TextWriter outText)
{
foreach (HtmlNode subnode in node.ChildNodes)
{
ConvertTo(subnode, outText);
}
}
/// <summary>
/// Converts to plain text.
/// </summary>
/// <param name="html">The HTML.</param>
/// <returns></returns>
public static string ConvertToPlainText(string html)
{
HtmlDocument doc = new HtmlDocument();
doc.LoadHtml(html);
StringWriter sw = new StringWriter();
ConvertTo(doc.DocumentNode, sw);
sw.Flush();
return sw.ToString();
}
private static void ConvertTo(HtmlNode node, TextWriter outText)
{
string html;
switch (node.NodeType)
{
case HtmlNodeType.Comment:
// don't output comments
break;
case HtmlNodeType.Document:
ConvertContentTo(node, outText);
break;
case HtmlNodeType.Text:
// script and style must not be output
string parentName = node.ParentNode.Name;
if ((parentName == "script") || (parentName == "style"))
break;
// get text
html = ((HtmlTextNode)node).Text;
// is it in fact a special closing node output as text?
if (HtmlNode.IsOverlappedClosingElement(html))
break;
// check the text is meaningful and not a bunch of whitespaces
if (html.Trim().Length > 0)
{
outText.Write(HtmlEntity.DeEntitize(html));
}
break;
case HtmlNodeType.Element:
switch (node.Name)
{
case "p":
// treat paragraphs as crlf
outText.Write("\r\n");
break;
case "br":
outText.Write("\r\n");
break;
}
if (node.HasChildNodes)
{
ConvertContentTo(node, outText);
}
break;
}
}
private void GetInspirationButton_Click(object sender, RoutedEventArgs e)
{
CommonUtils.OpenLinkInBrowser("https://www.youtube.com/watch?v=l0U7SxXHkPY");
}
private void CheckNewReleasesButton_Click(object sender, RoutedEventArgs e)
{
CommonUtils.OpenLinkInBrowser("https://github.com/akshinmustafayev/EasyJob/releases");
}
private void GithubImage_MouseLeftButtonDown(object sender, System.Windows.Input.MouseButtonEventArgs e)
{
CommonUtils.OpenLinkInBrowser("https://github.com/akshinmustafayev/EasyJob");
}
}
}
================================================
FILE: EasyJob/Windows/AddActionButtonDialog.xaml
================================================
<Window x:Class="EasyJob.Windows.AddActionButtonDialog"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:ui="http://schemas.modernwpf.com/2019"
ui:WindowHelper.UseModernWindowStyle="True"
xmlns:local="clr-namespace:EasyJob.Windows"
mc:Ignorable="d" Icon="pack://application:,,,/Images/icon.ico"
Title="Add button" Height="600" Width="400" WindowStartupLocation="CenterScreen">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="22"/>
<RowDefinition Height="34"/>
<RowDefinition Height="26"/>
<RowDefinition Height="64"/>
<RowDefinition Height="26"/>
<RowDefinition Height="64"/>
<RowDefinition Height="26"/>
<RowDefinition Height="38"/>
<RowDefinition Height="26"/>
<RowDefinition Height="38"/>
<RowDefinition Height="26"/>
<RowDefinition Height="*"/>
<RowDefinition Height="44"/>
</Grid.RowDefinitions>
<DockPanel Grid.Row="0">
<TextBlock Margin="10,0,0,0" FontSize="14" VerticalAlignment="Center" Text="Text" HorizontalAlignment="Left"/>
<Button AutomationProperties.Name="Help for script button text" Name="HelpAddActionButtonText" Width="14" Height="14" Margin="8,0,0,0" Click="HelpButton_Click">
<Image Source="pack://application:,,,/Images/help.png" Margin="-9,-5,-5,-6"/>
</Button>
</DockPanel>
<TextBox AutomationProperties.Name="Text displayed on script button" x:Name="ButtonText" Grid.Row="1" Margin="10,2,10,0" FontSize="14" VerticalAlignment="Center"/>
<DockPanel Grid.Row="2">
<TextBlock Margin="10,0,0,0" FontSize="14" VerticalAlignment="Center" Text="Description" HorizontalAlignment="Left"/>
<Button AutomationProperties.Name="Help on description text" Name="HelpAddActionButtonDescription" Width="14" Height="14" Margin="8,0,0,0" Click="HelpButton_Click">
<Image Source="pack://application:,,,/Images/help.png" Margin="-9,-5,-5,-6"/>
</Button>
</DockPanel>
<TextBox AutomationProperties.Name="Script description" x:Name="ButtonDescription" Grid.Row="3" Margin="10,2,10,0" FontSize="14" TextWrapping="Wrap" VerticalScrollBarVisibility="Auto"/>
<DockPanel Grid.Row="4">
<TextBlock Grid.Row="4" Margin="10,0,0,0" FontSize="14" VerticalAlignment="Center" Text="Script" HorizontalAlignment="Left"/>
<Button AutomationProperties.Name="Select file dialog on script path" Width="14" Height="14" Margin="8,0,0,0" Click="SelectFileButton_Click">
<Image Source="pack://application:,,,/Images/find.png" Margin="-9,-5,-5,-6"/>
</Button>
<Button AutomationProperties.Name="Help on script path" Name="HelpAddActionButtonScript" Width="14" Height="14" Margin="8,0,0,0" Click="HelpButton_Click">
<Image Source="pack://application:,,,/Images/help.png" Margin="-9,-5,-5,-6"/>
</Button>
</DockPanel>
<TextBox AutomationProperties.Name="Script path" x:Name="ButtonScript" Grid.Row="5" Margin="10,2,10,0" FontSize="14" TextWrapping="Wrap" VerticalScrollBarVisibility="Auto"/>
<DockPanel Grid.Row="6">
<TextBlock AutomationProperties.Name="Path type" Margin="10,0,0,0" FontSize="14" VerticalAlignment="Center" Text="Script path type" HorizontalAlignment="Left"/>
<Button AutomationProperties.Name="Help for script path type" Name="HelpAddActionButtonScriptPathType" Width="14" Height="14" Margin="8,0,0,0" Click="HelpButton_Click">
<Image Source="pack://application:,,,/Images/help.png" Margin="-9,-5,-5,-6"/>
</Button>
</DockPanel>
<ComboBox AutomationProperties.Name="Path type" x:Name="ButtonScriptPathType" Grid.Row="7" Margin="10,2,10,0" FontSize="14">
<ComboBoxItem IsSelected="True">Relative</ComboBoxItem>
<ComboBoxItem >Absolute</ComboBoxItem>
</ComboBox>
<DockPanel Grid.Row="8">
<TextBlock Margin="10,0,0,0" FontSize="14" VerticalAlignment="Center" Text="Script type" HorizontalAlignment="Left"/>
<Button AutomationProperties.Name="Help for script type" Name="HelpAddActionButtonScriptType" Width="14" Height="14" Margin="8,0,0,0" Click="HelpButton_Click">
<Image Source="pack://application:,,,/Images/help.png" Margin="-9,-5,-5,-6"/>
</Button>
</DockPanel>
<ComboBox AutomationProperties.Name="Script type" x:Name="ButtonScriptType" Grid.Row="9" Margin="10,2,10,0" FontSize="14">
<ComboBoxItem IsSelected="True">PowerShell</ComboBoxItem>
<ComboBoxItem >Batch</ComboBoxItem>
</ComboBox>
<DockPanel Grid.Row="10">
<TextBlock Margin="10,0,0,0" FontSize="14" VerticalAlignment="Center" Text="Arguments" HorizontalAlignment="Left"/>
<Button AutomationProperties.Name="Help for script arguements" Name="HelpAddActionButtonArguments" Width="14" Height="14" Margin="8,0,0,0" Click="HelpButton_Click">
<Image Source="pack://application:,,,/Images/help.png" Margin="-9,-5,-5,-6"/>
</Button>
</DockPanel>
<Grid Grid.Row="11">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="44"/>
</Grid.RowDefinitions>
<Border Grid.Row="0" Margin="10,0,10,0" BorderBrush="#333333" BorderThickness="1" CornerRadius="2">
<ListBox AutomationProperties.Name="Script arguements" x:Name="ButtonScriptArguments">
<ListBox.ItemTemplate>
<DataTemplate>
<StackPanel Margin="-5" Orientation="Horizontal">
<Button AutomationProperties.Name="Delete" x:Name="DeleteArgumentButton" Margin="0" Height="25" Width="25" Click="DeleteArgumentButton_Click">
<StackPanel VerticalAlignment="Center" HorizontalAlignment="Center" Orientation="Horizontal" Background="Transparent">
<Image Source="pack://application:,,,/Images/close.png" Margin="-6,-2,-6,-2" HorizontalAlignment="Center" VerticalAlignment="Center"/>
</StackPanel>
</Button>
<TextBlock Margin="10 0 2 0" Text="{Binding Path=AnswerQuestion}" HorizontalAlignment="Left" VerticalAlignment="Center"/>
</StackPanel>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
</Border>
<Button AutomationProperties.Name="Add script arguement" Grid.Row="1" Content="Add" Click="ADDButton_Click" Margin="10,0,0,0" Padding="5"/>
<TextBox AutomationProperties.Name="Script arguement" x:Name="ButtonScriptArgumentText" Grid.Row="2" Margin="55,6,10,6"/>
</Grid>
<Button Grid.Row="13" Content="OK" Click="OKButton_Click" Margin="5" Padding="5" Style="{StaticResource AccentButtonStyle}" HorizontalAlignment="Right"/>
<Button AutomationProperties.Name="Cancel" Grid.Row="13" Content="Cancel" Click="CANCELButton_Click" Margin="5,5,40,5" Padding="5" HorizontalAlignment="Right"/>
</Grid>
</Window>
================================================
FILE: EasyJob/Windows/AddActionButtonDialog.xaml.cs
================================================
using EasyJob.Serialization;
using EasyJob.Serialization.AnswerDialog;
using EasyJob.Utils;
using Microsoft.Win32;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Shapes;
namespace EasyJob.Windows
{
/// <summary>
/// Interaction logic for AddActionButtonDialog.xaml
/// </summary>
public partial class AddActionButtonDialog : Window
{
public ConfigButton configButton;
public AddActionButtonDialog()
{
InitializeComponent();
configButton = null;
}
private void OKButton_Click(object sender, RoutedEventArgs e)
{
List<ConfigArgument> configArguments = new List<ConfigArgument>();
foreach (Answer answer in ButtonScriptArguments.Items) { configArguments.Add(new ConfigArgument(answer.AnswerQuestion, answer.AnswerResult)); };
string buttonScriptPathTypeValue = ConvertScriptPathTypeComboBoxToString(ButtonScriptPathType);
string buttonScriptTypeValue = ConvertScriptTypeComboBoxToString(ButtonScriptType);
ConfigButton newConfigButton = new ConfigButton(Guid.NewGuid() ,ButtonText.Text, ButtonDescription.Text, ButtonScript.Text, buttonScriptPathTypeValue, buttonScriptTypeValue, configArguments);
configButton = newConfigButton;
DialogResult = true;
}
private string ConvertScriptTypeComboBoxToString(ComboBox cb)
{
if(cb.SelectedIndex == 0)
{
return "powershell";
}
else
{
return "bat";
}
}
private string ConvertScriptPathTypeComboBoxToString(ComboBox cb)
{
if (cb.SelectedIndex == 0)
{
return "relative";
}
else
{
return "absolute";
}
}
private void CANCELButton_Click(object sender, RoutedEventArgs e)
{
DialogResult = false;
}
private void ADDButton_Click(object sender, RoutedEventArgs e)
{
try
{
ButtonScriptArguments.Items.Add(new Answer { AnswerQuestion = ButtonScriptArgumentText.Text, AnswerResult = "" });
ButtonScriptArgumentText.Text = "";
}
catch { }
}
private void DeleteArgumentButton_Click(object sender, RoutedEventArgs e)
{
try
{
Button btn = sender as Button;
ButtonScriptArguments.Items.Remove((Answer)btn.DataContext);
}
catch { }
}
private void HelpButton_Click(object sender, RoutedEventArgs e)
{
Button button = sender as Button;
HelpDialog hd = new HelpDialog(button.Name);
hd.ShowDialog();
}
private void SelectFileButton_Click(object sender, RoutedEventArgs e)
{
OpenFileDialog ofd = new OpenFileDialog();
ofd.Multiselect = false;
ofd.InitialDirectory = CommonUtils.ApplicationStartupPath();
if (ofd.ShowDialog() == true)
{
if(ButtonScriptPathType.SelectedIndex == 0)
{
ButtonScript.Text = CommonUtils.ConvertPartToRelative(ofd.FileName);
}
else
{
ButtonScript.Text = ofd.FileName;
}
}
}
}
}
================================================
FILE: EasyJob/Windows/AnswerDialog.xaml
================================================
<Window x:Class="EasyJob.Windows.AnswerDialog"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:EasyJob.Windows"
mc:Ignorable="d" Icon="pack://application:,,,/Images/icon.ico"
Title="Select" ResizeMode="CanMinimize" SizeToContent="WidthAndHeight" WindowStartupLocation="CenterScreen" MinWidth="400">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="*" MaxHeight="450"/>
<RowDefinition Height="64"/>
</Grid.RowDefinitions>
<ScrollViewer Focusable="False" IsTabStop="False" Grid.Row="0" Margin="0,8,0,8" VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Disabled">
<ItemsControl AutomationProperties.Name="Answers" x:Name="AnswerDialogItems" ItemsSource="{Binding Answers}" Margin="8">
<ItemsControl.ItemsPanel>
<ItemsPanelTemplate>
<WrapPanel Orientation="Vertical" ItemWidth="500" Margin="10,0,10,0"/>
</ItemsPanelTemplate>
</ItemsControl.ItemsPanel>
<ItemsControl.ItemTemplate>
<DataTemplate>
<Grid Margin="8">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<TextBlock AutomationProperties.Name="{Binding AnswerQuestion}" HorizontalAlignment="Left" Grid.Row="0" Text="{Binding AnswerQuestion}"/>
<TextBox Grid.Row="1" Margin="5" Text="{Binding AnswerResult}"/>
</Grid>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
</ScrollViewer>
<Button AutomationProperties.Name="Cancel" Grid.Row="1" Content="Cancel" Click="CANCELButton_Click" Margin="5,5,40,5" Padding="5" HorizontalAlignment="Right"/>
<Button AutomationProperties.Name="Okay" Grid.Row="1" Content="OK" Click="OKButton_Click" Margin="5" Padding="5" Style="{StaticResource AccentButtonStyle}" HorizontalAlignment="Right"/>
</Grid>
</Window>
================================================
FILE: EasyJob/Windows/AnswerDialog.xaml.cs
================================================
using EasyJob.Serialization.AnswerDialog;
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Shapes;
namespace EasyJob.Windows
{
/// <summary>
/// Interaction logic for AnswerDialog.xaml
/// </summary>
public partial class AnswerDialog : Window
{
public AnswerData answerData = null;
public AnswerDialog(AnswerData _answerData)
{
InitializeComponent();
answerData = _answerData;
if (_answerData != null)
{
foreach (Answer answer in _answerData.Answers)
{
answer.AnswerResult = "";
}
AnswerDialogItems.ItemsSource = _answerData.Answers;
}
}
private void OKButton_Click(object sender, RoutedEventArgs e)
{
bool AllowConfirm = true;
answerData.Answers = (List<Answer>)AnswerDialogItems.ItemsSource;
foreach (Answer answer in answerData.Answers)
{
if(answer.AnswerResult == "" || answer.AnswerResult == null)
{
AllowConfirm = false;
}
}
if(AllowConfirm == false)
{
MessageBox.Show("Please provide value to all textboxes!", "Fill all data", MessageBoxButton.OK, MessageBoxImage.Warning);
return;
}
DialogResult = true;
}
private void CANCELButton_Click(object sender, RoutedEventArgs e)
{
DialogResult = false;
}
}
}
================================================
FILE: EasyJob/Windows/ColorTagsDialog.xaml
================================================
<Window x:Class="EasyJob.Windows.ColorTagsDialog"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:ui="http://schemas.modernwpf.com/2019"
ui:WindowHelper.UseModernWindowStyle="True"
xmlns:local="clr-namespace:EasyJob.Windows"
mc:Ignorable="d"
WindowStyle="SingleBorderWindow" Icon="pack://application:,,,/Images/icon.ico"
Title="Color tags" Height="430" Width="640" WindowStartupLocation="CenterScreen">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="90"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<TextBlock AutomationProperties.Name="Color tags" Grid.Row="0" Padding="12" Grid.Column="0" Text="Color tags" Style="{StaticResource HeaderTextBlockStyle}" Background="#E2E2E2"/>
<ui:ScrollViewerEx Focusable="False" IsTabStop="False" Grid.Row="1" VerticalScrollBarVisibility="Auto">
<Grid Margin="15,0,15,0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="116"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="56"/>
<RowDefinition Height="56"/>
<RowDefinition Height="56"/>
<RowDefinition Height="56"/>
<RowDefinition Height="56"/>
<RowDefinition Height="56"/>
<RowDefinition Height="56"/>
<RowDefinition Height="56"/>
<RowDefinition Height="56"/>
<RowDefinition Height="56"/>
<RowDefinition Height="56"/>
<RowDefinition Height="56"/>
<RowDefinition Height="56"/>
<RowDefinition Height="56"/>
</Grid.RowDefinitions>
<Border Grid.Column="0" Grid.Row="0" Margin="10,12,10,12" CornerRadius="6">
<Border.Background>
<ImageBrush Stretch="Fill" ImageSource="pack://application:,,,/Images/ColorTags/tag01.png"/>
</Border.Background>
<TextBlock Text="#DFFF00" VerticalAlignment="Center" Margin="5,0,5,0" TextAlignment="Center" FontSize="16"/>
</Border>
<TextBox AutomationProperties.Name="Color tag \c01EJ" Grid.Column="1" Grid.Row="0" Text="\c01EJSome text/c01EJ" VerticalAlignment="Center" Margin="10,0,10,0" TextAlignment="Center" IsReadOnly="True"/>
<Border Grid.Column="0" Grid.Row="1" Margin="10,12,10,12" CornerRadius="6">
<Border.Background>
<ImageBrush Stretch="Fill" ImageSource="pack://application:,,,/Images/ColorTags/tag02.png"/>
</Border.Background>
<TextBlock Text="#FFBF00" VerticalAlignment="Center" Margin="5,0,5,0" TextAlignment="Center" FontSize="16"/>
</Border>
<TextBox AutomationProperties.Name="Color tag \c02EJ" Grid.Column="1" Grid.Row="1" Text="\c02EJSome text/c02EJ" VerticalAlignment="Center" Margin="10,0,10,0" TextAlignment="Center" IsReadOnly="True"/>
<Border Grid.Column="0" Grid.Row="2" Margin="10,12,10,12" CornerRadius="6">
<Border.Background>
<ImageBrush Stretch="Fill" ImageSource="pack://application:,,,/Images/ColorTags/tag03.png"/>
</Border.Background>
<TextBlock Text="#FFBF00" VerticalAlignment="Center" Margin="5,0,5,0" TextAlignment="Center" FontSize="16"/>
</Border>
<TextBox AutomationProperties.Name="Color tag \c03EJ" Grid.Column="1" Grid.Row="2" Text="\c03EJSome text/c03EJ" VerticalAlignment="Center" Margin="10,0,10,0" TextAlignment="Center" IsReadOnly="True"/>
<Border Grid.Column="0" Grid.Row="3" Margin="10,12,10,12" CornerRadius="6">
<Border.Background>
<ImageBrush Stretch="Fill" ImageSource="pack://application:,,,/Images/ColorTags/tag04.png"/>
</Border.Background>
<TextBlock Text="#DE3163" VerticalAlignment="Center" Margin="5,0,5,0" TextAlignment="Center" FontSize="16"/>
</Border>
<TextBox AutomationProperties.Name="Color tag \c04EJ" Grid.Column="1" Grid.Row="3" Text="\c04EJSome text/c04EJ" VerticalAlignment="Center" Margin="10,0,10,0" TextAlignment="Center" IsReadOnly="True"/>
<Border Grid.Column="0" Grid.Row="4" Margin="10,12,10,12" CornerRadius="6">
<Border.Background>
<ImageBrush Stretch="Fill" ImageSource="pack://application:,,,/Images/ColorTags/tag05.png"/>
</Border.Background>
<TextBlock Text="#9FE2BF" VerticalAlignment="Center" Margin="5,0,5,0" TextAlignment="Center" FontSize="16"/>
</Border>
<TextBox AutomationProperties.Name="Color tag \c05EJ" Grid.Column="1" Grid.Row="4" Text="\c05EJSome text/c05EJ" VerticalAlignment="Center" Margin="10,0,10,0" TextAlignment="Center" IsReadOnly="True"/>
<Border Grid.Column="0" Grid.Row="5" Margin="10,12,10,12" CornerRadius="6">
<Border.Background>
<ImageBrush Stretch="Fill" ImageSource="pack://application:,,,/Images/ColorTags/tag06.png"/>
</Border.Background>
<TextBlock Text="#40E0D0" VerticalAlignment="Center" Margin="5,0,5,0" TextAlignment="Center" FontSize="16"/>
</Border>
<TextBox AutomationProperties.Name="Color tag \c06EJ" Grid.Column="1" Grid.Row="5" Text="\c06EJSome text/c06EJ" VerticalAlignment="Center" Margin="10,0,10,0" TextAlignment="Center" IsReadOnly="True"/>
<Border Grid.Column="0" Grid.Row="6" Margin="10,12,10,12" CornerRadius="6">
<Border.Background>
<ImageBrush Stretch="Fill" ImageSource="pack://application:,,,/Images/ColorTags/tag07.png"/>
</Border.Background>
<TextBlock Text="#6495ED" VerticalAlignment="Center" Margin="5,0,5,0" TextAlignment="Center" FontSize="16"/>
</Border>
<TextBox AutomationProperties.Name="Color tag \c07EJ" Grid.Column="1" Grid.Row="6" Text="\c07EJSome text/c07EJ" VerticalAlignment="Center" Margin="10,0,10,0" TextAlignment="Center" IsReadOnly="True"/>
<Border Grid.Column="0" Grid.Row="7" Margin="10,12,10,12" CornerRadius="6">
<Border.Background>
<ImageBrush Stretch="Fill" ImageSource="pack://application:,,,/Images/ColorTags/tag08.png"/>
</Border.Background>
<TextBlock Text="#CCCCFF" VerticalAlignment="Center" Margin="5,0,5,0" TextAlignment="Center" FontSize="16"/>
</Border>
<TextBox AutomationProperties.Name="Color tag \c08EJ" Grid.Column="1" Grid.Row="7" Text="\c08EJSome text/c08EJ" VerticalAlignment="Center" Margin="10,0,10,0" TextAlignment="Center" IsReadOnly="True"/>
<Border Grid.Column="0" Grid.Row="8" Margin="10,12,10,12" CornerRadius="6">
<Border.Background>
<ImageBrush Stretch="Fill" ImageSource="pack://application:,,,/Images/ColorTags/tag09.png"/>
</Border.Background>
<TextBlock Text="#800080" VerticalAlignment="Center" Margin="5,0,5,0" TextAlignment="Center" FontSize="16"/>
</Border>
<TextBox AutomationProperties.Name="Color tag \c09EJ" Grid.Column="1" Grid.Row="8" Text="\c09EJSome text/c09EJ" VerticalAlignment="Center" Margin="10,0,10,0" TextAlignment="Center" IsReadOnly="True"/>
<Border Grid.Column="0" Grid.Row="9" Margin="10,12,10,12" CornerRadius="6">
<Border.Background>
<ImageBrush Stretch="Fill" ImageSource="pack://application:,,,/Images/ColorTags/tag10.png"/>
</Border.Background>
<TextBlock Text="#3D3D6B" VerticalAlignment="Center" Margin="5,0,5,0" TextAlignment="Center" FontSize="16"/>
</Border>
<TextBox AutomationProperties.Name="Color tag \c10EJ" Grid.Column="1" Grid.Row="9" Text="\c10EJSome text/c10EJ" VerticalAlignment="Center" Margin="10,0,10,0" TextAlignment="Center" IsReadOnly="True"/>
<Border Grid.Column="0" Grid.Row="10" Margin="10,12,10,12" CornerRadius="6">
<Border.Background>
<ImageBrush Stretch="Fill" ImageSource="pack://application:,,,/Images/ColorTags/tag11.png"/>
</Border.Background>
<TextBlock Text="#ADD45C" VerticalAlignment="Center" Margin="5,0,5,0" TextAlignment="Center" FontSize="16"/>
</Border>
<TextBox AutomationProperties.Name="Color tag \c11EJ" Grid.Column="1" Grid.Row="10" Text="\c11EJSome text/c11EJ" VerticalAlignment="Center" Margin="10,0,10,0" TextAlignment="Center" IsReadOnly="True"/>
<Border Grid.Column="0" Grid.Row="11" Margin="10,12,10,12" CornerRadius="6">
<Border.Background>
<ImageBrush Stretch="Fill" ImageSource="pack://application:,,,/Images/ColorTags/tag12.png"/>
</Border.Background>
<TextBlock Text="#57C785" VerticalAlignment="Center" Margin="5,0,5,0" TextAlignment="Center" FontSize="16"/>
</Border>
<TextBox AutomationProperties.Name="Color tag \c12EJ" Grid.Column="1" Grid.Row="11" Text="\c12EJSome text/c12EJ" VerticalAlignment="Center" Margin="10,0,10,0" TextAlignment="Center" IsReadOnly="True"/>
<Border Grid.Column="0" Grid.Row="12" Margin="10,12,10,12" CornerRadius="6">
<Border.Background>
<ImageBrush Stretch="Fill" ImageSource="pack://application:,,,/Images/ColorTags/tag13.png"/>
</Border.Background>
<TextBlock Text="#00BAAD" VerticalAlignment="Center" Margin="5,0,5,0" TextAlignment="Center" FontSize="16"/>
</Border>
<TextBox AutomationProperties.Name="Color tag \c13EJ" Grid.Column="1" Grid.Row="12" Text="\c13EJSome text/c13EJ" VerticalAlignment="Center" Margin="10,0,10,0" TextAlignment="Center" IsReadOnly="True"/>
<Border Grid.Column="0" Grid.Row="13" Margin="10,12,10,12" CornerRadius="6">
<Border.Background>
<ImageBrush Stretch="Fill" ImageSource="pack://application:,,,/Images/ColorTags/tag14.png"/>
</Border.Background>
<TextBlock Text="#2A7B9B" VerticalAlignment="Center" Margin="5,0,5,0" TextAlignment="Center" FontSize="16"/>
</Border>
<TextBox AutomationProperties.Name="Color tag \c14EJ" Grid.Column="1" Grid.Row="13" Text="\c14EJSome text/c14EJ" VerticalAlignment="Center" Margin="10,0,10,0" TextAlignment="Center" IsReadOnly="True"/>
</Grid>
</ui:ScrollViewerEx>
</Grid>
</Window>
================================================
FILE: EasyJob/Windows/ColorTagsDialog.xaml.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Shapes;
namespace EasyJob.Windows
{
/// <summary>
/// Interaction logic for ColorTagsDialog.xaml
/// </summary>
public partial class ColorTagsDialog : Window
{
public ColorTagsDialog()
{
InitializeComponent();
}
}
}
================================================
FILE: EasyJob/Windows/ConfigurationDialog.xaml
================================================
<Window x:Class="EasyJob.Windows.ConfigurationDialog"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:ui="http://schemas.modernwpf.com/2019"
ui:WindowHelper.UseModernWindowStyle="True"
xmlns:local="clr-namespace:EasyJob.Windows"
mc:Ignorable="d" Icon="pack://application:,,,/Images/icon.ico"
Title="Configuration" Height="450" Width="700" WindowStartupLocation="CenterScreen">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="90"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<TextBlock Text="Configuration" Grid.Row="0" Background="#E2E2E2" Padding="12" Style="{StaticResource HeaderTextBlockStyle}" />
<ui:ScrollViewerEx Focusable="False" IsTabStop="False" Grid.Row="1" VerticalScrollBarVisibility="Auto">
<Grid Margin="15,0,15,0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="280"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="64"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="64"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="58"/>
<RowDefinition Height="58"/>
<RowDefinition Height="58"/>
<RowDefinition Height="58"/>
<RowDefinition Height="58"/>
<RowDefinition Height="58"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="48"/>
<RowDefinition Height="68"/>
</Grid.RowDefinitions>
<!-- Common parameters part -->
<TextBlock Grid.Row="0" Text="Common parameters" FontSize="22" FontWeight="DemiBold" Margin="10,4,10,10" VerticalAlignment="Bottom"/>
<Border Grid.Row="1" Grid.Column="0" BorderBrush="#E2E2E2" BorderThickness="0,0,1,0">
<DockPanel>
<TextBlock Text="Default PowerShell path" FontSize="16" Margin="10,0,10,0" VerticalAlignment="Center"/>
<Button AutomationProperties.Name="Default PowerShell path Help" Name="HelpConfigurationDefaultPowershellPath" Width="14" Height="14" Margin="8,0,0,0" Click="HelpButton_Click">
<Image Source="pack://application:,,,/Images/help.png" Margin="-9,-5,-5,-6"/>
</Button>
</DockPanel>
</Border>
<TextBox AutomationProperties.Name="Path to PowerShell executable" Name="DefaultPowerShellPath" Grid.Row="1" Grid.Column="1" FontSize="16" Margin="10,0,10,0" VerticalAlignment="Center"/>
<Border Grid.Row="2" Grid.Column="0" BorderBrush="#E2E2E2" BorderThickness="0,0,1,0">
<DockPanel>
<TextBlock Text="Default CMD path" FontSize="16" Margin="10,0,10,0" VerticalAlignment="Center"/>
<Button AutomationProperties.Name="Help for default cmd.exe path" Name="HelpConfigurationDefaultCMDPath" Width="14" Height="14" Margin="8,0,0,0" Click="HelpButton_Click">
<Image Source="pack://application:,,,/Images/help.png" Margin="-9,-5,-5,-6"/>
</Button>
</DockPanel>
</Border>
<TextBox AutomationProperties.Name="Path to cmd.exe executable" Name="DefaultCMDPath" Grid.Row="2" Grid.Column="1" FontSize="16" Margin="10,0,10,0" VerticalAlignment="Center"/>
<Border Grid.Row="3" Grid.Column="0" BorderBrush="#E2E2E2" BorderThickness="0,0,1,0">
<DockPanel>
<TextBlock Text="PowerShell arguments" FontSize="16" Margin="10,0,10,0" VerticalAlignment="Center"/>
<Button AutomationProperties.Name="Help for Arguements to pass to PowerShell Executable" Name="HelpConfigurationPowerShellArguments" Width="14" Height="14" Margin="8,0,0,0" Click="HelpButton_Click">
<Image Source="pack://application:,,,/Images/help.png" Margin="-9,-5,-5,-6"/>
</Button>
</DockPanel>
</Border>
<TextBox AutomationProperties.Name="Arguements to pass to PowerShell" Name="PowerShellArguments" Grid.Row="3" Grid.Column="1" FontSize="16" Margin="10,0,10,0" VerticalAlignment="Center"/>
<Border Grid.Row="4" Grid.Column="0" BorderBrush="#E2E2E2" BorderThickness="0,0,1,0">
<DockPanel>
<TextBlock Text="Console background" FontSize="16" Margin="10,4,10,4" VerticalAlignment="Center"/>
<Button AutomationProperties.Name="Help for Conso
gitextract_cvrmxber/
├── EasyJob/
│ ├── App.xaml
│ ├── App.xaml.cs
│ ├── AssemblyInfo.cs
│ ├── Documentation/
│ │ └── HelpDocumentation.xml
│ ├── EasyJob.csproj
│ ├── EasyJob.csproj.user
│ ├── EasyJobPS/
│ │ ├── EasyJobPS.psd1
│ │ └── EasyJobPS.psm1
│ ├── LICENSE.txt
│ ├── MainWindow.xaml
│ ├── MainWindow.xaml.cs
│ ├── Serialization/
│ │ ├── AnswerDialog/
│ │ │ ├── Answer.cs
│ │ │ └── AnswerData.cs
│ │ ├── Config/
│ │ │ ├── Config.cs
│ │ │ ├── ConfigArgument.cs
│ │ │ ├── ConfigButton.cs
│ │ │ ├── ConfigRestrictions.cs
│ │ │ └── ConfigTab.cs
│ │ ├── TabItems/
│ │ │ ├── ActionButton.cs
│ │ │ └── TabData.cs
│ │ └── TasksList/
│ │ └── TaskListTask.cs
│ ├── Utils/
│ │ ├── CommonUtils.cs
│ │ ├── ConfigUtils.cs
│ │ └── ScrollViewerExtensions.cs
│ ├── Windows/
│ │ ├── AboutDialog.xaml
│ │ ├── AboutDialog.xaml.cs
│ │ ├── AddActionButtonDialog.xaml
│ │ ├── AddActionButtonDialog.xaml.cs
│ │ ├── AnswerDialog.xaml
│ │ ├── AnswerDialog.xaml.cs
│ │ ├── ColorTagsDialog.xaml
│ │ ├── ColorTagsDialog.xaml.cs
│ │ ├── ConfigurationDialog.xaml
│ │ ├── ConfigurationDialog.xaml.cs
│ │ ├── EditActionButtonDialog.xaml
│ │ ├── EditActionButtonDialog.xaml.cs
│ │ ├── HelpDialog.xaml
│ │ ├── HelpDialog.xaml.cs
│ │ ├── NewTabDialog.xaml
│ │ ├── NewTabDialog.xaml.cs
│ │ ├── RenameTabDialog.xaml
│ │ ├── RenameTabDialog.xaml.cs
│ │ ├── ReorderActionButtonsDialog.xaml
│ │ ├── ReorderActionButtonsDialog.xaml.cs
│ │ ├── ReorderTabsDialog.xaml
│ │ ├── ReorderTabsDialog.xaml.cs
│ │ ├── TroubleshootingWindow.xaml
│ │ └── TroubleshootingWindow.xaml.cs
│ └── config.json
├── EasyJob.sln
├── EasyJobPSTools/
│ ├── EasyJobPSTools.csproj
│ ├── EasyJobPSTools.psd1
│ ├── EasyJobPSTools.psm1
│ ├── EasyJobPSTools.sln
│ ├── Program.cs
│ ├── Properties/
│ │ ├── AssemblyInfo.cs
│ │ ├── Resources.Designer.cs
│ │ ├── Resources.resx
│ │ ├── Settings.Designer.cs
│ │ └── Settings.settings
│ ├── Utils/
│ │ └── CommonUtils.cs
│ ├── Windows/
│ │ ├── ShowEJInputBox.xaml
│ │ └── ShowEJInputBox.xaml.cs
│ └── app.config
├── LICENSE.txt
├── README.md
└── WpfRichText/
├── AttachedProperties/
│ └── RichTextboxAssistant.cs
├── Commands/
│ ├── CommandReference.cs
│ └── DelegateCommand.cs
├── Controls/
│ ├── RichTextEditor.xaml
│ └── RichTextEditor.xaml.cs
├── WpfRichText.csproj
├── WpfRichText.sln
└── XamlToHtmlParser/
├── HtmlCssParser.cs
├── HtmlFromXamlConverter.cs
├── HtmlLexicalAnalyzer.cs
├── HtmlParser.cs
├── HtmlSchema.cs
├── HtmlToXamlConverter.cs
└── HtmlTokenType.cs
SYMBOL INDEX (370 symbols across 43 files)
FILE: EasyJob/App.xaml.cs
class App (line 15) | public partial class App : Application
method OnStartup (line 17) | protected override void OnStartup(StartupEventArgs e)
method SetDropDownMenuToBeRightAligned (line 24) | private static void SetDropDownMenuToBeRightAligned()
FILE: EasyJob/MainWindow.xaml.cs
class MainWindow (line 23) | public partial class MainWindow : Window
method MainWindow (line 31) | public MainWindow()
method LoadConfig (line 38) | public void LoadConfig()
method SaveConfig (line 63) | public bool SaveConfig()
method MainMenuItemsVisibility (line 119) | private void MainMenuItemsVisibility()
method AddTextToConsole (line 145) | private void AddTextToConsole (string Text, int OwnerTab)
method AddTextToEventsList (line 164) | public void AddTextToEventsList(string Text, bool IsAsync)
method ScrollToBottomListBox (line 186) | private void ScrollToBottomListBox(ListBox listBox, bool IsAsync)
method RemoveTaskFromTasksList (line 216) | private void RemoveTaskFromTasksList(int ProcessID, bool IsAsync)
method AddTaskToTasksList (line 251) | private void AddTaskToTasksList(int ProcessID, string ProcessFileName)
method GetScriptPath (line 257) | private string GetScriptPath(string ButtonScript, string ButtonScriptP...
method GetPowerShellArguments (line 275) | private string GetPowerShellArguments(string Arguments)
method ShowAddButtonDialog (line 287) | private void ShowAddButtonDialog()
method ShowRenameTabDialog (line 315) | private void ShowRenameTabDialog(int SelectedTab, string SelectedTabHe...
method ShowAddNewTabDialog (line 346) | private void ShowAddNewTabDialog()
method ShowReorderActionButtonsDialog (line 362) | private void ShowReorderActionButtonsDialog()
method ClearOutputButton_Click (line 384) | public void ClearOutputButton_Click(object sender, RoutedEventArgs e)
method ConvertArgumentsToAnswers (line 391) | public AnswerData ConvertArgumentsToAnswers(List<Answer> Answers)
method ConvertArgumentsToPowerShell (line 398) | public string ConvertArgumentsToPowerShell(List<Answer> Answers)
method ConvertArgumentsToCMD (line 414) | public string ConvertArgumentsToCMD(List<Answer> Answers)
method RemoveScriptFileFromPath (line 430) | public string RemoveScriptFileFromPath(string ScriptPath)
method ActionButton_Click (line 446) | public async void ActionButton_Click(object sender, RoutedEventArgs e)
method RunProcessAsync (line 525) | public async Task<int> RunProcessAsync(string FileName, string Args, i...
method RunProcessAsync (line 542) | private Task<int> RunProcessAsync(Process process, int OwnerTab, strin...
method TasksListStop_Click (line 591) | private void TasksListStop_Click(object sender, RoutedEventArgs e)
method ScrollToTopButton_Click (line 608) | private void ScrollToTopButton_Click(object sender, RoutedEventArgs e)
method ScrollToBottomButton_Click (line 621) | private void ScrollToBottomButton_Click(object sender, RoutedEventArgs e)
method FindVisualChild (line 634) | private static T FindVisualChild<T>(DependencyObject parent) where T :...
method ReloadConfigMenuItem_Click (line 653) | private void ReloadConfigMenuItem_Click(object sender, RoutedEventArgs e)
method OpenAppFolderMenuItem_Click (line 680) | private void OpenAppFolderMenuItem_Click(object sender, RoutedEventArg...
method ClearEventsLogListMenuItem_Click (line 693) | private void ClearEventsLogListMenuItem_Click(object sender, RoutedEve...
method ReorderTabsMenuItem_Click (line 698) | private void ReorderTabsMenuItem_Click(object sender, RoutedEventArgs e)
method ConfigurationMenuItem_Click (line 716) | private void ConfigurationMenuItem_Click(object sender, RoutedEventArg...
method AddTabMenuItem_Click (line 728) | private void AddTabMenuItem_Click(object sender, RoutedEventArgs e)
method RemoveCurrentTabMenuItem_Click (line 733) | private void RemoveCurrentTabMenuItem_Click(object sender, RoutedEvent...
method RenameCurrentTabMenuItem_Click (line 758) | private void RenameCurrentTabMenuItem_Click(object sender, RoutedEvent...
method AddButtonToCurrentTabMenuItem_Click (line 764) | private void AddButtonToCurrentTabMenuItem_Click(object sender, Routed...
method ReorderButtonsInCurrentTabMenuItem_Click (line 769) | private void ReorderButtonsInCurrentTabMenuItem_Click(object sender, R...
method ExitMenuItem_Click (line 774) | private void ExitMenuItem_Click(object sender, RoutedEventArgs e)
method MenuAbout_Click (line 789) | private void MenuAbout_Click(object sender, RoutedEventArgs e)
method MenuTroubleshooting_Click (line 795) | private void MenuTroubleshooting_Click(object sender, RoutedEventArgs e)
method MenuColorTags_Click (line 801) | private void MenuColorTags_Click(object sender, RoutedEventArgs e)
method ActionButton_PreviewMouseDown (line 812) | public void ActionButton_PreviewMouseDown(object sender, MouseButtonEv...
method OnActionButtonPannel_PreviewMouseDown (line 861) | public void OnActionButtonPannel_PreviewMouseDown(object sender, Mouse...
method OnTabHeader_PreviewMouseDown (line 917) | private void OnTabHeader_PreviewMouseDown(object sender, MouseButtonEv...
method ContextMenuRemoveTab_Click (line 963) | private void ContextMenuRemoveTab_Click(object sender, RoutedEventArgs e)
method ContextMenuRenameTab_Click (line 990) | private void ContextMenuRenameTab_Click(object sender, RoutedEventArgs e)
method ContextMenuAddTab_Click (line 1015) | private void ContextMenuAddTab_Click(object sender, RoutedEventArgs e)
method ContextMenuRemoveActionButton_Click (line 1020) | private void ContextMenuRemoveActionButton_Click(object sender, Routed...
method ContextMenuCopyActionButton_Click (line 1047) | private void ContextMenuCopyActionButton_Click(object sender, RoutedEv...
method ContextMenuEditActionButton_Click (line 1058) | private void ContextMenuEditActionButton_Click(object sender, RoutedEv...
method ContextMenuAddActionButton_Click (line 1093) | private void ContextMenuAddActionButton_Click(object sender, RoutedEve...
method ContextMenuReorderActionButtons_Click (line 1098) | private void ContextMenuReorderActionButtons_Click(object sender, Rout...
method ContextMenuPasteActionButton_Click (line 1103) | private void ContextMenuPasteActionButton_Click(object sender, RoutedE...
FILE: EasyJob/Serialization/AnswerDialog/Answer.cs
class Answer (line 3) | public class Answer
FILE: EasyJob/Serialization/AnswerDialog/AnswerData.cs
class AnswerData (line 5) | public class AnswerData
FILE: EasyJob/Serialization/Config/Config.cs
class Config (line 5) | public class Config
FILE: EasyJob/Serialization/Config/ConfigArgument.cs
class ConfigArgument (line 3) | public class ConfigArgument
method ConfigArgument (line 13) | public ConfigArgument(string argument_question, string argument_answer)
FILE: EasyJob/Serialization/Config/ConfigButton.cs
class ConfigButton (line 6) | public class ConfigButton
method ConfigButton (line 26) | public ConfigButton(Guid id, string text, string description, string s...
FILE: EasyJob/Serialization/Config/ConfigRestrictions.cs
class ConfigRestrictions (line 9) | public class ConfigRestrictions
FILE: EasyJob/Serialization/Config/ConfigTab.cs
class ConfigTab (line 6) | public class ConfigTab
method ConfigTab (line 18) | public ConfigTab(Guid id, string header, List<ConfigButton> buttons)
FILE: EasyJob/Serialization/TabItems/ActionButton.cs
class ActionButton (line 8) | public class ActionButton
FILE: EasyJob/Serialization/TabItems/TabData.cs
class TabData (line 8) | public class TabData : INotifyPropertyChanged
method TabData (line 15) | public TabData()
method TabData (line 24) | public TabData(string tabTextBoxText)
method OnChange (line 99) | protected void OnChange(string info)
FILE: EasyJob/Serialization/TasksList/TaskListTask.cs
class TaskListTask (line 3) | public class TaskListTask
FILE: EasyJob/Utils/CommonUtils.cs
class CommonUtils (line 10) | public class CommonUtils
method OpenLinkInBrowser (line 12) | public static void OpenLinkInBrowser(string url)
method ReadAssemblyFile (line 24) | public static string ReadAssemblyFile(string name)
method ApplyConsoleColorTagsToText (line 43) | public static string ApplyConsoleColorTagsToText(string Text)
method ConvertPartToRelative (line 83) | public static string ConvertPartToRelative(string Path)
method ApplicationStartupPath (line 89) | public static string ApplicationStartupPath()
FILE: EasyJob/Utils/ConfigUtils.cs
class ConfigUtils (line 16) | public class ConfigUtils
method ConvertTabsFromConfigToUI (line 21) | public static ObservableCollection<TabData> ConvertTabsFromConfigToUI(...
method ConvertTabsFromUIToConfig (line 51) | public static List<ConfigTab> ConvertTabsFromUIToConfig(IEnumerable<Ta...
method SaveFromConfigToFile (line 77) | public static bool SaveFromConfigToFile(Config config)
FILE: EasyJob/Utils/ScrollViewerExtensions.cs
class ScrollViewerExtensions (line 11) | public class ScrollViewerExtensions
method AlwaysScrollToEndChanged (line 16) | private static void AlwaysScrollToEndChanged(object sender, Dependency...
method GetAlwaysScrollToEnd (line 32) | public static bool GetAlwaysScrollToEnd(ScrollViewer scroll)
method SetAlwaysScrollToEnd (line 38) | public static void SetAlwaysScrollToEnd(ScrollViewer scroll, bool alwa...
method ScrollChanged (line 44) | private static void ScrollChanged(object sender, ScrollChangedEventArg...
FILE: EasyJob/Windows/AboutDialog.xaml.cs
class AboutDialog (line 15) | public partial class AboutDialog : Window
method AboutDialog (line 20) | public AboutDialog()
method LoadDataInfoIntoTheForm (line 26) | public void LoadDataInfoIntoTheForm()
method ConvertContentTo (line 36) | private static void ConvertContentTo(HtmlNode node, TextWriter outText)
method ConvertToPlainText (line 49) | public static string ConvertToPlainText(string html)
method ConvertTo (line 60) | private static void ConvertTo(HtmlNode node, TextWriter outText)
method GetInspirationButton_Click (line 114) | private void GetInspirationButton_Click(object sender, RoutedEventArgs e)
method CheckNewReleasesButton_Click (line 119) | private void CheckNewReleasesButton_Click(object sender, RoutedEventAr...
method GithubImage_MouseLeftButtonDown (line 124) | private void GithubImage_MouseLeftButtonDown(object sender, System.Win...
FILE: EasyJob/Windows/AddActionButtonDialog.xaml.cs
class AddActionButtonDialog (line 24) | public partial class AddActionButtonDialog : Window
method AddActionButtonDialog (line 27) | public AddActionButtonDialog()
method OKButton_Click (line 33) | private void OKButton_Click(object sender, RoutedEventArgs e)
method ConvertScriptTypeComboBoxToString (line 45) | private string ConvertScriptTypeComboBoxToString(ComboBox cb)
method ConvertScriptPathTypeComboBoxToString (line 57) | private string ConvertScriptPathTypeComboBoxToString(ComboBox cb)
method CANCELButton_Click (line 69) | private void CANCELButton_Click(object sender, RoutedEventArgs e)
method ADDButton_Click (line 74) | private void ADDButton_Click(object sender, RoutedEventArgs e)
method DeleteArgumentButton_Click (line 84) | private void DeleteArgumentButton_Click(object sender, RoutedEventArgs e)
method HelpButton_Click (line 94) | private void HelpButton_Click(object sender, RoutedEventArgs e)
method SelectFileButton_Click (line 101) | private void SelectFileButton_Click(object sender, RoutedEventArgs e)
FILE: EasyJob/Windows/AnswerDialog.xaml.cs
class AnswerDialog (line 22) | public partial class AnswerDialog : Window
method AnswerDialog (line 25) | public AnswerDialog(AnswerData _answerData)
method OKButton_Click (line 39) | private void OKButton_Click(object sender, RoutedEventArgs e)
method CANCELButton_Click (line 58) | private void CANCELButton_Click(object sender, RoutedEventArgs e)
FILE: EasyJob/Windows/ColorTagsDialog.xaml.cs
class ColorTagsDialog (line 20) | public partial class ColorTagsDialog : Window
method ColorTagsDialog (line 22) | public ColorTagsDialog()
FILE: EasyJob/Windows/ConfigurationDialog.xaml.cs
class ConfigurationDialog (line 23) | public partial class ConfigurationDialog : Window
method ConfigurationDialog (line 27) | public ConfigurationDialog(Config _config)
method LoadConfiguration (line 34) | private void LoadConfiguration()
method SetComboBoxFromValue (line 73) | private void SetComboBoxFromValue(ComboBox comboBox, bool value)
method GetComboBoxValue (line 85) | private bool GetComboBoxValue(ComboBox comboBox)
method SaveButton_Click (line 97) | private void SaveButton_Click(object sender, RoutedEventArgs e)
method HelpButton_Click (line 139) | private void HelpButton_Click(object sender, RoutedEventArgs e)
FILE: EasyJob/Windows/EditActionButtonDialog.xaml.cs
class EditActionButtonDialog (line 25) | public partial class EditActionButtonDialog : Window
method EditActionButtonDialog (line 29) | public EditActionButtonDialog(ActionButton _actionButton)
method ConvertScriptTypeComboBoxToString (line 48) | private string ConvertScriptTypeComboBoxToString(ComboBox cb)
method ConvertScriptPathTypeComboBoxToString (line 60) | private string ConvertScriptPathTypeComboBoxToString(ComboBox cb)
method ADDButton_Click (line 72) | private void ADDButton_Click(object sender, RoutedEventArgs e)
method DeleteArgumentButton_Click (line 82) | private void DeleteArgumentButton_Click(object sender, RoutedEventArgs e)
method SaveButton_Click (line 92) | private void SaveButton_Click(object sender, RoutedEventArgs e)
method CancelButton_Click (line 109) | private void CancelButton_Click(object sender, RoutedEventArgs e)
method HelpButton_Click (line 114) | private void HelpButton_Click(object sender, RoutedEventArgs e)
method SelectFileButton_Click (line 121) | private void SelectFileButton_Click(object sender, RoutedEventArgs e)
FILE: EasyJob/Windows/HelpDialog.xaml.cs
class HelpDialog (line 25) | public partial class HelpDialog : Window
method HelpDialog (line 27) | public HelpDialog(string helpitem)
method LoadXml (line 33) | private void LoadXml(string helpitem)
method ReloadVideoButton_Click (line 59) | private void ReloadVideoButton_Click(object sender, RoutedEventArgs e)
method StopVideoButton_Click (line 65) | private void StopVideoButton_Click(object sender, RoutedEventArgs e)
method PlayVideoButton_Click (line 70) | private void PlayVideoButton_Click(object sender, RoutedEventArgs e)
FILE: EasyJob/Windows/NewTabDialog.xaml.cs
class NewTabDialog (line 26) | public partial class NewTabDialog : Window
method NewTabDialog (line 32) | public NewTabDialog()
method LoadConfig (line 38) | public void LoadConfig()
method SaveConfig (line 60) | public bool SaveConfig()
method CreateNewTabButton_Click (line 92) | private void CreateNewTabButton_Click(object sender, RoutedEventArgs e)
method CancelButton_Click (line 113) | private void CancelButton_Click(object sender, RoutedEventArgs e)
FILE: EasyJob/Windows/RenameTabDialog.xaml.cs
class RenameTabDialog (line 20) | public partial class RenameTabDialog : Window
method RenameTabDialog (line 24) | public RenameTabDialog(string SelectedTabHeader)
method CancelRenameButton_Click (line 30) | private void CancelRenameButton_Click(object sender, RoutedEventArgs e)
method RenameTabButton_Click (line 35) | private void RenameTabButton_Click(object sender, RoutedEventArgs e)
FILE: EasyJob/Windows/ReorderActionButtonsDialog.xaml.cs
class ReorderActionButtonsDialog (line 26) | public partial class ReorderActionButtonsDialog : Window
method ReorderActionButtonsDialog (line 34) | public ReorderActionButtonsDialog(int _currentTabIndex, Config _config)
method LoadConfig (line 42) | public void LoadConfig()
method SaveConfig (line 63) | public bool SaveConfig()
method ActionButtonsRedorderDown_Click (line 94) | private void ActionButtonsRedorderDown_Click(object sender, RoutedEven...
method ActionButtonsReorderUp_Click (line 120) | private void ActionButtonsReorderUp_Click(object sender, RoutedEventAr...
FILE: EasyJob/Windows/ReorderTabsDialog.xaml.cs
class ReorderTabsDialog (line 16) | public partial class ReorderTabsDialog : Window
method ReorderTabsDialog (line 22) | public ReorderTabsDialog(Config _config)
method LoadConfig (line 29) | public void LoadConfig()
method SaveConfig (line 43) | public bool SaveConfig()
method TabsRedorderDown_Click (line 74) | private void TabsRedorderDown_Click(object sender, RoutedEventArgs e)
method TabsReorderUp_Click (line 97) | private void TabsReorderUp_Click(object sender, RoutedEventArgs e)
FILE: EasyJob/Windows/TroubleshootingWindow.xaml.cs
class TroubleshootingWindow (line 26) | public partial class TroubleshootingWindow : Window
method TroubleshootingWindow (line 30) | public TroubleshootingWindow(Config _config)
method FillKnownData (line 37) | private void FillKnownData()
method TroubleshootingWindow_Loaded (line 108) | private void TroubleshootingWindow_Loaded(object sender, RoutedEventAr...
FILE: EasyJobPSTools/Program.cs
class Program (line 11) | public class Program
method ShowEJInputBoxWindow (line 13) | public static string ShowEJInputBoxWindow(string Header, string Text, ...
method ShowEJSelectFileWindow (line 26) | public static string ShowEJSelectFileWindow()
method ShowEJSelectFileWindow (line 39) | public static string ShowEJSelectFileWindow(string fileType)
method ShowEJSelectFolderWindow (line 53) | public static string ShowEJSelectFolderWindow()
FILE: EasyJobPSTools/Properties/Resources.Designer.cs
class Resources (line 22) | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resource...
method Resources (line 31) | [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Mic...
FILE: EasyJobPSTools/Properties/Settings.Designer.cs
class Settings (line 14) | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
FILE: EasyJobPSTools/Utils/CommonUtils.cs
class CommonUtils (line 7) | public class CommonUtils
method FixModernWpfUI (line 9) | public static void FixModernWpfUI()
FILE: EasyJobPSTools/Windows/ShowEJInputBox.xaml.cs
class ShowEJInputBox (line 21) | public partial class ShowEJInputBox : Window
method ShowEJInputBox (line 28) | public ShowEJInputBox(string Header, string Text, bool AllowEmptyResult)
method OKButton_Click (line 43) | private void OKButton_Click(object sender, RoutedEventArgs e)
method CancelButton_Click (line 57) | private void CancelButton_Click(object sender, RoutedEventArgs e)
method FormAnswer_TextChanged (line 62) | private void FormAnswer_TextChanged(object sender, TextChangedEventArg...
FILE: WpfRichText/AttachedProperties/RichTextboxAssistant.cs
class RichTextBoxAssistant (line 15) | public static class RichTextBoxAssistant
method OnBoundDocumentChanged (line 25) | private static void OnBoundDocumentChanged(DependencyObject d, Depende...
method RemoveEventHandler (line 57) | private static void RemoveEventHandler(RichTextBox box)
method AttachEventHandler (line 76) | private static void AttachEventHandler(RichTextBox box)
method HandleLostFocus (line 95) | private static void HandleLostFocus(object sender, RoutedEventArgs e)
method HandleTextChanged (line 109) | private static void HandleTextChanged(object sender, RoutedEventArgs e)
method GetBoundDocument (line 130) | public static string GetBoundDocument(DependencyObject dependencyObject)
method SetBoundDocument (line 149) | public static void SetBoundDocument(DependencyObject dependencyObject,...
FILE: WpfRichText/Commands/CommandReference.cs
class CommandReference (line 12) | public class CommandReference : Freezable, ICommand
method CommandReference (line 15) | public CommandReference()
method CanExecute (line 36) | public bool CanExecute(object parameter)
method Execute (line 46) | public void Execute(object parameter)
method OnCommandChanged (line 55) | private static void OnCommandChanged(DependencyObject d, DependencyPro...
method CreateInstanceCore (line 78) | protected override Freezable CreateInstanceCore()
FILE: WpfRichText/Commands/DelegateCommand.cs
class DelegateCommand (line 12) | public class DelegateCommand : ICommand
method DelegateCommand (line 19) | public DelegateCommand(Action executeMethod)
method DelegateCommand (line 27) | public DelegateCommand(Action executeMethod, Func<bool> canExecuteMethod)
method DelegateCommand (line 35) | public DelegateCommand(Action executeMethod, Func<bool> canExecuteMeth...
method CanExecute (line 54) | public bool CanExecute()
method Execute (line 66) | public void Execute()
method RaiseCanExecuteChanged (line 103) | public void RaiseCanExecuteChanged()
method OnCanExecuteChanged (line 111) | protected virtual void OnCanExecuteChanged()
method CanExecute (line 143) | bool ICommand.CanExecute(object parameter)
method Execute (line 148) | void ICommand.Execute(object parameter)
method DelegateCommand (line 177) | public DelegateCommand(Action<T> executeMethod)
method DelegateCommand (line 185) | public DelegateCommand(Action<T> executeMethod, Func<T, bool> canExecu...
method DelegateCommand (line 193) | public DelegateCommand(Action<T> executeMethod, Func<T, bool> canExecu...
method CanExecute (line 212) | public bool CanExecute(T parameter)
method Execute (line 224) | public void Execute(T parameter)
method RaiseCanExecuteChanged (line 235) | public void RaiseCanExecuteChanged()
method OnCanExecuteChanged (line 243) | protected virtual void OnCanExecuteChanged()
method CanExecute (line 301) | bool ICommand.CanExecute(object parameter)
method Execute (line 314) | void ICommand.Execute(object parameter)
class DelegateCommand (line 170) | public class DelegateCommand<T> : ICommand
method DelegateCommand (line 19) | public DelegateCommand(Action executeMethod)
method DelegateCommand (line 27) | public DelegateCommand(Action executeMethod, Func<bool> canExecuteMethod)
method DelegateCommand (line 35) | public DelegateCommand(Action executeMethod, Func<bool> canExecuteMeth...
method CanExecute (line 54) | public bool CanExecute()
method Execute (line 66) | public void Execute()
method RaiseCanExecuteChanged (line 103) | public void RaiseCanExecuteChanged()
method OnCanExecuteChanged (line 111) | protected virtual void OnCanExecuteChanged()
method CanExecute (line 143) | bool ICommand.CanExecute(object parameter)
method Execute (line 148) | void ICommand.Execute(object parameter)
method DelegateCommand (line 177) | public DelegateCommand(Action<T> executeMethod)
method DelegateCommand (line 185) | public DelegateCommand(Action<T> executeMethod, Func<T, bool> canExecu...
method DelegateCommand (line 193) | public DelegateCommand(Action<T> executeMethod, Func<T, bool> canExecu...
method CanExecute (line 212) | public bool CanExecute(T parameter)
method Execute (line 224) | public void Execute(T parameter)
method RaiseCanExecuteChanged (line 235) | public void RaiseCanExecuteChanged()
method OnCanExecuteChanged (line 243) | protected virtual void OnCanExecuteChanged()
method CanExecute (line 301) | bool ICommand.CanExecute(object parameter)
method Execute (line 314) | void ICommand.Execute(object parameter)
class CommandManagerHelper (line 335) | internal static class CommandManagerHelper
method CallWeakReferenceHandlers (line 337) | internal static void CallWeakReferenceHandlers(List<WeakReference> han...
method AddHandlersToRequerySuggested (line 372) | internal static void AddHandlersToRequerySuggested(List<WeakReference>...
method RemoveHandlersFromRequerySuggested (line 387) | internal static void RemoveHandlersFromRequerySuggested(List<WeakRefer...
method AddWeakReferenceHandler (line 407) | internal static void AddWeakReferenceHandler(ref List<WeakReference> h...
method RemoveWeakReferenceHandler (line 417) | internal static void RemoveWeakReferenceHandler(List<WeakReference> ha...
FILE: WpfRichText/Controls/RichTextEditor.xaml.cs
class RichTextEditor (line 22) | public partial class RichTextEditor : UserControl
method RichTextEditor (line 30) | public RichTextEditor()
FILE: WpfRichText/XamlToHtmlParser/HtmlCssParser.cs
class HtmlCssParser (line 22) | internal static class HtmlCssParser
method GetElementPropertiesFromCssAttributes (line 30) | internal static void GetElementPropertiesFromCssAttributes(XmlElement ...
method ParseWhiteSpace (line 201) | private static void ParseWhiteSpace(string styleValue, ref int nextIndex)
method ParseWord (line 213) | private static bool ParseWord(string word, string styleValue, ref int ...
method ParseWordEnumeration (line 237) | private static string ParseWordEnumeration(string[] words, string styl...
method ParseWordEnumeration (line 250) | private static void ParseWordEnumeration(string[] words, string styleV...
method ParseCssSize (line 259) | private static string ParseCssSize(string styleValue, ref int nextInde...
method ParseCssSize (line 299) | private static void ParseCssSize(string styleValue, ref int nextIndex,...
method ParseCssColor (line 337) | private static string ParseCssColor(string styleValue, ref int nextIndex)
method ParseCssColor (line 402) | private static void ParseCssColor(string styleValue, ref int nextIndex...
method ParseCssFont (line 445) | private static void ParseCssFont(string styleValue, Hashtable localPro...
method ParseCssFontStyle (line 465) | private static void ParseCssFontStyle(string styleValue, ref int nextI...
method ParseCssFontVariant (line 470) | private static void ParseCssFontVariant(string styleValue, ref int nex...
method ParseCssFontWeight (line 475) | private static void ParseCssFontWeight(string styleValue, ref int next...
method ParseCssFontFamily (line 480) | private static void ParseCssFontFamily(string styleValue, ref int next...
method ParseCssListStyle (line 575) | private static void ParseCssListStyle(string styleValue, Hashtable loc...
method ParseCssListStyleType (line 610) | private static string ParseCssListStyleType(string styleValue, ref int...
method ParseCssListStylePosition (line 615) | private static string ParseCssListStylePosition(string styleValue, ref...
method ParseCssListStyleImage (line 620) | private static string ParseCssListStyleImage(string styleValue, ref in...
method ParseCssTextDecoration (line 634) | private static void ParseCssTextDecoration(string styleValue, ref int ...
method ParseCssTextTransform (line 662) | private static void ParseCssTextTransform(string styleValue, ref int n...
method ParseCssTextAlign (line 675) | private static void ParseCssTextAlign(string styleValue, ref int nextI...
method ParseCssVerticalAlign (line 688) | private static void ParseCssVerticalAlign(string styleValue, ref int n...
method ParseCssFloat (line 702) | private static void ParseCssFloat(string styleValue, ref int nextIndex...
method ParseCssClear (line 715) | private static void ParseCssClear(string styleValue, ref int nextIndex...
method ParseCssRectangleProperty (line 727) | private static bool ParseCssRectangleProperty(string styleValue, ref i...
method ParseCssBorder (line 774) | private static void ParseCssBorder(string styleValue, ref int nextInde...
method ParseCssBorderStyle (line 792) | private static string ParseCssBorderStyle(string styleValue, ref int n...
method ParseCssBackground (line 812) | private static void ParseCssBackground(string styleValue, ref int next...
class CssStylesheet (line 819) | internal class CssStylesheet
method CssStylesheet (line 822) | public CssStylesheet(XmlElement htmlElement)
method DiscoverStyleDefinitions (line 832) | public void DiscoverStyleDefinitions(XmlElement htmlElement)
method RemoveComments (line 920) | private string RemoveComments(string text)
method AddStyleDefinition (line 938) | public void AddStyleDefinition(string selector, string definition)
method GetStyle (line 965) | public string GetStyle(string elementName, List<XmlElement> sourceCont...
method MatchSelectorLevel (line 993) | private static bool MatchSelectorLevel(string selectorLevel, XmlElemen...
class StyleDefinition (line 1045) | private class StyleDefinition
method StyleDefinition (line 1047) | public StyleDefinition(string selector, string definition)
FILE: WpfRichText/XamlToHtmlParser/HtmlFromXamlConverter.cs
class HtmlFromXamlConverter (line 25) | internal static class HtmlFromXamlConverter
method ConvertXamlToHtml (line 34) | internal static string ConvertXamlToHtml(string xamlString)
method ConvertXamlToHtml (line 47) | internal static string ConvertXamlToHtml(string xamlString, bool asFlo...
method WriteFlowDocument (line 93) | private static bool WriteFlowDocument(XmlTextReader xamlReader, XmlTex...
method WriteFormattingProperties (line 140) | private static void WriteFormattingProperties(XmlTextReader xamlReader...
method ParseXamlColor (line 267) | private static string ParseXamlColor(string color)
method ParseXamlThickness (line 277) | private static string ParseXamlThickness(string thickness)
method WriteElementContent (line 328) | private static void WriteElementContent(XmlTextReader xamlReader, XmlT...
method AddComplexProperty (line 409) | private static void AddComplexProperty(XmlTextReader xamlReader, Strin...
method WriteElement (line 436) | private static void WriteElement(XmlTextReader xamlReader, XmlTextWrit...
method ReadNextToken (line 539) | private static bool ReadNextToken(XmlReader xamlReader)
FILE: WpfRichText/XamlToHtmlParser/HtmlLexicalAnalyzer.cs
class HtmlLexicalAnalyzer (line 24) | internal class HtmlLexicalAnalyzer : IDisposable
method HtmlLexicalAnalyzer (line 41) | internal HtmlLexicalAnalyzer(string inputTextString)
method GetNextContentToken (line 73) | internal void GetNextContentToken()
method GetNextTagToken (line 167) | internal void GetNextTagToken()
method GetNextEqualSignToken (line 225) | internal void GetNextEqualSignToken()
method GetNextAtomToken (line 247) | internal void GetNextAtomToken()
method GetNextCharacter (line 337) | private void GetNextCharacter()
method ReadLookAheadCharacter (line 436) | private void ReadLookAheadCharacter()
method SkipWhiteSpace (line 450) | private void SkipWhiteSpace()
method IsGoodForNameStart (line 507) | private static bool IsGoodForNameStart(char character)
method IsGoodForName (line 523) | private static bool IsGoodForName(char character)
method IsCombiningCharacter (line 548) | private static bool IsCombiningCharacter(char character)
method IsExtender (line 565) | private static bool IsExtender(char character)
method ReadDynamicContent (line 574) | private void ReadDynamicContent()
method ReadComment (line 615) | private void ReadComment()
method ReadUnknownDirective (line 672) | private void ReadUnknownDirective()
method SkipProcessingDirective (line 702) | private void SkipProcessingDirective()
method Dispose (line 818) | public void Dispose()
method Dispose (line 823) | private void Dispose(bool disposing)
FILE: WpfRichText/XamlToHtmlParser/HtmlParser.cs
class HtmlParser (line 76) | internal class HtmlParser : IDisposable
method HtmlParser (line 92) | private HtmlParser(string inputString)
method ParseHtml (line 128) | internal static XmlElement ParseHtml(string htmlString)
method ExtractHtmlFromClipboardData (line 166) | internal static string ExtractHtmlFromClipboardData(string htmlDataStr...
method AddHtmlClipboardHeader (line 206) | internal static string AddHtmlClipboardHeader(string htmlString)
method InvariantAssert (line 252) | private static void InvariantAssert(bool condition, string message)
method ParseHtmlContent (line 266) | private XmlElement ParseHtmlContent()
method CreateElementCopy (line 361) | private XmlElement CreateElementCopy(XmlElement htmlElement)
method AddEmptyElement (line 372) | private void AddEmptyElement(XmlElement htmlEmptyElement)
method OpenInlineElement (line 379) | private void OpenInlineElement(XmlElement htmlInlineElement)
method OpenStructuringElement (line 385) | private void OpenStructuringElement(XmlElement htmlElement)
method IsElementOpened (line 428) | private bool IsElementOpened(string htmlElementName)
method CloseElement (line 440) | private void CloseElement(string htmlElementName)
method AddTextContent (line 480) | private void AddTextContent(string textContent)
method AddComment (line 491) | private void AddComment(string comment)
method OpenPendingInlineElements (line 504) | private void OpenPendingInlineElements()
method ParseAttributes (line 520) | private void ParseAttributes(XmlElement xmlElement)
method Dispose (line 566) | public void Dispose()
method Dispose (line 571) | private void Dispose(bool disposing)
FILE: WpfRichText/XamlToHtmlParser/HtmlSchema.cs
class HtmlSchema (line 22) | internal static class HtmlSchema
method HtmlSchema (line 37) | static HtmlSchema()
method IsEmptyElement (line 75) | internal static bool IsEmptyElement(string xmlElementName)
method IsBlockElement (line 89) | internal static bool IsBlockElement(string xmlElementName)
method IsInlineElement (line 99) | internal static bool IsInlineElement(string xmlElementName)
method IsKnownOpenableElement (line 112) | internal static bool IsKnownOpenableElement(string xmlElementName)
method ClosesOnParentElementEnd (line 124) | internal static bool ClosesOnParentElementEnd(string xmlElementName)
method ClosesOnNextElementStart (line 138) | internal static bool ClosesOnNextElementStart(string currentElementNam...
method IsEntity (line 175) | internal static bool IsEntity(string entityName)
method EntityCharacterValue (line 195) | internal static char EntityCharacterValue(string entityName)
method InitializeInlineElements (line 230) | private static void InitializeInlineElements()
method InitializeBlockElements (line 264) | private static void InitializeBlockElements()
method InitializeEmptyElements (line 307) | private static void InitializeEmptyElements()
method InitializeOtherOpenableElements (line 327) | private static void InitializeOtherOpenableElements()
method InitializeElementsClosingOnParentElementEnd (line 362) | private static void InitializeElementsClosingOnParentElementEnd()
method InitializeElementsClosingOnNewElementStart (line 381) | private static void InitializeElementsClosingOnNewElementStart()
method InitializeHtmlCharacterEntities (line 458) | private static void InitializeHtmlCharacterEntities()
FILE: WpfRichText/XamlToHtmlParser/HtmlToXamlConverter.cs
class HtmlToXamlConverter (line 26) | public static class HtmlToXamlConverter
method ConvertHtmlToXaml (line 50) | public static string ConvertHtmlToXaml(string htmlString, bool asFlowD...
method GetAttribute (line 97) | internal static string GetAttribute(XmlElement element, string attribu...
method UnQuote (line 125) | internal static string UnQuote(string value)
method AddBlock (line 172) | private static XmlNode AddBlock(XmlElement xamlParentElement, XmlNode ...
method AddBreak (line 302) | private static void AddBreak(XmlElement xamlParentElement, string html...
method AddSection (line 338) | private static void AddSection(XmlElement xamlParentElement, XmlElemen...
method AddParagraph (line 412) | private static void AddParagraph(XmlElement xamlParentElement, XmlElem...
method AddImplicitParagraph (line 452) | private static XmlNode AddImplicitParagraph(XmlElement xamlParentEleme...
method AddInline (line 507) | private static void AddInline(XmlElement xamlParentElement, XmlNode ht...
method AddSpanOrRun (line 563) | private static void AddSpanOrRun(XmlElement xamlParentElement, XmlElem...
method AddTextRun (line 603) | private static void AddTextRun(XmlElement xamlElement, string textData)
method AddHyperlink (line 624) | private static void AddHyperlink(XmlElement xamlParentElement, XmlElem...
method DefineInlineFragmentParent (line 670) | private static void DefineInlineFragmentParent(XmlComment htmlComment,...
method ExtractInlineFragment (line 693) | private static XmlElement ExtractInlineFragment(XmlElement xamlFlowDoc...
method AddImage (line 722) | private static void AddImage(XmlElement xamlParentElement, XmlElement ...
method AddList (line 748) | private static void AddList(XmlElement xamlParentElement, XmlElement h...
method AddOrphanListItems (line 819) | private static XmlElement AddOrphanListItems(XmlElement xamlParentElem...
method AddListItem (line 873) | private static void AddListItem(XmlElement xamlListElement, XmlElement...
method AddTable (line 920) | private static void AddTable(XmlElement xamlParentElement, XmlElement ...
method GetCellFromSingleCellTable (line 1024) | private static XmlElement GetCellFromSingleCellTable(XmlElement htmlTa...
method AddColumnInformation (line 1102) | private static void AddColumnInformation(XmlElement htmlTableElement, ...
method AddTableColumnGroup (line 1157) | private static void AddTableColumnGroup(XmlElement xamlTableElement, X...
method AddTableColumn (line 1187) | private static void AddTableColumn(XmlElement xamlTableElement, XmlEle...
method AddTableRowsToTableBody (line 1220) | private static XmlNode AddTableRowsToTableBody(XmlElement xamlTableBod...
method AddTableCellsToTableRow (line 1304) | private static XmlNode AddTableCellsToTableRow(XmlElement xamlTableRow...
method AddDataToTableCell (line 1402) | private static void AddDataToTableCell(XmlElement xamlTableCellElement...
method AnalyzeTableStructure (line 1428) | private static ArrayList AnalyzeTableStructure(XmlElement htmlTableEle...
method AnalyzeTbodyStructure (line 1530) | private static double AnalyzeTbodyStructure(XmlElement htmlTbodyElemen...
method AnalyzeTRStructure (line 1597) | private static double AnalyzeTRStructure(XmlElement htmlTRElement, Arr...
method GetRowSpan (line 1753) | private static int GetRowSpan(XmlElement htmlTDElement)
method GetNextColumnIndex (line 1792) | private static int GetNextColumnIndex(int columnIndex, double columnWi...
method ClearActiveRowSpans (line 1829) | private static void ClearActiveRowSpans(ArrayList activeRowSpans)
method InitializeActiveRowSpans (line 1846) | private static void InitializeActiveRowSpans(ArrayList activeRowSpans,...
method GetNextColumnStart (line 1865) | private static double GetNextColumnStart(XmlElement htmlTDElement, dou...
method GetColumnWidth (line 1891) | private static double GetColumnWidth(XmlElement htmlTDElement)
method CalculateColumnSpan (line 1927) | private static int CalculateColumnSpan(int columnIndex, double columnW...
method VerifyColumnStartsAscendingOrder (line 1968) | private static void VerifyColumnStartsAscendingOrder(ArrayList columnS...
method ApplyLocalProperties (line 1999) | private static void ApplyLocalProperties(XmlElement xamlElement, Hasht...
method ComposeThicknessProperty (line 2244) | private static void ComposeThicknessProperty(XmlElement xamlElement, s...
method SetPropertyValue (line 2282) | private static void SetPropertyValue(XmlElement xamlElement, Dependenc...
method GetElementProperties (line 2317) | private static Hashtable GetElementProperties(XmlElement htmlElement, ...
method GetCssAttribute (line 2469) | private static string GetCssAttribute(string cssStyle, string attribut...
method TryGetLengthValue (line 2507) | private static bool TryGetLengthValue(string lengthAsString, out doubl...
method GetColorValue (line 2554) | private static string GetColorValue(string colorValue)
method ApplyPropertiesToTableCellElement (line 2572) | private static void ApplyPropertiesToTableCellElement(XmlElement htmlC...
FILE: WpfRichText/XamlToHtmlParser/HtmlTokenType.cs
type HtmlTokenType (line 16) | internal enum HtmlTokenType
Condensed preview — 80 files, each showing path, character count, and a content snippet. Download the .json file or copy for the full structured content (727K chars).
[
{
"path": "EasyJob/App.xaml",
"chars": 667,
"preview": "<Application x:Class=\"EasyJob.App\"\r\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\r\n "
},
{
"path": "EasyJob/App.xaml.cs",
"chars": 1154,
"preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.Configuration;\r\nusing System.Data;\r\nusing System.Linq;\r\n"
},
{
"path": "EasyJob/AssemblyInfo.cs",
"chars": 605,
"preview": "using System.Windows;\r\n\r\n[assembly: ThemeInfo(\r\n ResourceDictionaryLocation.None, //where theme specific resource dic"
},
{
"path": "EasyJob/Documentation/HelpDocumentation.xml",
"chars": 13368,
"preview": "<?xml version=\"1.0\" encoding=\"utf-8\" ?>\r\n<items>\r\n\t<item>\r\n\t\t<name>HelpAddActionButtonText</name>\r\n\t\t<heading>Text</hea"
},
{
"path": "EasyJob/EasyJob.csproj",
"chars": 12139,
"preview": "<Project Sdk=\"Microsoft.NET.Sdk\">\r\n\r\n <PropertyGroup>\r\n <OutputType>WinExe</OutputType>\r\n <TargetFramework>net5."
},
{
"path": "EasyJob/EasyJob.csproj.user",
"chars": 2811,
"preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\r\n<Project ToolsVersion=\"Current\" xmlns=\"http://schemas.microsoft.com/developer/m"
},
{
"path": "EasyJob/EasyJobPS/EasyJobPS.psd1",
"chars": 1102,
"preview": "# Module manifest for module 'EasyJobPS'\r\n# Generated by: Akshin Mustafayev\r\n# Generated on: 10/8/2021\r\n\r\n@{\r\n\r\n # Sc"
},
{
"path": "EasyJob/EasyJobPS/EasyJobPS.psm1",
"chars": 1204,
"preview": "[void][Reflection.Assembly]::LoadWithPartialName('Microsoft.VisualBasic')\r\n\r\nfunction Show-EJInputBox {\r\n <#\r\n "
},
{
"path": "EasyJob/LICENSE.txt",
"chars": 34522,
"preview": " GNU AFFERO GENERAL PUBLIC LICENSE\n Version 3, 19 November 2007\n\n Copyright (C)"
},
{
"path": "EasyJob/MainWindow.xaml",
"chars": 16133,
"preview": "<Window x:Class=\"EasyJob.MainWindow\"\r\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\r\n "
},
{
"path": "EasyJob/MainWindow.xaml.cs",
"chars": 44954,
"preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.Collections.ObjectModel;\r\nusing System.Diagnostics;\r\nusi"
},
{
"path": "EasyJob/Serialization/AnswerDialog/Answer.cs",
"chars": 194,
"preview": "namespace EasyJob.Serialization.AnswerDialog\r\n{\r\n public class Answer\r\n {\r\n public string AnswerQuestion {"
},
{
"path": "EasyJob/Serialization/AnswerDialog/AnswerData.cs",
"chars": 332,
"preview": "using System.Collections.Generic;\r\n\r\nnamespace EasyJob.Serialization.AnswerDialog\r\n{\r\n public class AnswerData\r\n "
},
{
"path": "EasyJob/Serialization/Config/Config.cs",
"chars": 635,
"preview": "using System.Collections.Generic;\r\n\r\nnamespace EasyJob.Serialization\r\n{\r\n public class Config\r\n {\r\n public"
},
{
"path": "EasyJob/Serialization/Config/ConfigArgument.cs",
"chars": 1222,
"preview": "namespace EasyJob.Serialization\r\n{\r\n public class ConfigArgument\r\n {\r\n private string _argument_question;\r"
},
{
"path": "EasyJob/Serialization/Config/ConfigButton.cs",
"chars": 3185,
"preview": "using System;\r\nusing System.Collections.Generic;\r\n\r\nnamespace EasyJob.Serialization\r\n{\r\n public class ConfigButton\r\n"
},
{
"path": "EasyJob/Serialization/Config/ConfigRestrictions.cs",
"chars": 1888,
"preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.Linq;\r\nusing System.Text;\r\nusing System.Threading.Tasks;"
},
{
"path": "EasyJob/Serialization/Config/ConfigTab.cs",
"chars": 1472,
"preview": "using System;\r\nusing System.Collections.Generic;\r\n\r\nnamespace EasyJob.Serialization\r\n{\r\n public class ConfigTab\r\n "
},
{
"path": "EasyJob/Serialization/TabItems/ActionButton.cs",
"chars": 2067,
"preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.Windows.Controls;\r\nusing EasyJob.Serialization.AnswerDia"
},
{
"path": "EasyJob/Serialization/TabItems/TabData.cs",
"chars": 3134,
"preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.ComponentModel;\r\nusing System.Threading.Tasks;\r\n\r\nnamesp"
},
{
"path": "EasyJob/Serialization/TasksList/TaskListTask.cs",
"chars": 182,
"preview": "namespace EasyJob.Serialization.TasksList\r\n{\r\n public class TaskListTask\r\n {\r\n public int TaskID { get; se"
},
{
"path": "EasyJob/Utils/CommonUtils.cs",
"chars": 3982,
"preview": "using System;\r\nusing System.Diagnostics;\r\nusing System.IO;\r\nusing System.Linq;\r\nusing System.Reflection;\r\nusing System."
},
{
"path": "EasyJob/Utils/ConfigUtils.cs",
"chars": 3714,
"preview": "using EasyJob.Serialization;\r\nusing EasyJob.Serialization.AnswerDialog;\r\nusing EasyJob.TabItems;\r\nusing Newtonsoft.Json"
},
{
"path": "EasyJob/Utils/ScrollViewerExtensions.cs",
"chars": 2483,
"preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.Linq;\r\nusing System.Text;\r\nusing System.Threading.Tasks;"
},
{
"path": "EasyJob/Windows/AboutDialog.xaml",
"chars": 2956,
"preview": "<Window x:Class=\"EasyJob.Windows.AboutDialog\"\r\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation"
},
{
"path": "EasyJob/Windows/AboutDialog.xaml.cs",
"chars": 4405,
"preview": "using EasyJob.Utils;\r\nusing HtmlAgilityPack;\r\nusing System;\r\nusing System.Diagnostics;\r\nusing System.IO;\r\nusing System."
},
{
"path": "EasyJob/Windows/AddActionButtonDialog.xaml",
"chars": 7771,
"preview": "<Window x:Class=\"EasyJob.Windows.AddActionButtonDialog\"\r\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/pr"
},
{
"path": "EasyJob/Windows/AddActionButtonDialog.xaml.cs",
"chars": 3931,
"preview": "using EasyJob.Serialization;\r\nusing EasyJob.Serialization.AnswerDialog;\r\nusing EasyJob.Utils;\r\nusing Microsoft.Win32;\r\n"
},
{
"path": "EasyJob/Windows/AnswerDialog.xaml",
"chars": 2522,
"preview": "<Window x:Class=\"EasyJob.Windows.AnswerDialog\"\r\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentatio"
},
{
"path": "EasyJob/Windows/AnswerDialog.xaml.cs",
"chars": 1975,
"preview": "using EasyJob.Serialization.AnswerDialog;\r\nusing System;\r\nusing System.Collections.Generic;\r\nusing System.Collections.O"
},
{
"path": "EasyJob/Windows/ColorTagsDialog.xaml",
"chars": 11651,
"preview": "<Window x:Class=\"EasyJob.Windows.ColorTagsDialog\"\r\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presenta"
},
{
"path": "EasyJob/Windows/ColorTagsDialog.xaml.cs",
"chars": 646,
"preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.Linq;\r\nusing System.Text;\r\nusing System.Threading.Tasks;"
},
{
"path": "EasyJob/Windows/ConfigurationDialog.xaml",
"chars": 35749,
"preview": "<Window x:Class=\"EasyJob.Windows.ConfigurationDialog\"\r\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/pres"
},
{
"path": "EasyJob/Windows/ConfigurationDialog.xaml.cs",
"chars": 8862,
"preview": "using EasyJob.Serialization;\r\nusing EasyJob.Utils;\r\nusing System;\r\nusing System.Collections.Generic;\r\nusing System.IO;\r"
},
{
"path": "EasyJob/Windows/EditActionButtonDialog.xaml",
"chars": 7699,
"preview": "<Window x:Class=\"EasyJob.Windows.EditActionButtonDialog\"\r\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/p"
},
{
"path": "EasyJob/Windows/EditActionButtonDialog.xaml.cs",
"chars": 4774,
"preview": "using EasyJob.Serialization;\r\nusing EasyJob.Serialization.AnswerDialog;\r\nusing EasyJob.TabItems;\r\nusing EasyJob.Utils;\r"
},
{
"path": "EasyJob/Windows/HelpDialog.xaml",
"chars": 3451,
"preview": "<Window x:Class=\"EasyJob.Windows.HelpDialog\"\r\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\""
},
{
"path": "EasyJob/Windows/HelpDialog.xaml.cs",
"chars": 2473,
"preview": "using EasyJob.Utils;\r\nusing System;\r\nusing System.Collections.Generic;\r\nusing System.IO;\r\nusing System.Linq;\r\nusing Sys"
},
{
"path": "EasyJob/Windows/NewTabDialog.xaml",
"chars": 1628,
"preview": "<Window x:Class=\"EasyJob.Windows.NewTabDialog\"\r\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentatio"
},
{
"path": "EasyJob/Windows/NewTabDialog.xaml.cs",
"chars": 3429,
"preview": "using EasyJob.Serialization;\r\nusing EasyJob.TabItems;\r\nusing EasyJob.Utils;\r\nusing Newtonsoft.Json;\r\nusing System;\r\nusi"
},
{
"path": "EasyJob/Windows/RenameTabDialog.xaml",
"chars": 1600,
"preview": "<Window x:Class=\"EasyJob.Windows.RenameTabDialog\"\r\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presenta"
},
{
"path": "EasyJob/Windows/RenameTabDialog.xaml.cs",
"chars": 1302,
"preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.Linq;\r\nusing System.Text;\r\nusing System.Threading.Tasks;"
},
{
"path": "EasyJob/Windows/ReorderActionButtonsDialog.xaml",
"chars": 2560,
"preview": "<Window x:Class=\"EasyJob.Windows.ReorderActionButtonsDialog\"\r\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xa"
},
{
"path": "EasyJob/Windows/ReorderActionButtonsDialog.xaml.cs",
"chars": 4643,
"preview": "using EasyJob.Serialization;\r\nusing EasyJob.TabItems;\r\nusing EasyJob.Utils;\r\nusing Newtonsoft.Json;\r\nusing System;\r\nusi"
},
{
"path": "EasyJob/Windows/ReorderTabsDialog.xaml",
"chars": 2499,
"preview": "<Window x:Class=\"EasyJob.Windows.ReorderTabsDialog\"\r\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presen"
},
{
"path": "EasyJob/Windows/ReorderTabsDialog.xaml.cs",
"chars": 3417,
"preview": "using EasyJob.Serialization;\r\nusing EasyJob.TabItems;\r\nusing EasyJob.Utils;\r\nusing Newtonsoft.Json;\r\nusing System;\r\nusi"
},
{
"path": "EasyJob/Windows/TroubleshootingWindow.xaml",
"chars": 4322,
"preview": "<Window x:Class=\"EasyJob.Windows.TroubleshootingWindow\"\r\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/pr"
},
{
"path": "EasyJob/Windows/TroubleshootingWindow.xaml.cs",
"chars": 5375,
"preview": "using EasyJob.Serialization;\r\nusing System;\r\nusing System.Collections.Generic;\r\nusing System.Diagnostics;\r\nusing System"
},
{
"path": "EasyJob/config.json",
"chars": 5632,
"preview": "{\r\n \"default_powershell_path\": \"C:\\\\Windows\\\\System32\\\\WindowsPowerShell\\\\v1.0\\\\powershell.exe\",\r\n \"default_cmd_path\":"
},
{
"path": "EasyJob.sln",
"chars": 2108,
"preview": "\r\nMicrosoft Visual Studio Solution File, Format Version 12.00\r\n# Visual Studio Version 16\r\nVisualStudioVersion = 16.0.3"
},
{
"path": "EasyJobPSTools/EasyJobPSTools.csproj",
"chars": 4780,
"preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\r\n<Project ToolsVersion=\"15.0\" xmlns=\"http://schemas.microsoft.com/developer/msbu"
},
{
"path": "EasyJobPSTools/EasyJobPSTools.psd1",
"chars": 1189,
"preview": "# Module manifest for module 'EasyJobPSTools'\r\n# Generated by: Akshin Mustafayev\r\n# Generated on: 10/8/2021\r\n\r\n@{\r\n\r\n "
},
{
"path": "EasyJobPSTools/EasyJobPSTools.psm1",
"chars": 3724,
"preview": "Add-Type -Path \"$PSScriptRoot\\ModernWpf.dll\"\r\nAdd-Type -Path \"$PSScriptRoot\\EasyJobPSTools.dll\"\r\n\r\nfunction Show-EJInpu"
},
{
"path": "EasyJobPSTools/EasyJobPSTools.sln",
"chars": 1131,
"preview": "\r\nMicrosoft Visual Studio Solution File, Format Version 12.00\r\n# Visual Studio Version 16\r\nVisualStudioVersion = 16.0.3"
},
{
"path": "EasyJobPSTools/Program.cs",
"chars": 1879,
"preview": "using EasyJobPSTools.Windows;\r\nusing System;\r\nusing System.Collections.Generic;\r\nusing System.Linq;\r\nusing System.Text;"
},
{
"path": "EasyJobPSTools/Properties/AssemblyInfo.cs",
"chars": 2496,
"preview": "using System.Reflection;\r\nusing System.Resources;\r\nusing System.Runtime.CompilerServices;\r\nusing System.Runtime.Interop"
},
{
"path": "EasyJobPSTools/Properties/Resources.Designer.cs",
"chars": 2855,
"preview": "//------------------------------------------------------------------------------\r\n// <auto-generated>\r\n// This code"
},
{
"path": "EasyJobPSTools/Properties/Resources.resx",
"chars": 5610,
"preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\r\n<root>\r\n <!-- \r\n Microsoft ResX Schema \r\n \r\n Version 2.0\r\n \r\n T"
},
{
"path": "EasyJobPSTools/Properties/Settings.Designer.cs",
"chars": 1096,
"preview": "//------------------------------------------------------------------------------\r\n// <auto-generated>\r\n// This code"
},
{
"path": "EasyJobPSTools/Properties/Settings.settings",
"chars": 199,
"preview": "<?xml version='1.0' encoding='utf-8'?>\r\n<SettingsFile xmlns=\"uri:settings\" CurrentProfile=\"(Default)\">\r\n <Profiles>\r\n "
},
{
"path": "EasyJobPSTools/Utils/CommonUtils.cs",
"chars": 698,
"preview": "using ModernWpf;\r\nusing ModernWpf.Controls;\r\nusing System.Windows;\r\n\r\nnamespace EasyJobPSTools.Utils\r\n{\r\n public cla"
},
{
"path": "EasyJobPSTools/Windows/ShowEJInputBox.xaml",
"chars": 1884,
"preview": "<Window x:Class=\"EasyJobPSTools.Windows.ShowEJInputBox\"\r\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/pr"
},
{
"path": "EasyJobPSTools/Windows/ShowEJInputBox.xaml.cs",
"chars": 2129,
"preview": "using EasyJobPSTools.Utils;\r\nusing System;\r\nusing System.Collections.Generic;\r\nusing System.Linq;\r\nusing System.Text;\r\n"
},
{
"path": "EasyJobPSTools/app.config",
"chars": 161,
"preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\r\n<configuration>\r\n<startup><supportedRuntime version=\"v4.0\" sku=\".NETFramework,Ve"
},
{
"path": "LICENSE.txt",
"chars": 34522,
"preview": " GNU AFFERO GENERAL PUBLIC LICENSE\n Version 3, 19 November 2007\n\n Copyright (C)"
},
{
"path": "README.md",
"chars": 10884,
"preview": "# <img src=\"assets/icon.png\" height=\"42\" width=\"42\"/> EasyJob\n\n<a href=\"https://img.shields.io/github/license/akshinmust"
},
{
"path": "WpfRichText/AttachedProperties/RichTextboxAssistant.cs",
"chars": 5017,
"preview": "using System;\nusing System.Collections.Generic;\nusing System.Text;\nusing System.Windows;\nusing System.Windows.Documents"
},
{
"path": "WpfRichText/Commands/CommandReference.cs",
"chars": 2475,
"preview": "using System;\nusing System.Windows;\nusing System.Windows.Input;\n\nnamespace WpfRichText\n{\n /// <summary>\n /// This"
},
{
"path": "WpfRichText/Commands/DelegateCommand.cs",
"chars": 13454,
"preview": "using System;\nusing System.Collections.Generic;\nusing System.Windows;\nusing System.Windows.Input;\n\nnamespace WpfRichTex"
},
{
"path": "WpfRichText/Controls/RichTextEditor.xaml",
"chars": 1068,
"preview": "<UserControl\n\t\t\t xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n\t\t\t xmlns:x=\"http://schemas.microsof"
},
{
"path": "WpfRichText/Controls/RichTextEditor.xaml.cs",
"chars": 1069,
"preview": "using System;\nusing System.Collections.Generic;\nusing System.Collections.ObjectModel;\nusing System.Globalization;\nusing"
},
{
"path": "WpfRichText/WpfRichText.csproj",
"chars": 1251,
"preview": "<Project Sdk=\"Microsoft.NET.Sdk\">\r\n <PropertyGroup>\r\n <TargetFramework>net5.0-windows</TargetFramework>\r\n <Outpu"
},
{
"path": "WpfRichText/WpfRichText.sln",
"chars": 1817,
"preview": "\r\nMicrosoft Visual Studio Solution File, Format Version 12.00\r\n# Visual Studio Version 16\r\nVisualStudioVersion = 16.0.3"
},
{
"path": "WpfRichText/XamlToHtmlParser/HtmlCssParser.cs",
"chars": 47516,
"preview": "//---------------------------------------------------------------------------\r\n// \r\n// File: HtmlXamlConverter.cs\r\n//\r\n/"
},
{
"path": "WpfRichText/XamlToHtmlParser/HtmlFromXamlConverter.cs",
"chars": 22483,
"preview": "//---------------------------------------------------------------------------\n// \n// File: HtmlFromXamlConverter.cs\n//\n/"
},
{
"path": "WpfRichText/XamlToHtmlParser/HtmlLexicalAnalyzer.cs",
"chars": 31623,
"preview": "//---------------------------------------------------------------------------\n// \n// File: HtmlLexicalAnalyzer.cs\n//\n// "
},
{
"path": "WpfRichText/XamlToHtmlParser/HtmlParser.cs",
"chars": 28125,
"preview": "//---------------------------------------------------------------------------\n// \n// File: HtmlParser.cs\n//\n// Copyright"
},
{
"path": "WpfRichText/XamlToHtmlParser/HtmlSchema.cs",
"chars": 35954,
"preview": "//---------------------------------------------------------------------------\n// \n// File: HtmlSchema.cs\n//\n// Copyright"
},
{
"path": "WpfRichText/XamlToHtmlParser/HtmlToXamlConverter.cs",
"chars": 127876,
"preview": "//---------------------------------------------------------------------------\n// \n// File: HtmlXamlConverter.cs\n//\n// Co"
},
{
"path": "WpfRichText/XamlToHtmlParser/HtmlTokenType.cs",
"chars": 749,
"preview": "//---------------------------------------------------------------------------\n// \n// File: HtmlTokenType.cs\n//\n// Copyri"
}
]
About this extraction
This page contains the full source code of the akshinmustafayev/EasyJob GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 80 files (670.2 KB), approximately 142.7k tokens, and a symbol index with 370 extracted functions, classes, methods, constants, and types. Use this with OpenClaw, Claude, ChatGPT, Cursor, Windsurf, or any other AI tool that accepts text input. You can copy the full output to your clipboard or download it as a .txt file.
Extracted by GitExtract — free GitHub repo to text converter for AI. Built by Nikandr Surkov.