Full Code of li-zheng-hao/StickyNotes for AI

master 563523cc3526
129 files
428.4 KB
99.9k tokens
Showing preview only (461K chars total). The displayed content is truncated. Use the JSON API for full output.
Repository: li-zheng-hao/StickyNotes
Branch: master
Commit: 563523cc3526
Files: 129
Total size: 428.4 KB

Directory structure:
gitextract_uf0toj3p/

├── .gitattributes
├── .gitignore
├── .travis.yml
├── Common/
│   ├── AdministratorUtil.cs
│   ├── ComUtil.cs
│   ├── Common.csproj
│   ├── DownloadFileHelper.cs
│   ├── FileHelper.cs
│   ├── FodyWeavers.xml
│   ├── FodyWeavers.xsd
│   ├── HttpHelper.cs
│   ├── JsonHelper.cs
│   ├── Lang/
│   │   ├── LangBase.cs
│   │   ├── LangCN.cs
│   │   ├── LangEN.cs
│   │   ├── LangExtension.cs
│   │   └── Language.cs
│   ├── LangHelper.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── WindowHelper.cs
│   ├── packages.config
│   ├── version.Designer.cs
│   └── version.json
├── Contract/
│   ├── Contract.csproj
│   ├── ProgramData.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   └── SoftwareUpdate.cs
├── DB/
│   ├── App.config
│   ├── Config.cs
│   ├── DB.csproj
│   ├── Init.cs
│   ├── ProgramDB.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── Repository.cs
│   ├── Versions.cs
│   ├── WindowsDataDB.cs
│   └── packages.config
├── LICENSE
├── README.md
├── StickyNotes/
│   ├── App.config
│   ├── App.xaml
│   ├── App.xaml.cs
│   ├── Converter/
│   │   ├── DateTimeToVisibilityConverter.cs
│   │   ├── DeleteWindowMessageConverter.cs
│   │   ├── LanguageConverter.cs
│   │   ├── ShowAllHotKeyConverter.cs
│   │   ├── ThemeConverter.cs
│   │   └── boolToVisibilityConverter.cs
│   ├── Data/
│   │   ├── ConstData.cs
│   │   ├── ProgramData.cs
│   │   └── WindowsData.cs
│   ├── FodyWeavers.xml
│   ├── FodyWeavers.xsd
│   ├── Properties/
│   │   ├── Annotations.cs
│   │   ├── AssemblyInfo.cs
│   │   ├── Resources.Designer.cs
│   │   ├── Resources.resx
│   │   ├── Settings.Designer.cs
│   │   └── Settings.settings
│   ├── StickyNotes.csproj
│   ├── Style/
│   │   ├── Color.xaml
│   │   ├── Control.xaml
│   │   ├── Font.xaml
│   │   ├── Label.xaml
│   │   ├── Languages/
│   │   │   ├── Lan-cn.xaml
│   │   │   └── Lan-en.xaml
│   │   ├── Themes/
│   │   │   ├── 乌云灰.xaml
│   │   │   ├── 冷灰.xaml
│   │   │   ├── 甘蓝.xaml
│   │   │   ├── 田园褐.xaml
│   │   │   └── 石材灰.xaml
│   │   └── Window.xaml
│   ├── UserControl/
│   │   ├── CardItem.xaml
│   │   ├── CardItem.xaml.cs
│   │   ├── CustomWarningDialog.xaml
│   │   └── CustomWarningDialog.xaml.cs
│   ├── Utils/
│   │   ├── DataHelper.cs
│   │   ├── HotKeyUtil/
│   │   │   ├── HotKey.cs
│   │   │   ├── HotKeyHandler.cs
│   │   │   ├── HotKeyManager.cs
│   │   │   ├── HotKeySetting.cs
│   │   │   ├── HotkeyEventArgs.cs
│   │   │   └── NativeMethods.cs
│   │   ├── HttpHelper.cs
│   │   ├── LanguageManager.cs
│   │   ├── Logger.cs
│   │   ├── Messages/
│   │   │   ├── ChangeWindowMessage.cs
│   │   │   └── SaveMessage.cs
│   │   ├── SystemTray.cs
│   │   ├── ThemeAssist.cs
│   │   ├── TimerUtil.cs
│   │   ├── UpdateHelper.cs
│   │   ├── WindowHide.cs
│   │   └── WindowsManager.cs
│   ├── View/
│   │   ├── AboutWindow.xaml
│   │   ├── AboutWindow.xaml.cs
│   │   ├── ListWindow.xaml
│   │   ├── ListWindow.xaml.cs
│   │   ├── MainWindow.xaml
│   │   ├── MainWindow.xaml.cs
│   │   ├── SettingWindow-DESKTOP-HA5D6OQ.xaml
│   │   ├── SettingWindow.xaml
│   │   ├── SettingWindow.xaml-DESKTOP-HA5D6OQ.cs
│   │   └── SettingWindow.xaml.cs
│   └── ViewModel/
│       ├── ListWindowViewModel.cs
│       ├── MainViewModel-DESKTOP-HA5D6OQ.cs
│       ├── MainViewModel.cs
│       ├── SettingViewModel-DESKTOP-HA5D6OQ.cs
│       ├── SettingViewModel.cs
│       └── ViewModelLocator.cs
├── StickyNotes.sln
├── StikyNotes.sln.DotSettings
├── UpdateApp/
│   ├── App.config
│   ├── App.xaml
│   ├── App.xaml.cs
│   ├── FodyWeavers.xml
│   ├── FodyWeavers.xsd
│   ├── MainWindow.xaml
│   ├── MainWindow.xaml.cs
│   ├── MainWindowViewModel.cs
│   ├── Properties/
│   │   ├── AssemblyInfo.cs
│   │   ├── Resources.Designer.cs
│   │   ├── Resources.resx
│   │   ├── Settings.Designer.cs
│   │   └── Settings.settings
│   ├── UpdateApp.csproj
│   └── packages.config
├── version.json
└── 更新日志.md

================================================
FILE CONTENTS
================================================

================================================
FILE: .gitattributes
================================================
###############################################################################
# Set default behavior to automatically normalize line endings.
###############################################################################
* text=auto

###############################################################################
# Set default behavior for command prompt diff.
#
# This is need for earlier builds of msysgit that does not have it on by
# default for csharp files.
# Note: This is only used by command line
###############################################################################
#*.cs     diff=csharp

###############################################################################
# Set the merge driver for project and solution files
#
# Merging from the command prompt will add diff markers to the files if there
# are conflicts (Merging from VS is not affected by the settings below, in VS
# the diff markers are never inserted). Diff markers may cause the following 
# file extensions to fail to load in VS. An alternative would be to treat
# these files as binary and thus will always conflict and require user
# intervention with every merge. To do so, just uncomment the entries below
###############################################################################
#*.sln       merge=binary
#*.csproj    merge=binary
#*.vbproj    merge=binary
#*.vcxproj   merge=binary
#*.vcproj    merge=binary
#*.dbproj    merge=binary
#*.fsproj    merge=binary
#*.lsproj    merge=binary
#*.wixproj   merge=binary
#*.modelproj merge=binary
#*.sqlproj   merge=binary
#*.wwaproj   merge=binary

###############################################################################
# behavior for image files
#
# image files are treated as binary by default.
###############################################################################
#*.jpg   binary
#*.png   binary
#*.gif   binary

###############################################################################
# diff behavior for common document formats
# 
# Convert binary document formats to text before diffing them. This feature
# is only available from the command line. Turn it on by uncommenting the 
# entries below.
###############################################################################
#*.doc   diff=astextplain
#*.DOC   diff=astextplain
#*.docx  diff=astextplain
#*.DOCX  diff=astextplain
#*.dot   diff=astextplain
#*.DOT   diff=astextplain
#*.pdf   diff=astextplain
#*.PDF   diff=astextplain
#*.rtf   diff=astextplain
#*.RTF   diff=astextplain


================================================
FILE: .gitignore
================================================
## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons.

# User-specific files
*.suo
*.user
*.userosscache
*.sln.docstates

# User-specific files (MonoDevelop/Xamarin Studio)
*.userprefs

# Build results
[Dd]ebug/
[Dd]ebugPublic/
[Rr]elease/
[Rr]eleases/
x64/
x86/
bld/
[Bb]in/
[Oo]bj/
[Ll]og/

# Visual Studio 2015 cache/options directory
.vs/
# Uncomment if you have tasks that create the project's static files in wwwroot
#wwwroot/

# MSTest test Results
[Tt]est[Rr]esult*/
[Bb]uild[Ll]og.*

# NUNIT
*.VisualState.xml
TestResult.xml

# Build Results of an ATL Project
[Dd]ebugPS/
[Rr]eleasePS/
dlldata.c

# DNX
project.lock.json
project.fragment.lock.json
artifacts/

*_i.c
*_p.c
*_i.h
*.ilk
*.meta
*.obj
*.pch
*.pdb
*.pgc
*.pgd
*.rsp
*.sbr
*.tlb
*.tli
*.tlh
*.tmp
*.tmp_proj
*.log
*.vspscc
*.vssscc
.builds
*.pidb
*.svclog
*.scc

# Chutzpah Test files
_Chutzpah*

# Visual C++ cache files
ipch/
*.aps
*.ncb
*.opendb
*.opensdf
*.sdf
*.cachefile
*.VC.db
*.VC.VC.opendb

# Visual Studio profiler
*.psess
*.vsp
*.vspx
*.sap

# TFS 2012 Local Workspace
$tf/

# Guidance Automation Toolkit
*.gpState

# ReSharper is a .NET coding add-in
_ReSharper*/
*.[Rr]e[Ss]harper
*.DotSettings.user

# JustCode is a .NET coding add-in
.JustCode

# TeamCity is a build add-in
_TeamCity*

# DotCover is a Code Coverage Tool
*.dotCover

# NCrunch
_NCrunch_*
.*crunch*.local.xml
nCrunchTemp_*

# MightyMoose
*.mm.*
AutoTest.Net/

# Web workbench (sass)
.sass-cache/

# Installshield output folder
[Ee]xpress/

# DocProject is a documentation generator add-in
DocProject/buildhelp/
DocProject/Help/*.HxT
DocProject/Help/*.HxC
DocProject/Help/*.hhc
DocProject/Help/*.hhk
DocProject/Help/*.hhp
DocProject/Help/Html2
DocProject/Help/html

# Click-Once directory
publish/

# Publish Web Output
*.[Pp]ublish.xml
*.azurePubxml
# TODO: Comment the next line if you want to checkin your web deploy settings
# but database connection strings (with potential passwords) will be unencrypted
#*.pubxml
*.publishproj

# Microsoft Azure Web App publish settings. Comment the next line if you want to
# checkin your Azure Web App publish settings, but sensitive information contained
# in these scripts will be unencrypted
PublishScripts/

# NuGet Packages
*.nupkg
# The packages folder can be ignored because of Package Restore
**/packages/*
# except build/, which is used as an MSBuild target.
!**/packages/build/
# Uncomment if necessary however generally it will be regenerated when needed
#!**/packages/repositories.config
# NuGet v3's project.json files produces more ignoreable files
*.nuget.props
*.nuget.targets

# Microsoft Azure Build Output
csx/
*.build.csdef

# Microsoft Azure Emulator
ecf/
rcf/

# Windows Store app package directories and files
AppPackages/
BundleArtifacts/
Package.StoreAssociation.xml
_pkginfo.txt

# Visual Studio cache files
# files ending in .cache can be ignored
*.[Cc]ache
# but keep track of directories ending in .cache
!*.[Cc]ache/

# Others
ClientBin/
~$*
*~
*.dbmdl
*.dbproj.schemaview
*.jfm
*.pfx
*.publishsettings
node_modules/
orleans.codegen.cs

# Since there are multiple workflows, uncomment next line to ignore bower_components
# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622)
#bower_components/

# RIA/Silverlight projects
Generated_Code/

# Backup & report files from converting an old project file
# to a newer Visual Studio version. Backup files are not needed,
# because we have git ;-)
_UpgradeReport_Files/
Backup*/
UpgradeLog*.XML
UpgradeLog*.htm

# SQL Server files
*.mdf
*.ldf

# Business Intelligence projects
*.rdl.data
*.bim.layout
*.bim_*.settings

# Microsoft Fakes
FakesAssemblies/

# GhostDoc plugin setting file
*.GhostDoc.xml

# Node.js Tools for Visual Studio
.ntvs_analysis.dat

# Visual Studio 6 build log
*.plg

# Visual Studio 6 workspace options file
*.opt

# Visual Studio LightSwitch build output
**/*.HTMLClient/GeneratedArtifacts
**/*.DesktopClient/GeneratedArtifacts
**/*.DesktopClient/ModelManifest.xml
**/*.Server/GeneratedArtifacts
**/*.Server/ModelManifest.xml
_Pvt_Extensions

# Paket dependency manager
.paket/paket.exe
paket-files/

# FAKE - F# Make
.fake/

# JetBrains Rider
.idea/
*.sln.iml

# CodeRush
.cr/

# Python Tools for Visual Studio (PTVS)
__pycache__/
*.pyc
Build/
Buildupdate/


================================================
FILE: .travis.yml
================================================
language: csharp
solution: StikyNotes.sln

================================================
FILE: Common/AdministratorUtil.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Security.Principal;
using System.Management;
using System.Diagnostics;
using System.Reflection;
using System.Windows;

namespace Common
{
    public class AdministratorUtil
    {
        public static void RunAsAdmin(string argment="")
        {
            //Put this code in the main entry point for the application
            // Check if user is NOT admin 
            if (!IsRunningAsAdministrator())
            {
                // Setting up start info of the new process of the same application
                ProcessStartInfo processStartInfo = new ProcessStartInfo(Assembly.GetEntryAssembly().CodeBase);

                // Using operating shell and setting the ProcessStartInfo.Verb to “runas” will let it run as admin
                processStartInfo.UseShellExecute = true;
                processStartInfo.Verb = "runas";
                processStartInfo.Arguments = argment;
                // Start the application as new process
                Process.Start(processStartInfo);

            }

        }


        /// <summary>
        /// Function that check's if current user is in Aministrator role
        /// </summary>
        /// <returns></returns>
        private static bool IsRunningAsAdministrator()
        {
            // Get current Windows user
            WindowsIdentity windowsIdentity = WindowsIdentity.GetCurrent();

            // Get current Windows user principal
            WindowsPrincipal windowsPrincipal = new WindowsPrincipal(windowsIdentity);

            // Return TRUE if user is in role "Administrator"
            return windowsPrincipal.IsInRole(WindowsBuiltInRole.Administrator);
        }

        // kill process by name
        public static void KillProcess(string name)
        {
            foreach (Process clsProcess in Process.GetProcesses())
            {
                if (clsProcess.ProcessName.Contains(name))
                {
                    clsProcess.Kill();
                }
            }
        }
    }
}


================================================
FILE: Common/ComUtil.cs
================================================
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;

namespace Common
{
    public class ComUtil
    {
        /// <summary>
        /// get random guid string
        /// </summary>
        /// <returns></returns>
        public static string GetRandomGuid()
        {
            return Guid.NewGuid().ToString();
        }

        // 获取目录的上一级
        public static string GetParentDirectory(string path)
        {
            return System.IO.Path.GetDirectoryName(path);
        }
        public static string GetCurrentExecDirectory()
        {
            return Path.GetDirectoryName(Process.GetCurrentProcess().MainModule.FileName);
        }
    }
}


================================================
FILE: Common/Common.csproj
================================================
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <Import Project="..\packages\PropertyChanged.Fody.3.4.1\build\PropertyChanged.Fody.props" Condition="Exists('..\packages\PropertyChanged.Fody.3.4.1\build\PropertyChanged.Fody.props')" />
  <Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
  <PropertyGroup>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
    <ProjectGuid>{EB437726-8891-46DE-9D88-271242DB82BC}</ProjectGuid>
    <OutputType>Library</OutputType>
    <AppDesignerFolder>Properties</AppDesignerFolder>
    <RootNamespace>Common</RootNamespace>
    <AssemblyName>Common</AssemblyName>
    <TargetFrameworkVersion>v4.6</TargetFrameworkVersion>
    <FileAlignment>512</FileAlignment>
    <Deterministic>true</Deterministic>
    <NuGetPackageImportStamp>
    </NuGetPackageImportStamp>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
    <DebugSymbols>true</DebugSymbols>
    <DebugType>full</DebugType>
    <Optimize>false</Optimize>
    <OutputPath>bin\Debug\</OutputPath>
    <DefineConstants>DEBUG;TRACE</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
    <DebugType>pdbonly</DebugType>
    <Optimize>true</Optimize>
    <OutputPath>bin\Release\</OutputPath>
    <DefineConstants>TRACE</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
  </PropertyGroup>
  <ItemGroup>
    <Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
      <HintPath>..\packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
    </Reference>
    <Reference Include="PresentationFramework" />
    <Reference Include="PropertyChanged, Version=3.4.1.0, Culture=neutral, PublicKeyToken=ee3ee20bcf148ddd, processorArchitecture=MSIL">
      <HintPath>..\packages\PropertyChanged.Fody.3.4.1\lib\net40\PropertyChanged.dll</HintPath>
    </Reference>
    <Reference Include="RestSharp, Version=106.15.0.0, Culture=neutral, PublicKeyToken=598062e77f915f75, processorArchitecture=MSIL">
      <HintPath>..\packages\RestSharp.106.15.0\lib\net452\RestSharp.dll</HintPath>
    </Reference>
    <Reference Include="System" />
    <Reference Include="System.Core" />
    <Reference Include="System.IO.Compression" />
    <Reference Include="System.IO.Compression.FileSystem" />
    <Reference Include="System.Web" />
    <Reference Include="System.Windows.Forms" />
    <Reference Include="System.Xaml" />
    <Reference Include="System.Xml.Linq" />
    <Reference Include="System.Data.DataSetExtensions" />
    <Reference Include="Microsoft.CSharp" />
    <Reference Include="System.Data" />
    <Reference Include="System.Net.Http" />
    <Reference Include="System.Xml" />
  </ItemGroup>
  <ItemGroup>
    <Compile Include="AdministratorUtil.cs" />
    <Compile Include="JsonHelper.cs" />
    <Compile Include="ComUtil.cs" />
    <Compile Include="DownloadFileHelper.cs" />
    <Compile Include="FileHelper.cs" />
    <Compile Include="HttpHelper.cs" />
    <Compile Include="LangHelper.cs" />
    <Compile Include="Lang\LangBase.cs" />
    <Compile Include="Lang\LangCN.cs" />
    <Compile Include="Lang\LangEN.cs" />
    <Compile Include="Lang\LangExtension.cs" />
    <Compile Include="Lang\Language.cs" />
    <Compile Include="Properties\AssemblyInfo.cs" />
    <Compile Include="WindowHelper.cs" />
  </ItemGroup>
  <ItemGroup>
    <None Include="packages.config" />
    <Content Include="version.json">
      <CopyToOutputDirectory>Always</CopyToOutputDirectory>
    </Content>
  </ItemGroup>
  <ItemGroup>
    <Resource Include="FodyWeavers.xml" />
  </ItemGroup>
  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
  <Import Project="..\packages\Fody.6.6.2\build\Fody.targets" Condition="Exists('..\packages\Fody.6.6.2\build\Fody.targets')" />
  <Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
    <PropertyGroup>
      <ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them.  For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
    </PropertyGroup>
    <Error Condition="!Exists('..\packages\Fody.6.6.2\build\Fody.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\Fody.6.6.2\build\Fody.targets'))" />
    <Error Condition="!Exists('..\packages\PropertyChanged.Fody.3.4.1\build\PropertyChanged.Fody.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\PropertyChanged.Fody.3.4.1\build\PropertyChanged.Fody.props'))" />
  </Target>
</Project>

================================================
FILE: Common/DownloadFileHelper.cs
================================================
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Net;
using System.Text;
using System.Threading.Tasks;

namespace Common
{
    public class DownloadFileHelper
    {
        const int bytebuff = 1024;
        const int ReadWriteTimeOut = 2 * 1000;//超时等待时间
        const int TimeOutWait = 5 * 1000;//超时等待时间
        const int MaxTryTime = 12;

        private double totalSize, curReadSize, speed;
        private int proc, remainTime;
        private int totalTime = 0;

        private bool downLoadWorking = false;

        private string StrFileName = "";
        private string StrUrl = "";

        private string outMsg = "";

        private string fileName = string.Empty;
        /// <summary>
        /// 下载文件
        /// </summary>
        /// <param name="url">地址</param>
        /// <param name="savePath">完整的路径包含文件名</param>
        public DownloadFileHelper(string url, string savePath)
        {
            this.StrUrl = url;
            this.StrFileName = savePath;
            this.fileName = Path.GetFileName(savePath);
        }
        /// <summary>
        /// 下载进度更新
        /// </summary>
        /// <param name="totalNum">下载文件总大小</param>
        /// <param name="num">已下载文件大小</param>
        /// <param name="progress">下载进度百分比</param>
        /// <param name="speed">下载速度</param>
        /// <param name="remainTime">剩余下载时间</param>
        public delegate void delDownFileHandler(string totalNum, string num, int progress, string speed, string remainTime, string outMsg, string fileName);
        public event delDownFileHandler ProgressChanged;

        // 文件下载完成
        public event Action ProcessCompleted;

        public System.Windows.Forms.Timer timer;

        public void Init()
        {
            timer = new System.Windows.Forms.Timer();
            timer.Interval = 50;
            timer.Tick -= TickEventHandler;
            timer.Tick += TickEventHandler;
            timer.Enabled = true;
            downLoadWorking = true;
        }
        /// <summary>
        /// 获取文件大小
        /// </summary>
        /// <param name="size"></param>
        /// <returns></returns>
        private string GetSize(double size)
        {
            String[] units = new String[] { "B", "KB", "MB", "GB", "TB", "PB" };
            double mod = 1024.0;
            int i = 0;
            while (size >= mod)
            {
                size /= mod;
                i++;
            }
            return Math.Round(size) + units[i];


        }
        /// <summary>
        /// 获取时间
        /// </summary>
        /// <param name="second"></param>
        /// <returns></returns>
        private string GetTime(int second)
        {
            return new DateTime(1970, 01, 01, 00, 00, 00).AddSeconds(second).ToString("HH:mm:ss");
        }

        /// <summary>
        /// 开始下载文件(同步)  支持断点续传
        /// </summary>
        private void DownloadFile()
        {
            totalSize = GetFileContentLength(StrUrl);
            System.IO.FileStream fs=null;
            try
            {
                //打开上次下载的文件或新建文件
                long lStartPos = 0;
                
                if (System.IO.File.Exists(StrFileName))
                {
                    fs = System.IO.File.OpenWrite(StrFileName);
                    lStartPos = fs.Length;
                    fs.Seek(lStartPos, System.IO.SeekOrigin.Current);   //移动文件流中的当前指针
                }
                else
                {
                    fs = new System.IO.FileStream(StrFileName, System.IO.FileMode.Create);
                    lStartPos = 0;
                }

                curReadSize = lStartPos;

                if (curReadSize == totalSize)
                {
                    outMsg = "文件已下载!";
                    timer.Enabled = false;
                    timer.Stop();
                    fs?.Close();
                    ProcessCompleted?.Invoke();
                    
                    return;
                }

                //打开网络连接
                try
                {
                    System.Net.HttpWebRequest request = (System.Net.HttpWebRequest)System.Net.HttpWebRequest.Create(StrUrl);
                    if (lStartPos > 0)
                        request.AddRange((int)lStartPos);    //设置Range值

                    //向服务器请求,获得服务器回应数据流
                    System.IO.Stream ns = request.GetResponse().GetResponseStream();
                    byte[] nbytes = new byte[bytebuff];
                    int nReadSize = 0;
                    proc = 0;

                    do
                    {

                        nReadSize = ns.Read(nbytes, 0, bytebuff);
                        fs.Write(nbytes, 0, nReadSize);

                        //已下载大小
                        curReadSize += nReadSize;
                        //进度百分比
                        proc = (int)((curReadSize / totalSize) * 100);
                        Console.WriteLine(proc + "进度条");
                        //下载速度
                        speed = (curReadSize / totalTime) * 10;
                        //剩余时间
                        remainTime = (int)((totalSize / speed) - (totalTime / 10));

                        if (downLoadWorking == false)
                            break;

                    } while (nReadSize > 0);

                    fs.Close();
                    ns.Close();

                    if (curReadSize == totalSize)
                    {
                        outMsg = "下载完成!";
                        ProcessCompleted?.Invoke();
                        downLoadWorking = false;
                    }
                }
                catch (Exception ex)
                {
                    outMsg = string.Format("下载失败:{0}", ex.ToString());
                }
         
            }finally
            {
                fs?.Close();
                timer.Enabled = false;
                timer.Stop();

            }

        }
        /// <summary>
        /// 暂停下载
        /// </summary>
        public void DownLoadPause()
        {
            outMsg = "下载已暂停";
            downLoadWorking = false;
            timer.Stop();
            
        }
        /// <summary>
        /// 继续下载
        /// </summary>
        public void DownLoadContinue()
        {
            outMsg = "正在下载";
            downLoadWorking = true;
            DownLoadStart();
        }

        /// <summary>
        /// 开始下载
        /// </summary>
        public void DownLoadStart()
        {
            Init();
            Task.Run(() =>
            {
                DownloadFile();
            });
        }

        /// <summary>
        /// 定时器方法
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void TickEventHandler(object sender, EventArgs e)
        {
            ProgressChanged?.Invoke(GetSize(totalSize),
                                GetSize(curReadSize),
                                proc,
                                string.Format("{0}/s", GetSize(speed)),
                                GetTime(remainTime),
                                outMsg,
                                fileName
                                );
            if (downLoadWorking == true)
            {
                totalTime++;
            }
        }

        /// <summary>
        /// 获取下载文件长度
        /// </summary>
        /// <param name="url"></param>
        /// <returns></returns>
        public long GetFileContentLength(string url)
        {
            HttpWebRequest request = null;
            try
            {
                request = (HttpWebRequest)HttpWebRequest.Create(url);
                //request.Timeout = TimeOutWait;
                //request.ReadWriteTimeout = ReadWriteTimeOut;
                //向服务器请求,获得服务器回应数据流
                WebResponse respone = request.GetResponse();
                request.Abort();
                return respone.ContentLength;
            }
            catch (WebException e)
            {
                if (request != null)
                    request.Abort();
                return 0;
            }
        }
    }

}


================================================
FILE: Common/FileHelper.cs
================================================
using System;
using System.Collections.Generic;
using System.IO;
using System.IO.Compression;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Common
{
    public class FileHelper
    {
        /// <summary>
        /// 获取文件名
        /// </summary>
        /// <param name="filePath"></param>
        /// <returns></returns>
        public static string GetFileName(string filePath)
        {
            return Path.GetFileName(filePath);
        }

        /// <summary>
        /// 解压缩zip文件 然后解压缩到对应的
        /// </summary>
        /// <param name="zipFile"></param>
        /// <param name="outputFolder"></param>
        /// <exception cref="FileNotFoundException"></exception>
        public static void Decompress(string zipFile, string outputFolder)
        {
            if (!File.Exists(zipFile))
            {
                throw new FileNotFoundException("The zip file was not found.", zipFile);
            }
            if (!Directory.Exists(outputFolder))
            {
                
                Directory.CreateDirectory(outputFolder);
            }
            using (ZipArchive archive = ZipFile.OpenRead(zipFile))
            {
                foreach (ZipArchiveEntry entry in archive.Entries)
                {
                    if (entry.Name == "") continue;
                    entry.ExtractToFile(Path.Combine(outputFolder, entry.Name), true);
                }
            }
        }
    }
}


================================================
FILE: Common/FodyWeavers.xml
================================================
<?xml version="1.0" encoding="utf-8"?>
<Weavers xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="FodyWeavers.xsd">
  <PropertyChanged />
</Weavers>

================================================
FILE: Common/FodyWeavers.xsd
================================================
<?xml version="1.0" encoding="utf-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
  <!-- This file was generated by Fody. Manual changes to this file will be lost when your project is rebuilt. -->
  <xs:element name="Weavers">
    <xs:complexType>
      <xs:all>
        <xs:element name="PropertyChanged" minOccurs="0" maxOccurs="1">
          <xs:complexType>
            <xs:attribute name="InjectOnPropertyNameChanged" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>Used to control if the On_PropertyName_Changed feature is enabled.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="TriggerDependentProperties" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>Used to control if the Dependent properties feature is enabled.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="EnableIsChangedProperty" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>Used to control if the IsChanged property feature is enabled.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="EventInvokerNames" type="xs:string">
              <xs:annotation>
                <xs:documentation>Used to change the name of the method that fires the notify event. This is a string that accepts multiple values in a comma separated form.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="CheckForEquality" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>Used to control if equality checks should be inserted. If false, equality checking will be disabled for the project.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="CheckForEqualityUsingBaseEquals" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>Used to control if equality checks should use the Equals method resolved from the base class.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="UseStaticEqualsFromBase" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>Used to control if equality checks should use the static Equals method resolved from the base class.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="SuppressWarnings" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>Used to turn off build warnings from this weaver.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="SuppressOnPropertyNameChangedWarning" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>Used to turn off build warnings about mismatched On_PropertyName_Changed methods.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
          </xs:complexType>
        </xs:element>
      </xs:all>
      <xs:attribute name="VerifyAssembly" type="xs:boolean">
        <xs:annotation>
          <xs:documentation>'true' to run assembly verification (PEVerify) on the target assembly after all weavers have been executed.</xs:documentation>
        </xs:annotation>
      </xs:attribute>
      <xs:attribute name="VerifyIgnoreCodes" type="xs:string">
        <xs:annotation>
          <xs:documentation>A comma-separated list of error codes that can be safely ignored in assembly verification.</xs:documentation>
        </xs:annotation>
      </xs:attribute>
      <xs:attribute name="GenerateXsd" type="xs:boolean">
        <xs:annotation>
          <xs:documentation>'false' to turn off automatic generation of the XML Schema file.</xs:documentation>
        </xs:annotation>
      </xs:attribute>
    </xs:complexType>
  </xs:element>
</xs:schema>

================================================
FILE: Common/HttpHelper.cs
================================================
using Newtonsoft.Json;
using RestSharp;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;

namespace Common
{
    public class HttpHelper
    {
        public static string BaseUrl ;
        public static ResponseResult HttpGet(string url, string[] paramsName=null, object[]paramsVal=null)
        {
            var client = new RestClient(BaseUrl);
            var request = new RestRequest(url);
            if (paramsName.Length != paramsVal.Length)
                throw new Exception("参数个数不一致");
            if (paramsName != null)
            {
                for (int i = 0; i < paramsName.Length; i++)
                {
                    request.AddParameter(paramsName[i], paramsVal[i]);
                }
            }
            var response = client.Get<ResponseResult>(request);
            return response.Data;
        }
        // http download file from url
        public static void HttpDownloadFile(string url, string fileName,bool useBaseUrl=false)
        {
            RestClient client;
            if (useBaseUrl == false)
            {
                client = new RestClient();
            }
            else
            {
                client = new RestClient(BaseUrl);
            }
            var request = new RestRequest(url);
            var response = client.Get(request);
            var file = new System.IO.FileInfo(fileName);
            file.Directory.Create();
            System.IO.File.WriteAllBytes(fileName, response.RawBytes);
        }

        // dynamic to class object
        public static T DynamicToObject<T>(dynamic dynamicObject)
        {
            return JsonConvert.DeserializeObject<T>(JsonConvert.SerializeObject(dynamicObject));
        }
    }

    public class ResponseResult
    {
        public bool success { get; set; }
        public string message { get; set; }
        public dynamic data { get; set; }
        public int code { get; set; }
    }

    
}


================================================
FILE: Common/JsonHelper.cs
================================================
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Common
{
    public class Version
    {
        public StickyNotesVersion StickyNotesVersion { get; set; }
        public UpdateAppVersion UpdateAppVersion { get; set; }
    }
    public class StickyNotesVersion
    {
        public int MajorVersionNumber { get; set; }
        public int MinorVersionNumber { get; set; }
        public int RevisionNumebr { get; set; }
    }
    public class UpdateAppVersion
    {
        public int MajorVersionNumber { get; set; }
        public int MinorVersionNumber { get; set; }
        public int RevisionNumebr { get; set; }
    }
    public class JsonHelper
    {
        public static Version ReadVersionFromFile(string fileDir, string versionFileName)
        {
            var filePath = Path.Combine(fileDir, versionFileName);
            var json = File.ReadAllText(filePath);
            var version = Newtonsoft.Json.JsonConvert.DeserializeObject<Version>(json);
            return version;
        }
        public  static void WriteVersionToFile(Version version,string fileDir,string versionFileName)
        {
            var filePath = Path.Combine(fileDir, versionFileName);
            var json = Newtonsoft.Json.JsonConvert.SerializeObject(version);
            File.WriteAllText(filePath, json);
        }
    }
}


================================================
FILE: Common/Lang/LangBase.cs
================================================
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Common.Lang
{   public abstract class LangBase:INotifyPropertyChanged
    {
        public abstract string StartUpArgsError { get; set; }
        /// <summary>
        /// 更新窗体的标题
        /// </summary>
        public abstract string UpdateWindowTitle { get; set; }
        /// <summary>
        /// 确定更新
        /// </summary>
        public abstract string ConfirmUpdate { get; set; }
        /// <summary>
        /// 关闭更新
        /// </summary>
        public abstract string CloseUpdate { get; set; }
        /// <summary>
        /// 窗体菜单栏标题
        /// </summary>

        public abstract string UpdateWindowLeftTopTitle { get; set; }

        public event PropertyChangedEventHandler PropertyChanged;
      
    }
}


================================================
FILE: Common/Lang/LangCN.cs
================================================
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Common.Lang
{
    public class LangCN : LangBase
    {
        public override string StartUpArgsError { get; set; } = "启动参数错误";

        public override string UpdateWindowTitle { get; set; } = "更新内容";
        public override string ConfirmUpdate { get; set; } = "开始更新";
        public override string CloseUpdate { get; set; } = "关闭";
        public override string UpdateWindowLeftTopTitle { get; set; } = "检查更新";
    }
}


================================================
FILE: Common/Lang/LangEN.cs
================================================
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Common.Lang
{
    public class LangEN : LangBase
    {
        public override string StartUpArgsError { get; set; } = "Start up args error";


        public override string UpdateWindowTitle { get; set; } = "Update Info";
        public override string ConfirmUpdate { get; set; } = "Begin Update";
        public override string CloseUpdate { get; set; } = "Close";
        public override string UpdateWindowLeftTopTitle { get; set; } = "Check Update";
    }
}


================================================
FILE: Common/Lang/LangExtension.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Markup;

namespace Common.Lang
{
    public class LangExtension:MarkupExtension
    {
        private object _value;

        public object Key
        {
            get => _value;
            set => _value = value;
        }



        public override object ProvideValue(IServiceProvider serviceProvider)
        {
            var val = LangHelper.Instance.Lang.GetType().GetProperty((string)Key).GetValue(LangHelper.Instance.Lang, null);
            return val;
        }
    }
}


================================================
FILE: Common/Lang/Language.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Common.Lang
{
    public enum Language
    {
        Chinese,
        English
    }
}


================================================
FILE: Common/LangHelper.cs
================================================
using Common.Lang;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Common
{

    public class LangHelper:INotifyPropertyChanged
    {
        // singleton
        public static LangHelper Instance { get; set; }
        static LangHelper()
        {
            Instance = new LangHelper();
        }

        public event PropertyChangedEventHandler PropertyChanged;

        public void SetLang(Language language)
        {
            Instance.Language = language;
            if (language == Language.English)
            {
                Instance.Lang = new LangEN();
            }
            else
            {
                Instance.Lang = new LangCN();
            }
        }
        public Language Language { get; set; }
        private LangHelper() { }
        
        public LangBase Lang { get; set; }

    }
}


================================================
FILE: Common/Properties/AssemblyInfo.cs
================================================
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;

// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("Common")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("Common")]
[assembly: AssemblyCopyright("Copyright ©  2022")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]

// Setting ComVisible to false makes the types in this assembly not visible
// to COM components.  If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]

// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("eb437726-8891-46de-9d88-271242db82bc")]

// Version information for an assembly consists of the following four values:
//
//      Major Version
//      Minor Version
//      Build Number
//      Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]


================================================
FILE: Common/WindowHelper.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Interop;

namespace Common
{
    public class WindowHelper
    {
        public void TryToAttach(IntPtr ownerHandle,Window window)
        {
            if (ownerHandle == IntPtr.Zero)
            {
                return;
            }
            try
            {
                var helper = new WindowInteropHelper(window) { Owner = ownerHandle };
            }
            catch (Exception e)
            {
            }
        }
    }
}


================================================
FILE: Common/packages.config
================================================
<?xml version="1.0" encoding="utf-8"?>
<packages>
  <package id="Fody" version="6.6.2" targetFramework="net46" developmentDependency="true" />
  <package id="Newtonsoft.Json" version="13.0.1" targetFramework="net46" />
  <package id="PropertyChanged.Fody" version="3.4.1" targetFramework="net46" />
  <package id="RestSharp" version="106.15.0" targetFramework="net46" />
</packages>

================================================
FILE: Common/version.Designer.cs
================================================
//------------------------------------------------------------------------------
// <auto-generated>
//     This code was generated by a tool.
//     Runtime Version:4.0.30319.42000
//
//     Changes to this file may cause incorrect behavior and will be lost if
//     the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------

namespace Common {
    
    
    [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
    [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "17.2.0.0")]
    internal sealed partial class version : global::System.Configuration.ApplicationSettingsBase {
        
        private static version defaultInstance = ((version)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new version())));
        
        public static version Default {
            get {
                return defaultInstance;
            }
        }
    }
}


================================================
FILE: Common/version.json
================================================
{
  "StickyNotesVersion": {
    "MajorVersionNumber": 5,
    "MinorVersionNumber": 0,
    "RevisionNumebr": 1
  },
  "UpdateAppVersion": {
    "MajorVersionNumber": 1,
    "MinorVersionNumber": 0,
    "RevisionNumebr": 1
  }
}

================================================
FILE: Contract/Contract.csproj
================================================
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
  <PropertyGroup>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
    <ProjectGuid>{5CB7E208-C6E8-4593-BAF9-B8D396FBFE41}</ProjectGuid>
    <OutputType>Library</OutputType>
    <AppDesignerFolder>Properties</AppDesignerFolder>
    <RootNamespace>Contract</RootNamespace>
    <AssemblyName>Contract</AssemblyName>
    <TargetFrameworkVersion>v4.6</TargetFrameworkVersion>
    <FileAlignment>512</FileAlignment>
    <Deterministic>true</Deterministic>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
    <DebugSymbols>true</DebugSymbols>
    <DebugType>full</DebugType>
    <Optimize>false</Optimize>
    <OutputPath>bin\Debug\</OutputPath>
    <DefineConstants>DEBUG;TRACE</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
    <DebugType>pdbonly</DebugType>
    <Optimize>true</Optimize>
    <OutputPath>bin\Release\</OutputPath>
    <DefineConstants>TRACE</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
  </PropertyGroup>
  <ItemGroup>
    <Reference Include="System" />
    <Reference Include="System.Core" />
    <Reference Include="System.Xml.Linq" />
    <Reference Include="System.Data.DataSetExtensions" />
    <Reference Include="Microsoft.CSharp" />
    <Reference Include="System.Data" />
    <Reference Include="System.Net.Http" />
    <Reference Include="System.Xml" />
  </ItemGroup>
  <ItemGroup>
    <Compile Include="ProgramData.cs" />
    <Compile Include="Properties\AssemblyInfo.cs" />
    <Compile Include="SoftwareUpdate.cs" />
  </ItemGroup>
  <ItemGroup>
    <Folder Include="Request\" />
    <Folder Include="Response\" />
  </ItemGroup>
  <ItemGroup>
    <ProjectReference Include="..\Common\Common.csproj">
      <Project>{EB437726-8891-46DE-9D88-271242DB82BC}</Project>
      <Name>Common</Name>
    </ProjectReference>
  </ItemGroup>
  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
</Project>

================================================
FILE: Contract/ProgramData.cs
================================================

using Common.Lang;
using System;
using System.Collections.ObjectModel;
using System.ComponentModel;
using System.Runtime.CompilerServices;
using System.Windows.Input;

namespace Contract
{
    public class ProgramData
    {
        /// <summary>
        /// 系统语言
        /// </summary>
        public Language Language { get; set; }
        /// <summary>
        /// 窗体是否置顶
        /// </summary>
        public bool IsWindowTopMost { get; set; }
        /// <summary>
        /// 程序是否自动检查更新
        /// </summary>
        public bool IsAutoCheckUpdate { get; set; }

        /// <summary>
        /// 日间或夜间
        /// </summary>
        public string BaseTheme { get; set; }
        /// <summary>
        /// 窗体主题颜色
        /// </summary>
        public string CurrentTheme { get; set; }

        /// <summary>
        /// 是否开机自启动
        /// </summary>
        public bool IsStartUpWithSystem { get; set; }

        public bool IsWindowVisible { get; set; } = true;



       
    }
}


================================================
FILE: Contract/Properties/AssemblyInfo.cs
================================================
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;

// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("Contract")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("Contract")]
[assembly: AssemblyCopyright("Copyright ©  2022")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]

// Setting ComVisible to false makes the types in this assembly not visible
// to COM components.  If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]

// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("5cb7e208-c6e8-4593-baf9-b8d396fbfe41")]

// Version information for an assembly consists of the following four values:
//
//      Major Version
//      Minor Version
//      Build Number
//      Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]


================================================
FILE: Contract/SoftwareUpdate.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Contract
{
    public class HistoryData
    {
        /// <summary>
        /// 
        /// </summary>
        public string id { get; set; }
        /// <summary>
        /// 
        /// </summary>
        public string history_text { get; set; }
        /// <summary>
        /// 
        /// </summary>
        public string version { get; set; }
        /// <summary>
        /// 
        /// </summary>
        public int major_version_number { get; set; }
        /// <summary>
        /// 
        /// </summary>
        public int minor_version_number { get; set; }
        /// <summary>
        /// 
        /// </summary>
        public int revision_number { get; set; }
        /// <summary>
        /// 
        /// </summary>
        public string software_name { get; set; }
    }

    public class SoftwareUpdate
    {
        /// <summary>
        /// 
        /// </summary>
        public string id { get; set; }
        /// <summary>
        /// 
        /// </summary>
        public string version { get; set; }
        /// <summary>
        /// 
        /// </summary>
        public string software_name { get; set; }
        /// <summary>
        /// 
        /// </summary>
        public string author { get; set; }
        /// <summary>
        /// 
        /// </summary>
        public string update_time { get; set; }
        /// <summary>
        /// 
        /// </summary>
        public int download_count { get; set; }
        /// <summary>
        /// 
        /// </summary>
        public int major_version_number { get; set; }
        /// <summary>
        /// 
        /// </summary>
        public int minor_version_number { get; set; }
        /// <summary>
        /// 
        /// </summary>
        public int revision_number { get; set; }
        /// <summary>
        /// 
        /// </summary>
        public string patch_file_url { get; set; }
        /// <summary>
        /// 
        /// </summary>
        public string download_url { get; set; }
        /// <summary>
        /// 
        /// </summary>
        public List<HistoryData> history_text { get; set; }
    }

  
    
}


================================================
FILE: DB/App.config
================================================
<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <configSections>
    <!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 -->
    <section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
  </configSections>
  <entityFramework>
    <providers>
      <provider invariantName="System.Data.SqlClient" type="System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer" />
      <provider invariantName="System.Data.SQLite.EF6" type="System.Data.SQLite.EF6.SQLiteProviderServices, System.Data.SQLite.EF6" />
    </providers>
  </entityFramework>
  <system.data>
    <DbProviderFactories>
      <remove invariant="System.Data.SQLite.EF6" />
      <add name="SQLite Data Provider (Entity Framework 6)" invariant="System.Data.SQLite.EF6" description=".NET Framework Data Provider for SQLite (Entity Framework 6)" type="System.Data.SQLite.EF6.SQLiteProviderFactory, System.Data.SQLite.EF6" />
    <remove invariant="System.Data.SQLite" /><add name="SQLite Data Provider" invariant="System.Data.SQLite" description=".NET Framework Data Provider for SQLite" type="System.Data.SQLite.SQLiteFactory, System.Data.SQLite" /></DbProviderFactories>
  </system.data>
  <runtime>
    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
      <dependentAssembly>
        <assemblyIdentity name="System.Data.SQLite" publicKeyToken="db937bc2d44ff139" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-1.0.116.0" newVersion="1.0.116.0" />
      </dependentAssembly>
    </assemblyBinding>
  </runtime>
</configuration>

================================================
FILE: DB/Config.cs
================================================
using Common;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace DB
{

    public class Config
    {
        private static string GetCurrentProjectPath
        {

            get
            {
               var str= ComUtil.GetCurrentExecDirectory();
                return str;
            }
        }
        public static string ConnectionString = @"DataSource=" + GetCurrentProjectPath + @"\data.sqlite";
    }
  
}


================================================
FILE: DB/DB.csproj
================================================
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <Import Project="..\packages\EntityFramework.6.4.4\build\EntityFramework.props" Condition="Exists('..\packages\EntityFramework.6.4.4\build\EntityFramework.props')" />
  <Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
  <PropertyGroup>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
    <ProjectGuid>{0E9DA473-F7C4-401B-B1AE-455313699794}</ProjectGuid>
    <OutputType>Library</OutputType>
    <AppDesignerFolder>Properties</AppDesignerFolder>
    <RootNamespace>DB</RootNamespace>
    <AssemblyName>DB</AssemblyName>
    <TargetFrameworkVersion>v4.6</TargetFrameworkVersion>
    <FileAlignment>512</FileAlignment>
    <Deterministic>true</Deterministic>
    <NuGetPackageImportStamp>
    </NuGetPackageImportStamp>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
    <DebugSymbols>true</DebugSymbols>
    <DebugType>full</DebugType>
    <Optimize>false</Optimize>
    <OutputPath>bin\Debug\</OutputPath>
    <DefineConstants>DEBUG;TRACE</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
    <DebugType>pdbonly</DebugType>
    <Optimize>true</Optimize>
    <OutputPath>bin\Release\</OutputPath>
    <DefineConstants>TRACE</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
  </PropertyGroup>
  <ItemGroup>
    <Reference Include="EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL">
      <HintPath>..\packages\EntityFramework.6.4.4\lib\net45\EntityFramework.dll</HintPath>
    </Reference>
    <Reference Include="EntityFramework.SqlServer, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL">
      <HintPath>..\packages\EntityFramework.6.4.4\lib\net45\EntityFramework.SqlServer.dll</HintPath>
    </Reference>
    <Reference Include="log4net, Version=2.0.14.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
      <HintPath>..\packages\log4net.2.0.14\lib\net45\log4net.dll</HintPath>
    </Reference>
    <Reference Include="SqlSugar, Version=5.0.9.1, Culture=neutral, processorArchitecture=MSIL">
      <HintPath>..\packages\SqlSugar.5.0.9.1\lib\SqlSugar.dll</HintPath>
    </Reference>
    <Reference Include="System" />
    <Reference Include="System.ComponentModel.DataAnnotations" />
    <Reference Include="System.Configuration" />
    <Reference Include="System.Core" />
    <Reference Include="System.Data.SQLite, Version=1.0.116.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139, processorArchitecture=MSIL">
      <HintPath>..\packages\Stub.System.Data.SQLite.Core.NetFramework.1.0.116.0\lib\net46\System.Data.SQLite.dll</HintPath>
    </Reference>
    <Reference Include="System.Data.SQLite.EF6, Version=1.0.116.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139, processorArchitecture=MSIL">
      <HintPath>..\packages\System.Data.SQLite.EF6.1.0.116.0\lib\net46\System.Data.SQLite.EF6.dll</HintPath>
    </Reference>
    <Reference Include="System.Data.SQLite.Linq, Version=1.0.116.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139, processorArchitecture=MSIL">
      <HintPath>..\packages\System.Data.SQLite.Linq.1.0.116.0\lib\net46\System.Data.SQLite.Linq.dll</HintPath>
    </Reference>
    <Reference Include="System.Web" />
    <Reference Include="System.Windows.Forms" />
    <Reference Include="System.Xml.Linq" />
    <Reference Include="System.Data.DataSetExtensions" />
    <Reference Include="Microsoft.CSharp" />
    <Reference Include="System.Data" />
    <Reference Include="System.Net.Http" />
    <Reference Include="System.Xml" />
  </ItemGroup>
  <ItemGroup>
    <Compile Include="Config.cs" />
    <Compile Include="Init.cs" />
    <Compile Include="ProgramDB.cs" />
    <Compile Include="Properties\AssemblyInfo.cs" />
    <Compile Include="Repository.cs" />
    <Compile Include="Versions.cs" />
    <Compile Include="WindowsDataDB.cs" />
  </ItemGroup>
  <ItemGroup>
    <None Include="App.config" />
    <None Include="packages.config" />
  </ItemGroup>
  <ItemGroup>
    <ProjectReference Include="..\Common\Common.csproj">
      <Project>{EB437726-8891-46DE-9D88-271242DB82BC}</Project>
      <Name>Common</Name>
    </ProjectReference>
  </ItemGroup>
  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
  <Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
    <PropertyGroup>
      <ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them.  For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
    </PropertyGroup>
    <Error Condition="!Exists('..\packages\EntityFramework.6.4.4\build\EntityFramework.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\EntityFramework.6.4.4\build\EntityFramework.props'))" />
    <Error Condition="!Exists('..\packages\EntityFramework.6.4.4\build\EntityFramework.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\EntityFramework.6.4.4\build\EntityFramework.targets'))" />
    <Error Condition="!Exists('..\packages\Stub.System.Data.SQLite.Core.NetFramework.1.0.116.0\build\net46\Stub.System.Data.SQLite.Core.NetFramework.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\Stub.System.Data.SQLite.Core.NetFramework.1.0.116.0\build\net46\Stub.System.Data.SQLite.Core.NetFramework.targets'))" />
  </Target>
  <Import Project="..\packages\EntityFramework.6.4.4\build\EntityFramework.targets" Condition="Exists('..\packages\EntityFramework.6.4.4\build\EntityFramework.targets')" />
  <Import Project="..\packages\Stub.System.Data.SQLite.Core.NetFramework.1.0.116.0\build\net46\Stub.System.Data.SQLite.Core.NetFramework.targets" Condition="Exists('..\packages\Stub.System.Data.SQLite.Core.NetFramework.1.0.116.0\build\net46\Stub.System.Data.SQLite.Core.NetFramework.targets')" />
</Project>

================================================
FILE: DB/Init.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace DB
{
    public  class DBInit
    {
        public static void InitDB()
        {
            var programDataService = new ProgramDataService();
            //建库
            programDataService.AsSugarClient().DbMaintenance.CreateDatabase();
            //建表
            programDataService.AsSugarClient().CodeFirst.InitTables<ProgramDB>();
            programDataService.AsSugarClient().CodeFirst.InitTables<WindowsDataDB>();
            programDataService.AsSugarClient().CodeFirst.InitTables<Versions>();            
        }
    }
}


================================================
FILE: DB/ProgramDB.cs
================================================
using log4net;
using SqlSugar;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace DB
{
    public class ProgramDataService : Repository<ProgramDB>
    {

        /// <summary>
        /// 获取最新的数据
        /// </summary>
        /// <returns></returns>
        public ProgramDB GetNewestDb()
        {
            try
            {
                var db = base.AsSugarClient().Queryable<ProgramDB>().OrderByDescending(d => d.CreateTime).First();
                return db;

            }
            catch
            {
                return null;
            }
        }

        // delete data yestaday
        public bool DeleteByDate(DateTime time)
        {
            try
            {
                //var db = base.AsSugarClient().Deleteable<ProgramDB>().Where(it => it.CreateTime < time).ExecuteCommand();
                return true;
            }
            catch (Exception ex)
            {
                LogManager.GetLogger("DB").Error(ex.Message);
                return false;
            }
          
        }
       
    }
    [SugarIndex("index_programdb_createtime", nameof(ProgramDB.CreateTime), OrderByType.Asc)]
    public class ProgramDB
    {
        [SqlSugar.SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
        public int Id { get; set; }
        /// <summary>
        /// ProgramData序列化之后的值 
        /// </summary>
        public string Data { get; set; }


        public DateTime CreateTime { get; set; }
    }

   
}


================================================
FILE: DB/Properties/AssemblyInfo.cs
================================================
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;

// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("DB")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("DB")]
[assembly: AssemblyCopyright("Copyright ©  2022")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]

// Setting ComVisible to false makes the types in this assembly not visible
// to COM components.  If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]

// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("0e9da473-f7c4-401b-b1ae-455313699794")]

// Version information for an assembly consists of the following four values:
//
//      Major Version
//      Minor Version
//      Build Number
//      Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]


================================================
FILE: DB/Repository.cs
================================================
using log4net;
using SqlSugar;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace DB
{
    public class Repository<T> : SimpleClient<T> where T : class, new()
    {
        public Repository(ISqlSugarClient context = null) : base(context)//注意这里要有默认值等于null
        {
            if (context == null)
            {
                base.Context = new SqlSugarClient(new ConnectionConfig()
                {
                    DbType = SqlSugar.DbType.Sqlite,
                    InitKeyType = InitKeyType.Attribute,
                    IsAutoCloseConnection = true,
                    ConnectionString = Config.ConnectionString
                });


                base.Context.Aop.OnLogExecuting = (s, p) =>
                {
                    
                    LogManager.GetLogger("DB").Info(s);
                };
            }
        }

       

        /// <summary>
        /// 扩展方法,自带方法不能满足的时候可以添加新方法
        /// </summary>
        /// <returns></returns>
        public List<T> CommQuery(string json)
        {
            T t = Context.Utilities.DeserializeObject<T>(json);
            var list = base.Context.Queryable<T>().WhereClass(t).ToList();
            return list;
        }
    }
}


================================================
FILE: DB/Versions.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace DB
{
    public class Versions
    {
        [SqlSugar.SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
        public int Id { get; set; }
        /// <summary>
        /// 大版本
        /// </summary>
        public int MajorVersion { get; set; }
        /// <summary>
        /// 中版本
        /// </summary>
        public int MinorVersion { get; set; }
        /// <summary>
        /// 小版本
        /// </summary>
        public int BuildVersion { get; set; }

        // get version
        public string Version
        {
            get
            {
                return string.Format("{0}.{1}.{2}", MajorVersion, MinorVersion, BuildVersion);
            }
        }

        /// <summary>
        /// 发布时间
        /// </summary>
        public DateTime PublishTime { get; set; }
    }
}


================================================
FILE: DB/WindowsDataDB.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace DB
{
    public class WindowsDataService:Repository<WindowsDataDB>
    {
        public async Task<List<WindowsDataDB>> GetWindowsDataByProgramDataId(int programDataId)
        {
            return await base.AsSugarClient().Queryable<WindowsDataDB>().Where(it => it.ProgramDataId == programDataId).ToListAsync();
        }
    }
    public class WindowsDataDB
    {
        [SqlSugar.SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
        public int Id { get; set; }
        /// <summary>
        /// ProgramData序列化之后的值 
        /// </summary>
        [SqlSugar.SugarColumn(ColumnDataType ="blob")]
        public byte[] Data { get; set; }

        public int ProgramDataId { get; set; }

        public string WindowId { get; set; }
    }
}


================================================
FILE: DB/packages.config
================================================
<?xml version="1.0" encoding="utf-8"?>
<packages>
  <package id="EntityFramework" version="6.4.4" targetFramework="net46" />
  <package id="log4net" version="2.0.14" targetFramework="net46" />
  <package id="SqlSugar" version="5.0.9.1" targetFramework="net46" />
  <package id="Stub.System.Data.SQLite.Core.NetFramework" version="1.0.116.0" targetFramework="net46" />
  <package id="System.Data.SQLite" version="1.0.116.0" targetFramework="net46" />
  <package id="System.Data.SQLite.Core" version="1.0.116.0" targetFramework="net46" />
  <package id="System.Data.SQLite.EF6" version="1.0.116.0" targetFramework="net46" />
  <package id="System.Data.SQLite.Linq" version="1.0.116.0" targetFramework="net46" />
</packages>

================================================
FILE: LICENSE
================================================
MIT License

Copyright (c) 2019 LiZhengHao

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.


================================================
FILE: README.md
================================================
**此项目已不再维护 2023年5月29日**

# StikyNotes

![#](https://img.shields.io/badge/building-pass-brightgreen)
![star](https://img.shields.io/github/stars/li-zheng-hao/StikyNotes)
![下载量](https://img.shields.io/github/downloads/li-zheng-hao/StikyNotes/total)
![license](https://img.shields.io/github/license/li-zheng-hao/StikyNotes)
![version](https://img.shields.io/github/v/release/li-zheng-hao/StikyNotes)

一个简单清爽的的Windows桌面便利贴

## 安装 Installation

点击下载安装运行即可[点击此处打开下载页面](https://github.com/li-zheng-hao/StikyNotes/releases)

## 一些特性 Features

1. 支持字体放大和缩小
2. 开机自启动
3. 窗口置顶
4. 定时保存
5. 窗体靠上边缘自动吸附隐藏,鼠标上移显示
6. 支持多个窗体主题
7. 全局快捷键功能
8. 自动更新

## 程序截图

![image-20220709174700688](./Doc/ScreenShot1.png)

![image-20220709174700688](./Doc/ScreenShot2.png)

![image](https://github.com/li-zheng-hao/StikyNotes/raw/master/Doc/taskbar.png)



================================================
FILE: StickyNotes/App.config
================================================
<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <configSections>
    <!--log4net配置-->
    <section name="log4net" type="System.Configuration.IgnoreSectionHandler"/>
  </configSections>

  <log4net>
    <appender name="RollingLogFileAppender_DateFormat" type="log4net.Appender.RollingFileAppender">
      <file value="log//"/>
      <param name="Encoding" value="utf-8"/>
      <appendToFile value="true"/>
      <rollingStyle value="Date"/>
      <datePattern value="yyyy-MM-dd&quot;.log&quot;"/>
      <staticLogFileName value="false"/>
      <param name="MaxSizeRollBackups" value="30"/>
      <layout type="log4net.Layout.PatternLayout">
        <conversionPattern value="%date %-5level - %message%newline"/>
      </layout>
    </appender>
    <root>
      <appender-ref ref="RollingLogFileAppender_DateFormat"/>
    </root>
  </log4net>
  <!--log4net配置end-->
  <startup>
    <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.8"/>
  </startup>


</configuration>


================================================
FILE: StickyNotes/App.xaml
================================================
<Application
    x:Class="StickyNotes.App"
    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:d1p1="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:local="clr-namespace:StickyNotes"
    d1p1:Ignorable="d"
    ShutdownMode="OnExplicitShutdown"
    Startup="Application_Startup">
    <!--  Startup="Application_Startup"  -->
    <Application.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
             
                <!--<ResourceDictionary Source="Style/Languages/Lan-cn.xaml" />-->
                <!--<ResourceDictionary Source="Style/Languages/Lan-en.xaml" />-->


                <!--<ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Accents/Blue.xaml" />-->
                <!--<ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Accents/BaseLight.xaml" />-->
                <!--<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.Light.xaml" />-->
                <!--<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.Defaults.xaml" />-->

                <!--handycontrol-->
               
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Controls.xaml" />
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Fonts.xaml" />
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Themes/Light.Blue.xaml" />
                <ResourceDictionary Source="pack://application:,,,/HandyControl;component/Themes/SkinDefault.xaml"/>
                <ResourceDictionary Source="pack://application:,,,/HandyControl;component/Themes/Theme.xaml"/>
                <!--  加上自己的一些Style  放下面的优先级更高-->
                <ResourceDictionary Source="Style/Color.xaml" />
                <ResourceDictionary Source="Style/Font.xaml" />
                <ResourceDictionary Source="Style/Control.xaml" />
                <ResourceDictionary Source="Style/Window.xaml" />
                <ResourceDictionary Source="Style/Label.xaml" />
                <ResourceDictionary Source="Style/Themes/冷灰.xaml" />
            </ResourceDictionary.MergedDictionaries>
            <vm:ViewModelLocator
                xmlns:vm="clr-namespace:StickyNotes.ViewModel"
                x:Key="Locator"
                d:IsDataSource="True" />
            <ContextMenu x:Key="NotifyIconMenu" HorizontalAlignment="Center" Width="100" StaysOpen="False">
                <MenuItem
                    Width="100"
                    Padding="10 5"
                    HorizontalAlignment="Center"
                    Name="MenuOpen"
                    Click="MenuOpen_Click"
                    Header="{DynamicResource global-new}" />
                <MenuItem
                    Width="100"
                    Padding="5 5"
                    HorizontalAlignment="Center"
                    Name="ListOpen"
                    Click="ListOpen_Click"
                    Header="{DynamicResource menuList}" />
                <MenuItem
                    HorizontalAlignment="Center"
                    Width="100"
                    Padding="10 5"
                    
                    Name="MenuExit"
                    Click="MenuExit_Click"
                    Header="{DynamicResource global-exit}" />
            </ContextMenu>
        </ResourceDictionary>
    </Application.Resources>
</Application>

================================================
FILE: StickyNotes/App.xaml.cs
================================================
using Common;
using Common.Lang;
using DB;
using MahApps.Metro.Controls;
using StickyNotes.Utils;
using StickyNotes.View;
using System;
using System.Diagnostics;
using System.IO;
using System.Net;
using System.Reflection;
using System.Text.RegularExpressions;
using System.Threading;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Threading;
using Application = System.Windows.Application;
using MessageBox = System.Windows.MessageBox;
namespace StickyNotes
{
    /// <summary>
    /// App.xaml 的交互逻辑
    /// </summary>
    public partial class App : Application
    {

        #region 主程序
        System.Threading.Mutex mutex;

        public bool IsInited { get; set; } = true;

        public TimerUtil TimerUtil;

        /// <summary>
        /// 程序启动
        /// </summary>
        /// <param name="e"></param>
        protected override async void OnStartup(StartupEventArgs e)
        {

            #region 是否只能运行一个APP

            bool ret;
            mutex = new System.Threading.Mutex(true, "StickyNotesAPP", out ret);

            if (!ret)
            {
                //AdministratorUtil.KillProcess("StickyNotes");
                MessageBox.Show("已运行");
                Environment.Exit(0);
            }
            #endregion
            #region 检测管理员权限
            //AdministratorUtil.RunAsAdmin();
            #endregion

            Logger.Log().Info("程序启动");
            /// 将全局异常保存到文件目录下
            Current.DispatcherUnhandledException += App_OnDispatcherUnhandledException;
            AppDomain.CurrentDomain.UnhandledException += CurrentDomain_UnhandledException;
            //Messenger.Default.Register<SaveMessage>(this, SaveDataMessage);
            // 初始化数据库
            DBInit.InitDB();
            // 删除3小时前的旧数据
            new ProgramDataService().DeleteByDate(DateTime.Now.AddHours(-3));
            var systemtray = SystemTray.Instance;
            var programData = await DataHelper.RestoreDataAsync();
            if (programData == null)
            {
                LanguageManager.ChangeLanguage(Language.Chinese);

            }
            else
            {
                LanguageManager.ChangeLanguage(programData.Language);

            }

            if (programData != null)
            {
                var windowsDatas = programData.Datas;
                ProgramData.Instance.IsWindowTopMost = programData.IsWindowTopMost;
                ProgramData.Instance.IsStartUpWithSystem = programData.IsStartUpWithSystem;
                ProgramData.Instance.CurrentTheme = programData.CurrentTheme;
                ProgramData.Instance.ShowAllHotKey = programData.ShowAllHotKey;
                ProgramData.Instance.IsAutoCheckUpdate = programData.IsAutoCheckUpdate;
                ProgramData.Instance.HideWindowData= programData.HideWindowData;
                ProgramData.Instance.Language = programData.Language;
                ThemeAssist.ChangeTheme(programData.CurrentTheme);
                //有创建过的窗口
                if (windowsDatas.Count > 0)
                {
                    for (int i = 0; i < windowsDatas.Count; i++)
                    {
                        OpenNewWindow(windowsDatas[i]);
                    }
                }
                else//以前的窗口都被删掉了
                {
                    OpenNewWindow();
                }
            }
            //没有创建过的窗口
            else
            {
                OpenNewWindow();
            }
            IsInited = false;
            TimerUtil = new TimerUtil(SaveDataAction);
            HttpHelper.BaseUrl = StickyNotes.Properties.Resources.ServerUrl;
            
            new Task(CheckUpdate).Start();

        }
        /// <summary>
        /// 检查程序是否要更新
        /// </summary>
        private void CheckUpdate()
        {
            ProgramData p = ProgramData.Instance;
            if (p.IsAutoCheckUpdate == false)
                return;
            try
            {
                var updateHelper=new UpdateHelper();
                updateHelper.UpdateToolCompleted += () => {
                   var res=updateHelper.CheckSelfNeedUpdate();
                   if(res)
                   {
                        updateHelper.OpenUpdateTool();
                   }
                };
               
                updateHelper.UpdateUpdateTool();
            }
            catch (Exception ex)
            {
                Logger.Log().Debug($"无法更新 {ex.Message}");
            }
        }


        /// <summary>
        /// 新建窗体
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void MenuOpen_Click(object sender, RoutedEventArgs e)
        {
            OpenNewWindow();
        }

        /// <summary>
        /// 窗体退出
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void MenuExit_Click(object sender, RoutedEventArgs e)
        {
            SystemTray.Instance.DisposeNotifyIcon();
            App.Current.Shutdown();
        }

        /// <summary>
        /// 程序退出事件
        /// </summary>
        /// <param name="e"></param>
        protected override async void OnExit(ExitEventArgs e)
        {
            Logger.Log().Info("程序退出");
            await DataHelper.SaveDataAsync(ProgramData.Instance);
            SystemTray.Instance.DisposeNotifyIcon();
            base.OnExit(e);
        }

        /// <summary>
        /// 程序开始启动的地方
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void Application_Startup(object sender, StartupEventArgs e)
        {
            OnStartup(null);
        }

        /// <summary>
        /// 接收到了保存数据的消息
        /// </summary>
        /// <param name="message"></param>
        //private void SaveDataMessage(SaveMessage message)
        //{
        //    if (!IsInited)
        //    {
        //        XMLHelper.SaveObjAsXml(ProgramData.Instance, ConstData.SaveSettingDataName);
        //    }
        //}

        public void SaveDataAction()
        {
            if (!IsInited)
            {
                DataHelper.SaveDataAsync(ProgramData.Instance);
            }
        }
        
        /// <summary>
        /// 打开一个空的窗体
        /// </summary>
        private void OpenNewWindow()
        {
            var MainWindow = new MainWindow();
            MainWindow.viewModel.Datas = new WindowsData();
            MainWindow.Show();
            ProgramData.Instance.Datas.Add(MainWindow.viewModel.Datas);
            WindowsManager.Instance.Windows.Add(MainWindow);
        }
        /// <summary>
        /// 打开之前曾经存在过的窗体
        /// </summary>
        /// <param name="data"></param>
        private void OpenNewWindow(WindowsData data)
        {
            var MainWindow = new MainWindow();
            MainWindow.viewModel.Datas = data;
            MainWindow.viewModel.RestoreData(MainWindow.Document, MainWindow.viewModel.Datas.WindowID);
            MainWindow.Show();
            WindowsManager.Instance.Windows.Add(MainWindow);
            ProgramData.Instance.Datas.Add(data);


        }


        // <summary>
        /// UI线程抛出全局异常事件处理
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void App_OnDispatcherUnhandledException(object sender, DispatcherUnhandledExceptionEventArgs e)
        {
            try
            {
                Logger.Log().Error(e.Exception.StackTrace);
                Logger.Log().Error(e.Exception.Message);
                MessageBox.Show(e.Exception.Message);

            }
            catch (Exception ex)
            {
                Logger.Log().Error(ex.StackTrace);
                Logger.Log().Error(ex.Message);
            }
        }

        /// <summary>
        /// 非UI线程抛出全局异常事件处理
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void CurrentDomain_UnhandledException(object sender, UnhandledExceptionEventArgs e)
        {
            try
            {
                var exception = e.ExceptionObject as Exception;
                if (exception != null)
                {
                    Logger.Log().Error(exception.StackTrace);
                    Logger.Log().Error(exception.Message);
                    MessageBox.Show(exception.Message);
                }
            }
            catch (Exception ex)
            {
                try
                {
                    var exception = e.ExceptionObject as Exception;
                    if (exception != null)
                    {
                        Logger.Log().Error(exception.StackTrace);
                        Logger.Log().Error(exception.Message);
                    }
                }
                catch (Exception exxxx)
                {
                    Logger.Log().Error(exxxx.StackTrace);
                    Logger.Log().Error(exxxx.Message);

                }
            }
        }

        #endregion

        private void ListOpen_Click(object sender, RoutedEventArgs e)
        {
            if (WindowsManager.ListWindow == null || WindowsManager.ListWindow.IsActive == false)
            {
                WindowsManager.ListWindow = new ListWindow();
                WindowsManager.ListWindow.Show();
            }
            else
            {
                WindowsManager.ListWindow.Activate();
            }
        }
    }
}


================================================
FILE: StickyNotes/Converter/DateTimeToVisibilityConverter.cs
================================================
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Data;

namespace StickyNotes.Converter
{
    public class DateTimeToVisibilityConverter : IValueConverter
    {
        public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
        {
            return ((DateTime)value).ToString("yyyy-MM-dd HH:mm:ss");
        }

        public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
        {
            return null;
        }
    }
}


================================================
FILE: StickyNotes/Converter/DeleteWindowMessageConverter.cs
================================================
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Runtime.InteropServices.WindowsRuntime;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Data;

namespace StickyNotes.Converter
{
    public class DeleteWindowMessageConverter: IMultiValueConverter
    {
      
            public object Convert(object[] values, Type targetType, object parameter, CultureInfo culture)
            {
                return values.Clone();
            }

            public object[] ConvertBack(object value, Type[] targetTypes, object parameter, CultureInfo culture)
            {
                return null;
            }
    }
}


================================================
FILE: StickyNotes/Converter/LanguageConverter.cs
================================================
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Data;

namespace StickyNotes
{
    internal class LanguageConverter : IValueConverter
    {
        /// <summary>
        /// 从DataContext中的数据转换到View中的数据
        /// </summary>
        /// <param name="value"></param>
        /// <param name="targetType"></param>
        /// <param name="parameter"></param>
        /// <param name="culture"></param>
        /// <returns></returns>
        public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
        {
            string result = value.ToString();
            return result;
        }
        /// <summary>
        /// 不需要这个
        /// </summary>
        /// <param name="value"></param>
        /// <param name="targetType"></param>
        /// <param name="parameter"></param>
        /// <param name="culture"></param>
        /// <returns></returns>
        public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
        {
            throw new Exception("不需要转换语言,只允许单向绑定");
        }
    }
}


================================================
FILE: StickyNotes/Converter/ShowAllHotKeyConverter.cs
================================================
using StickyNotes.Utils.HotKeyUtil;
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Data;

namespace StickyNotes
{
    public class ShowAllHotKeyConverter : IValueConverter
    {
        /// <summary>
        /// 从DataContent中的数据转换到View中的数据
        /// </summary>
        /// <param name="value">DataContent中的数据</param>
        /// <param name="targetType"></param>
        /// <param name="parameter"></param>
        /// <param name="culture"></param>
        /// <returns></returns>
        public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
        {
            var result = (HotKey)value;
            return result.ToString();
        }

       

        /// <summary>
        /// 只有在TwoWay的时候才能用上
        /// </summary>
        /// <param name="value"></param>
        /// <param name="targetType"></param>
        /// <param name="parameter"></param>
        /// <param name="culture"></param>
        /// <returns></returns>
        public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
        {
            //            HotKeyModel res = new HotKeyModel();
            //            res.Name = EHotKeySetting.ShowAllWindow.ToString();
            //            string str = (string)value;
            //            string[] keys = str.Split('+');
            //            if (keys.Contains("Ctrl"))
            //            {
            //                res.IsSelectCtrl = true;
            //            }
            //
            //            if (keys.Contains("Shift"))
            //            {
            //                res.IsSelectShift = true;
            //            }
            //
            //            if (keys.Contains("Alt"))
            //            {
            //                res.IsSelectAlt = true;
            //            }
            //
            //            var useKey = EKey.Q;
            //            foreach (int v in Enum.GetValues(typeof(EKey)))
            //            {
            //                string keyName = Enum.GetName(typeof(EKey), v);
            //                if (keys.Last() == keyName)
            //                {
            //                    useKey = (EKey)v;
            //                }
            //            }
            //
            //            res.SelectKey = useKey;
            //            res.IsUsable = true;
            //            return res;
            return null;

        }

    }
}


================================================
FILE: StickyNotes/Converter/ThemeConverter.cs
================================================
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Data;

namespace StickyNotes
{
    public class ThemeConverter:IValueConverter
    {
        /// <summary>
        /// 从DataContext中的数据转换到View中的数据
        /// </summary>
        /// <param name="value">DataContent中的数据</param>
        /// <param name="targetType"></param>
        /// <param name="parameter"></param>
        /// <param name="culture"></param>
        /// <returns></returns>
        public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
        {
            int result=(int)value;
            return result.ToString();
        }

        /// <summary>
        /// 只有在TwoWay的时候才能用上
        /// </summary>
        /// <param name="value"></param>
        /// <param name="targetType"></param>
        /// <param name="parameter"></param>
        /// <param name="culture"></param>
        /// <returns></returns>
        public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
        {
            //var index = (Themes)value;
            //return index;
            return "1";
        }
    }
}


================================================
FILE: StickyNotes/Converter/boolToVisibilityConverter.cs
================================================
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Data;

namespace StickyNotes.Converter
{
    public class BoolToVisibilityConverter : IValueConverter
    {
        public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
        {
            return (bool)value == true ? Visibility.Visible : Visibility.Collapsed;
        }

        public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
        {
            return null;
        }
    }
}


================================================
FILE: StickyNotes/Data/ConstData.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace StickyNotes
{
    public class ConstData
    {
        public static  string SaveSettingDataName = "StickyNotesData.xml";
        public static string BackUpDataName = "BackupData.xml";

    }
}


================================================
FILE: StickyNotes/Data/ProgramData.cs
================================================
using Common.Lang;
using GalaSoft.MvvmLight.Messaging;
using StickyNotes.Annotations;
using StickyNotes.Utils;
using StickyNotes.Utils.HotKeyUtil;
using System;
using System.Collections.ObjectModel;
using System.ComponentModel;
using System.Runtime.CompilerServices;
using System.Windows.Input;

namespace StickyNotes
{
    [Serializable]
    public class ProgramData : INotifyPropertyChanged
    {
        public ObservableCollection<WindowsData> Datas { get; set; }
        public ObservableCollection<WindowsData> HideWindowData { get; set; }

        /// <summary>
        /// 系统语言
        /// </summary>
        public Language Language { get; set; }
        /// <summary>
        /// 窗体是否置顶
        /// </summary>
        public bool IsWindowTopMost { get; set; }
        /// <summary>
        /// 程序是否自动检查更新
        /// </summary>
        public bool IsAutoCheckUpdate { get; set; }

        private static ProgramData instance = new ProgramData();

        public static ProgramData Instance
        {
            get { return instance; }
        }
        /// <summary>
        /// 显示所有窗体的快捷键
        /// </summary>
        public HotKey ShowAllHotKey { get; set; }


        /// <summary>
        /// 日间或夜间
        /// </summary>
        public string BaseTheme { get; set; }
        /// <summary>
        /// 窗体主题颜色
        /// </summary>
        public string CurrentTheme { get; set; }

        /// <summary>
        /// 是否开机自启动
        /// </summary>
        public bool IsStartUpWithSystem { get; set; }

        public bool IsWindowVisible { get; set; } = true;


        private ProgramData()
        {
            //            Instance = new ProgramData();
            Datas = new ObservableCollection<WindowsData>();
            HideWindowData = new ObservableCollection<WindowsData>();
            IsWindowTopMost = false;
            IsStartUpWithSystem = false;
            IsAutoCheckUpdate = false;
            Datas.CollectionChanged += Datas_CollectionChanged;
            BaseTheme = "Light";
            Language = Language.Chinese;
            CurrentTheme = "冷灰";
            ShowAllHotKey = new HotKey(Key.Q, ModifierKeys.Control,HotKeyHandler.HandlePress,HotKeyType.ShowOrHideAllWindow);
        }

        

        private void Datas_CollectionChanged(object sender, System.Collections.Specialized.NotifyCollectionChangedEventArgs e)
        {
            Messenger.Default.Send<SaveMessage>(new SaveMessage());
        }

        public event PropertyChangedEventHandler PropertyChanged;

        [NotifyPropertyChangedInvocator]
        public virtual void OnPropertyChanged([CallerMemberName] string propertyName = null)
        {
            Messenger.Default.Send<SaveMessage>(new SaveMessage());
            PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
        }
    }
}


================================================
FILE: StickyNotes/Data/WindowsData.cs
================================================
using StickyNotes.Annotations;
using System;
using System.ComponentModel;
using System.Runtime.CompilerServices;
using System.Windows;
using System.Xml.Serialization;
using GalaSoft.MvvmLight.Messaging;

namespace StickyNotes
{
    public class WindowsData : INotifyPropertyChanged
    {
        /// <summary>
        /// 文档创建的ID,以时间戳为准
        /// </summary>
        public string WindowID { get; set; }
        /// <summary>
        /// 窗体字体
        /// </summary>
        public double FontSize { get; set; }

        /// <summary>
        /// 窗体启动左上角位置
        /// </summary>
        public double StartUpPositionTop { get; set; }
        public double StartUpPositionLeft { get; set; }
        /// <summary>
        /// 文本框是否获得了焦点
        /// </summary>
        public bool IsFocused { get; set; }
        /// <summary>
        /// 窗体宽度
        /// </summary>
        public int WindowsWidth { get; set; }


        /// <summary>
        /// 窗体高度
        /// </summary>
        public int WindowsHeight { get; set; }

        /// <summary>
        /// 文本框内容 用于存储到数据库使用的字符串 显示会乱码
        /// </summary>
        public byte[] RichTextBoxContent { get; set; }

        /// <summary>
        /// 用于在界面上展示的便签内容
        /// </summary>
        public string DisplayRichTextBoxContent { get; set; }
        /// <summary>
        /// 窗体是否置顶
        /// </summary>
        public bool IsCurrentWindowTopMost { get; set; }

        /// <summary>
        /// 当前窗口存储的文件路径
        /// </summary>
        public string DocumentFileName { get; set; }

        /// <summary>
        /// 窗体是否已经显示
        /// </summary>
        public bool IsShowed { get; set; }

        /// <summary>
        /// 最后修改时间
        /// </summary>
        public DateTime ModifiedTime { get; set; }
        /// <summary>
        /// 默认初始化数据
        /// </summary>
        public WindowsData()
        {
            WindowID = DateTime.Now.Year.ToString() + "-" + DateTime.Now.Month.ToString() +
                       DateTime.Now.Day.ToString() + "-" + DateTime.Now.Minute.ToString() + "-" +
                       DateTime.Now.Second.ToString() + "-" +
                       DateTime.Now.Millisecond.ToString();
            DocumentFileName = WindowID;
            WindowsWidth = 300;
            WindowsHeight = 300;
            FontSize = 14;
            double screenHeight = SystemParameters.FullPrimaryScreenHeight;
            double screenWidth = SystemParameters.FullPrimaryScreenWidth;
            StartUpPositionLeft = (screenWidth - WindowsWidth) / 2;
            StartUpPositionTop = (screenHeight - WindowsHeight) / 2;
            DisplayRichTextBoxContent = string.Empty;
            IsCurrentWindowTopMost = false;
            IsFocused = true;
            IsShowed = true;
            ModifiedTime = DateTime.Now;
        }


        public event PropertyChangedEventHandler PropertyChanged;

        [NotifyPropertyChangedInvocator]
        protected virtual void OnPropertyChanged([CallerMemberName] string propertyName = null)
        {
            PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
        }
    }
}


================================================
FILE: StickyNotes/FodyWeavers.xml
================================================
<?xml version="1.0" encoding="utf-8"?>
<Weavers xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="FodyWeavers.xsd">
  <PropertyChanged />
	<Costura
  Unmanaged32Assemblies='dllname' 
  Unmanaged64Assemblies='dllname' />
</Weavers>


================================================
FILE: StickyNotes/FodyWeavers.xsd
================================================
<?xml version="1.0" encoding="utf-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
  <!-- This file was generated by Fody. Manual changes to this file will be lost when your project is rebuilt. -->
  <xs:element name="Weavers">
    <xs:complexType>
      <xs:all>
        <xs:element name="PropertyChanged" minOccurs="0" maxOccurs="1">
          <xs:complexType>
            <xs:attribute name="InjectOnPropertyNameChanged" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>Used to control if the On_PropertyName_Changed feature is enabled.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="EventInvokerNames" type="xs:string">
              <xs:annotation>
                <xs:documentation>Used to change the name of the method that fires the notify event. This is a string that accepts multiple values in a comma separated form.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="CheckForEquality" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>Used to control if equality checks should be inserted. If false, equality checking will be disabled for the project.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="CheckForEqualityUsingBaseEquals" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>Used to control if equality checks should use the Equals method resolved from the base class.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="UseStaticEqualsFromBase" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>Used to control if equality checks should use the static Equals method resolved from the base class.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
          </xs:complexType>
        </xs:element>
        <xs:element name="Costura" minOccurs="0" maxOccurs="1">
          <xs:complexType>
            <xs:all>
              <xs:element minOccurs="0" maxOccurs="1" name="ExcludeAssemblies" type="xs:string">
                <xs:annotation>
                  <xs:documentation>A list of assembly names to exclude from the default action of "embed all Copy Local references", delimited with line breaks</xs:documentation>
                </xs:annotation>
              </xs:element>
              <xs:element minOccurs="0" maxOccurs="1" name="IncludeAssemblies" type="xs:string">
                <xs:annotation>
                  <xs:documentation>A list of assembly names to include from the default action of "embed all Copy Local references", delimited with line breaks.</xs:documentation>
                </xs:annotation>
              </xs:element>
              <xs:element minOccurs="0" maxOccurs="1" name="Unmanaged32Assemblies" type="xs:string">
                <xs:annotation>
                  <xs:documentation>A list of unmanaged 32 bit assembly names to include, delimited with line breaks.</xs:documentation>
                </xs:annotation>
              </xs:element>
              <xs:element minOccurs="0" maxOccurs="1" name="Unmanaged64Assemblies" type="xs:string">
                <xs:annotation>
                  <xs:documentation>A list of unmanaged 64 bit assembly names to include, delimited with line breaks.</xs:documentation>
                </xs:annotation>
              </xs:element>
              <xs:element minOccurs="0" maxOccurs="1" name="PreloadOrder" type="xs:string">
                <xs:annotation>
                  <xs:documentation>The order of preloaded assemblies, delimited with line breaks.</xs:documentation>
                </xs:annotation>
              </xs:element>
            </xs:all>
            <xs:attribute name="CreateTemporaryAssemblies" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>This will copy embedded files to disk before loading them into memory. This is helpful for some scenarios that expected an assembly to be loaded from a physical file.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="IncludeDebugSymbols" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>Controls if .pdbs for reference assemblies are also embedded.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="DisableCompression" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>Embedded assemblies are compressed by default, and uncompressed when they are loaded. You can turn compression off with this option.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="DisableCleanup" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>As part of Costura, embedded assemblies are no longer included as part of the build. This cleanup can be turned off.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="LoadAtModuleInit" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>Costura by default will load as part of the module initialization. This flag disables that behavior. Make sure you call CosturaUtility.Initialize() somewhere in your code.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="IgnoreSatelliteAssemblies" type="xs:boolean">
              <xs:annotation>
                <xs:documentation>Costura will by default use assemblies with a name like 'resources.dll' as a satellite resource and prepend the output path. This flag disables that behavior.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="ExcludeAssemblies" type="xs:string">
              <xs:annotation>
                <xs:documentation>A list of assembly names to exclude from the default action of "embed all Copy Local references", delimited with |</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="IncludeAssemblies" type="xs:string">
              <xs:annotation>
                <xs:documentation>A list of assembly names to include from the default action of "embed all Copy Local references", delimited with |.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="Unmanaged32Assemblies" type="xs:string">
              <xs:annotation>
                <xs:documentation>A list of unmanaged 32 bit assembly names to include, delimited with |.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="Unmanaged64Assemblies" type="xs:string">
              <xs:annotation>
                <xs:documentation>A list of unmanaged 64 bit assembly names to include, delimited with |.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
            <xs:attribute name="PreloadOrder" type="xs:string">
              <xs:annotation>
                <xs:documentation>The order of preloaded assemblies, delimited with |.</xs:documentation>
              </xs:annotation>
            </xs:attribute>
          </xs:complexType>
        </xs:element>
      </xs:all>
      <xs:attribute name="VerifyAssembly" type="xs:boolean">
        <xs:annotation>
          <xs:documentation>'true' to run assembly verification (PEVerify) on the target assembly after all weavers have been executed.</xs:documentation>
        </xs:annotation>
      </xs:attribute>
      <xs:attribute name="VerifyIgnoreCodes" type="xs:string">
        <xs:annotation>
          <xs:documentation>A comma-separated list of error codes that can be safely ignored in assembly verification.</xs:documentation>
        </xs:annotation>
      </xs:attribute>
      <xs:attribute name="GenerateXsd" type="xs:boolean">
        <xs:annotation>
          <xs:documentation>'false' to turn off automatic generation of the XML Schema file.</xs:documentation>
        </xs:annotation>
      </xs:attribute>
    </xs:complexType>
  </xs:element>
</xs:schema>

================================================
FILE: StickyNotes/Properties/Annotations.cs
================================================
/* MIT License

Copyright (c) 2016 JetBrains http://www.jetbrains.com

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE. */

using System;

#pragma warning disable 1591
// ReSharper disable UnusedMember.Global
// ReSharper disable MemberCanBePrivate.Global
// ReSharper disable UnusedAutoPropertyAccessor.Global
// ReSharper disable IntroduceOptionalParameters.Global
// ReSharper disable MemberCanBeProtected.Global
// ReSharper disable InconsistentNaming

namespace StickyNotes.Annotations
{
  /// <summary>
  /// Indicates that the value of the marked element could be <c>null</c> sometimes,
  /// so the check for <c>null</c> is necessary before its usage.
  /// </summary>
  /// <example><code>
  /// [CanBeNull] object Test() => null;
  /// 
  /// void UseTest() {
  ///   var p = Test();
  ///   var s = p.ToString(); // Warning: Possible 'System.NullReferenceException'
  /// }
  /// </code></example>
  [AttributeUsage(
    AttributeTargets.Method | AttributeTargets.Parameter | AttributeTargets.Property |
    AttributeTargets.Delegate | AttributeTargets.Field | AttributeTargets.Event |
    AttributeTargets.Class | AttributeTargets.Interface | AttributeTargets.GenericParameter)]
  public sealed class CanBeNullAttribute : Attribute { }

  /// <summary>
  /// Indicates that the value of the marked element could never be <c>null</c>.
  /// </summary>
  /// <example><code>
  /// [NotNull] object Foo() {
  ///   return null; // Warning: Possible 'null' assignment
  /// }
  /// </code></example>
  [AttributeUsage(
    AttributeTargets.Method | AttributeTargets.Parameter | AttributeTargets.Property |
    AttributeTargets.Delegate | AttributeTargets.Field | AttributeTargets.Event |
    AttributeTargets.Class | AttributeTargets.Interface | AttributeTargets.GenericParameter)]
  public sealed class NotNullAttribute : Attribute { }

  /// <summary>
  /// Can be appplied to symbols of types derived from IEnumerable as well as to symbols of Task
  /// and Lazy classes to indicate that the value of a collection item, of the Task.Result property
  /// or of the Lazy.Value property can never be null.
  /// </summary>
  [AttributeUsage(
    AttributeTargets.Method | AttributeTargets.Parameter | AttributeTargets.Property |
    AttributeTargets.Delegate | AttributeTargets.Field)]
  public sealed class ItemNotNullAttribute : Attribute { }

  /// <summary>
  /// Can be appplied to symbols of types derived from IEnumerable as well as to symbols of Task
  /// and Lazy classes to indicate that the value of a collection item, of the Task.Result property
  /// or of the Lazy.Value property can be null.
  /// </summary>
  [AttributeUsage(
    AttributeTargets.Method | AttributeTargets.Parameter | AttributeTargets.Property |
    AttributeTargets.Delegate | AttributeTargets.Field)]
  public sealed class ItemCanBeNullAttribute : Attribute { }

  /// <summary>
  /// Indicates that the marked method builds string by format pattern and (optional) arguments.
  /// Parameter, which contains format string, should be given in constructor. The format string
  /// should be in <see cref="string.Format(IFormatProvider,string,object[])"/>-like form.
  /// </summary>
  /// <example><code>
  /// [StringFormatMethod("message")]
  /// void ShowError(string message, params object[] args) { /* do something */ }
  /// 
  /// void Foo() {
  ///   ShowError("Failed: {0}"); // Warning: Non-existing argument in format string
  /// }
  /// </code></example>
  [AttributeUsage(
    AttributeTargets.Constructor | AttributeTargets.Method |
    AttributeTargets.Property | AttributeTargets.Delegate)]
  public sealed class StringFormatMethodAttribute : Attribute
  {
    /// <param name="formatParameterName">
    /// Specifies which parameter of an annotated method should be treated as format-string
    /// </param>
    public StringFormatMethodAttribute([NotNull] string formatParameterName)
    {
      FormatParameterName = formatParameterName;
    }

    [NotNull] public string FormatParameterName { get; private set; }
  }

  /// <summary>
  /// For a parameter that is expected to be one of the limited set of values.
  /// Specify fields of which type should be used as values for this parameter.
  /// </summary>
  [AttributeUsage(
    AttributeTargets.Parameter | AttributeTargets.Property | AttributeTargets.Field,
    AllowMultiple = true)]
  public sealed class ValueProviderAttribute : Attribute
  {
    public ValueProviderAttribute([NotNull] string name)
    {
      Name = name;
    }

    [NotNull] public string Name { get; private set; }
  }

  /// <summary>
  /// Indicates that the function argument should be string literal and match one
  /// of the parameters of the caller function. For example, ReSharper annotates
  /// the parameter of <see cref="System.ArgumentNullException"/>.
  /// </summary>
  /// <example><code>
  /// void Foo(string param) {
  ///   if (param == null)
  ///     throw new ArgumentNullException("par"); // Warning: Cannot resolve symbol
  /// }
  /// </code></example>
  [AttributeUsage(AttributeTargets.Parameter)]
  public sealed class InvokerParameterNameAttribute : Attribute { }

  /// <summary>
  /// Indicates that the method is contained in a type that implements
  /// <c>System.ComponentModel.INotifyPropertyChanged</c> interface and this method
  /// is used to notify that some property value changed.
  /// </summary>
  /// <remarks>
  /// The method should be non-static and conform to one of the supported signatures:
  /// <list>
  /// <item><c>NotifyChanged(string)</c></item>
  /// <item><c>NotifyChanged(params string[])</c></item>
  /// <item><c>NotifyChanged{T}(Expression{Func{T}})</c></item>
  /// <item><c>NotifyChanged{T,U}(Expression{Func{T,U}})</c></item>
  /// <item><c>SetProperty{T}(ref T, T, string)</c></item>
  /// </list>
  /// </remarks>
  /// <example><code>
  /// public class Foo : INotifyPropertyChanged {
  ///   public event PropertyChangedEventHandler PropertyChanged;
  /// 
  ///   [NotifyPropertyChangedInvocator]
  ///   protected virtual void NotifyChanged(string propertyName) { ... }
  ///
  ///   string _name;
  /// 
  ///   public string Name {
  ///     get { return _name; }
  ///     set { _name = value; NotifyChanged("LastName"); /* Warning */ }
  ///   }
  /// }
  /// </code>
  /// Examples of generated notifications:
  /// <list>
  /// <item><c>NotifyChanged("Property")</c></item>
  /// <item><c>NotifyChanged(() =&gt; Property)</c></item>
  /// <item><c>NotifyChanged((VM x) =&gt; x.Property)</c></item>
  /// <item><c>SetProperty(ref myField, value, "Property")</c></item>
  /// </list>
  /// </example>
  [AttributeUsage(AttributeTargets.Method)]
  public sealed class NotifyPropertyChangedInvocatorAttribute : Attribute
  {
    public NotifyPropertyChangedInvocatorAttribute() { }
    public NotifyPropertyChangedInvocatorAttribute([NotNull] string parameterName)
    {
      ParameterName = parameterName;
    }

    [CanBeNull] public string ParameterName { get; private set; }
  }

  /// <summary>
  /// Describes dependency between method input and output.
  /// </summary>
  /// <syntax>
  /// <p>Function Definition Table syntax:</p>
  /// <list>
  /// <item>FDT      ::= FDTRow [;FDTRow]*</item>
  /// <item>FDTRow   ::= Input =&gt; Output | Output &lt;= Input</item>
  /// <item>Input    ::= ParameterName: Value [, Input]*</item>
  /// <item>Output   ::= [ParameterName: Value]* {halt|stop|void|nothing|Value}</item>
  /// <item>Value    ::= true | false | null | notnull | canbenull</item>
  /// </list>
  /// If method has single input parameter, it's name could be omitted.<br/>
  /// Using <c>halt</c> (or <c>void</c>/<c>nothing</c>, which is the same) for method output
  /// means that the methos doesn't return normally (throws or terminates the process).<br/>
  /// Value <c>canbenull</c> is only applicable for output parameters.<br/>
  /// You can use multiple <c>[ContractAnnotation]</c> for each FDT row, or use single attribute
  /// with rows separated by semicolon. There is no notion of order rows, all rows are checked
  /// for applicability and applied per each program state tracked by R# analysis.<br/>
  /// </syntax>
  /// <examples><list>
  /// <item><code>
  /// [ContractAnnotation("=&gt; halt")]
  /// public void TerminationMethod()
  /// </code></item>
  /// <item><code>
  /// [ContractAnnotation("halt &lt;= condition: false")]
  /// public void Assert(bool condition, string text) // regular assertion method
  /// </code></item>
  /// <item><code>
  /// [ContractAnnotation("s:null =&gt; true")]
  /// public bool IsNullOrEmpty(string s) // string.IsNullOrEmpty()
  /// </code></item>
  /// <item><code>
  /// // A method that returns null if the parameter is null,
  /// // and not null if the parameter is not null
  /// [ContractAnnotation("null =&gt; null; notnull =&gt; notnull")]
  /// public object Transform(object data) 
  /// </code></item>
  /// <item><code>
  /// [ContractAnnotation("=&gt; true, result: notnull; =&gt; false, result: null")]
  /// public bool TryParse(string s, out Person result)
  /// </code></item>
  /// </list></examples>
  [AttributeUsage(AttributeTargets.Method, AllowMultiple = true)]
  public sealed class ContractAnnotationAttribute : Attribute
  {
    public ContractAnnotationAttribute([NotNull] string contract)
      : this(contract, false) { }

    public ContractAnnotationAttribute([NotNull] string contract, bool forceFullStates)
    {
      Contract = contract;
      ForceFullStates = forceFullStates;
    }

    [NotNull] public string Contract { get; private set; }

    public bool ForceFullStates { get; private set; }
  }

  /// <summary>
  /// Indicates that marked element should be localized or not.
  /// </summary>
  /// <example><code>
  /// [LocalizationRequiredAttribute(true)]
  /// class Foo {
  ///   string str = "my string"; // Warning: Localizable string
  /// }
  /// </code></example>
  [AttributeUsage(AttributeTargets.All)]
  public sealed class LocalizationRequiredAttribute : Attribute
  {
    public LocalizationRequiredAttribute() : this(true) { }

    public LocalizationRequiredAttribute(bool required)
    {
      Required = required;
    }

    public bool Required { get; private set; }
  }

  /// <summary>
  /// Indicates that the value of the marked type (or its derivatives)
  /// cannot be compared using '==' or '!=' operators and <c>Equals()</c>
  /// should be used instead. However, using '==' or '!=' for comparison
  /// with <c>null</c> is always permitted.
  /// </summary>
  /// <example><code>
  /// [CannotApplyEqualityOperator]
  /// class NoEquality { }
  /// 
  /// class UsesNoEquality {
  ///   void Test() {
  ///     var ca1 = new NoEquality();
  ///     var ca2 = new NoEquality();
  ///     if (ca1 != null) { // OK
  ///       bool condition = ca1 == ca2; // Warning
  ///     }
  ///   }
  /// }
  /// </code></example>
  [AttributeUsage(AttributeTargets.Interface | AttributeTargets.Class | AttributeTargets.Struct)]
  public sealed class CannotApplyEqualityOperatorAttribute : Attribute { }

  /// <summary>
  /// When applied to a target attribute, specifies a requirement for any type marked
  /// with the target attribute to implement or inherit specific type or types.
  /// </summary>
  /// <example><code>
  /// [BaseTypeRequired(typeof(IComponent)] // Specify requirement
  /// class ComponentAttribute : Attribute { }
  /// 
  /// [Component] // ComponentAttribute requires implementing IComponent interface
  /// class MyComponent : IComponent { }
  /// </code></example>
  [AttributeUsage(AttributeTargets.Class, AllowMultiple = true)]
  [BaseTypeRequired(typeof(Attribute))]
  public sealed class BaseTypeRequiredAttribute : Attribute
  {
    public BaseTypeRequiredAttribute([NotNull] Type baseType)
    {
      BaseType = baseType;
    }

    [NotNull] public Type BaseType { get; private set; }
  }

  /// <summary>
  /// Indicates that the marked symbol is used implicitly (e.g. via reflection, in external library),
  /// so this symbol will not be marked as unused (as well as by other usage inspections).
  /// </summary>
  [AttributeUsage(AttributeTargets.All)]
  public sealed class UsedImplicitlyAttribute : Attribute
  {
    public UsedImplicitlyAttribute()
      : this(ImplicitUseKindFlags.Default, ImplicitUseTargetFlags.Default) { }

    public UsedImplicitlyAttribute(ImplicitUseKindFlags useKindFlags)
      : this(useKindFlags, ImplicitUseTargetFlags.Default) { }

    public UsedImplicitlyAttribute(ImplicitUseTargetFlags targetFlags)
      : this(ImplicitUseKindFlags.Default, targetFlags) { }

    public UsedImplicitlyAttribute(ImplicitUseKindFlags useKindFlags, ImplicitUseTargetFlags targetFlags)
    {
      UseKindFlags = useKindFlags;
      TargetFlags = targetFlags;
    }

    public ImplicitUseKindFlags UseKindFlags { get; private set; }

    public ImplicitUseTargetFlags TargetFlags { get; private set; }
  }

  /// <summary>
  /// Should be used on attributes and causes ReSharper to not mark symbols marked with such attributes
  /// as unused (as well as by other usage inspections)
  /// </summary>
  [AttributeUsage(AttributeTargets.Class | AttributeTargets.GenericParameter)]
  public sealed class MeansImplicitUseAttribute : Attribute
  {
    public MeansImplicitUseAttribute()
      : this(ImplicitUseKindFlags.Default, ImplicitUseTargetFlags.Default) { }

    public MeansImplicitUseAttribute(ImplicitUseKindFlags useKindFlags)
      : this(useKindFlags, ImplicitUseTargetFlags.Default) { }

    public MeansImplicitUseAttribute(ImplicitUseTargetFlags targetFlags)
      : this(ImplicitUseKindFlags.Default, targetFlags) { }

    public MeansImplicitUseAttribute(ImplicitUseKindFlags useKindFlags, ImplicitUseTargetFlags targetFlags)
    {
      UseKindFlags = useKindFlags;
      TargetFlags = targetFlags;
    }

    [UsedImplicitly] public ImplicitUseKindFlags UseKindFlags { get; private set; }

    [UsedImplicitly] public ImplicitUseTargetFlags TargetFlags { get; private set; }
  }

  [Flags]
  public enum ImplicitUseKindFlags
  {
    Default = Access | Assign | InstantiatedWithFixedConstructorSignature,
    /// <summary>Only entity marked with attribute considered used.</summary>
    Access = 1,
    /// <summary>Indicates implicit assignment to a member.</summary>
    Assign = 2,
    /// <summary>
    /// Indicates implicit instantiation of a type with fixed constructor signature.
    /// That means any unused constructor parameters won't be reported as such.
    /// </summary>
    InstantiatedWithFixedConstructorSignature = 4,
    /// <summary>Indicates implicit instantiation of a type.</summary>
    InstantiatedNoFixedConstructorSignature = 8,
  }

  /// <summary>
  /// Specify what is considered used implicitly when marked
  /// with <see cref="MeansImplicitUseAttribute"/> or <see cref="UsedImplicitlyAttribute"/>.
  /// </summary>
  [Flags]
  public enum ImplicitUseTargetFlags
  {
    Default = Itself,
    Itself = 1,
    /// <summary>Members of entity marked with attribute are considered used.</summary>
    Members = 2,
    /// <summary>Entity marked with attribute and all its members considered used.</summary>
    WithMembers = Itself | Members
  }

  /// <summary>
  /// This attribute is intended to mark publicly available API
  /// which should not be removed and so is treated as used.
  /// </summary>
  [MeansImplicitUse(ImplicitUseTargetFlags.WithMembers)]
  public sealed class PublicAPIAttribute : Attribute
  {
    public PublicAPIAttribute() { }

    public PublicAPIAttribute([NotNull] string comment)
    {
      Comment = comment;
    }

    [CanBeNull] public string Comment { get; private set; }
  }

  /// <summary>
  /// Tells code analysis engine if the parameter is completely handled when the invoked method is on stack.
  /// If the parameter is a delegate, indicates that delegate is executed while the method is executed.
  /// If the parameter is an enumerable, indicates that it is enumerated while the method is executed.
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter)]
  public sealed class InstantHandleAttribute : Attribute { }

  /// <summary>
  /// Indicates that a method does not make any observable state changes.
  /// The same as <c>System.Diagnostics.Contracts.PureAttribute</c>.
  /// </summary>
  /// <example><code>
  /// [Pure] int Multiply(int x, int y) => x * y;
  /// 
  /// void M() {
  ///   Multiply(123, 42); // Waring: Return value of pure method is not used
  /// }
  /// </code></example>
  [AttributeUsage(AttributeTargets.Method)]
  public sealed class PureAttribute : Attribute { }

  /// <summary>
  /// Indicates that the return value of method invocation must be used.
  /// </summary>
  [AttributeUsage(AttributeTargets.Method)]
  public sealed class MustUseReturnValueAttribute : Attribute
  {
    public MustUseReturnValueAttribute() { }

    public MustUseReturnValueAttribute([NotNull] string justification)
    {
      Justification = justification;
    }

    [CanBeNull] public string Justification { get; private set; }
  }

  /// <summary>
  /// Indicates the type member or parameter of some type, that should be used instead of all other ways
  /// to get the value that type. This annotation is useful when you have some "context" value evaluated
  /// and stored somewhere, meaning that all other ways to get this value must be consolidated with existing one.
  /// </summary>
  /// <example><code>
  /// class Foo {
  ///   [ProvidesContext] IBarService _barService = ...;
  /// 
  ///   void ProcessNode(INode node) {
  ///     DoSomething(node, node.GetGlobalServices().Bar);
  ///     //              ^ Warning: use value of '_barService' field
  ///   }
  /// }
  /// </code></example>
  [AttributeUsage(
    AttributeTargets.Field | AttributeTargets.Property | AttributeTargets.Parameter | AttributeTargets.Method |
    AttributeTargets.Class | AttributeTargets.Interface | AttributeTargets.Struct | AttributeTargets.GenericParameter)]
  public sealed class ProvidesContextAttribute : Attribute { }

  /// <summary>
  /// Indicates that a parameter is a path to a file or a folder within a web project.
  /// Path can be relative or absolute, starting from web root (~).
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter)]
  public sealed class PathReferenceAttribute : Attribute
  {
    public PathReferenceAttribute() { }

    public PathReferenceAttribute([NotNull, PathReference] string basePath)
    {
      BasePath = basePath;
    }

    [CanBeNull] public string BasePath { get; private set; }
  }

  /// <summary>
  /// An extension method marked with this attribute is processed by ReSharper code completion
  /// as a 'Source Template'. When extension method is completed over some expression, it's source code
  /// is automatically expanded like a template at call site.
  /// </summary>
  /// <remarks>
  /// Template method body can contain valid source code and/or special comments starting with '$'.
  /// Text inside these comments is added as source code when the template is applied. Template parameters
  /// can be used either as additional method parameters or as identifiers wrapped in two '$' signs.
  /// Use the <see cref="MacroAttribute"/> attribute to specify macros for parameters.
  /// </remarks>
  /// <example>
  /// In this example, the 'forEach' method is a source template available over all values
  /// of enumerable types, producing ordinary C# 'foreach' statement and placing caret inside block:
  /// <code>
  /// [SourceTemplate]
  /// public static void forEach&lt;T&gt;(this IEnumerable&lt;T&gt; xs) {
  ///   foreach (var x in xs) {
  ///      //$ $END$
  ///   }
  /// }
  /// </code>
  /// </example>
  [AttributeUsage(AttributeTargets.Method)]
  public sealed class SourceTemplateAttribute : Attribute { }

  /// <summary>
  /// Allows specifying a macro for a parameter of a <see cref="SourceTemplateAttribute">source template</see>.
  /// </summary>
  /// <remarks>
  /// You can apply the attribute on the whole method or on any of its additional parameters. The macro expression
  /// is defined in the <see cref="MacroAttribute.Expression"/> property. When applied on a method, the target
  /// template parameter is defined in the <see cref="MacroAttribute.Target"/> property. To apply the macro silently
  /// for the parameter, set the <see cref="MacroAttribute.Editable"/> property value = -1.
  /// </remarks>
  /// <example>
  /// Applying the attribute on a source template method:
  /// <code>
  /// [SourceTemplate, Macro(Target = "item", Expression = "suggestVariableName()")]
  /// public static void forEach&lt;T&gt;(this IEnumerable&lt;T&gt; collection) {
  ///   foreach (var item in collection) {
  ///     //$ $END$
  ///   }
  /// }
  /// </code>
  /// Applying the attribute on a template method parameter:
  /// <code>
  /// [SourceTemplate]
  /// public static void something(this Entity x, [Macro(Expression = "guid()", Editable = -1)] string newguid) {
  ///   /*$ var $x$Id = "$newguid$" + x.ToString();
  ///   x.DoSomething($x$Id); */
  /// }
  /// </code>
  /// </example>
  [AttributeUsage(AttributeTargets.Parameter | AttributeTargets.Method, AllowMultiple = true)]
  public sealed class MacroAttribute : Attribute
  {
    /// <summary>
    /// Allows specifying a macro that will be executed for a <see cref="SourceTemplateAttribute">source template</see>
    /// parameter when the template is expanded.
    /// </summary>
    [CanBeNull] public string Expression { get; set; }

    /// <summary>
    /// Allows specifying which occurrence of the target parameter becomes editable when the template is deployed.
    /// </summary>
    /// <remarks>
    /// If the target parameter is used several times in the template, only one occurrence becomes editable;
    /// other occurrences are changed synchronously. To specify the zero-based index of the editable occurrence,
    /// use values >= 0. To make the parameter non-editable when the template is expanded, use -1.
    /// </remarks>>
    public int Editable { get; set; }

    /// <summary>
    /// Identifies the target parameter of a <see cref="SourceTemplateAttribute">source template</see> if the
    /// <see cref="MacroAttribute"/> is applied on a template method.
    /// </summary>
    [CanBeNull] public string Target { get; set; }
  }

  [AttributeUsage(AttributeTargets.Assembly | AttributeTargets.Field | AttributeTargets.Property, AllowMultiple = true)]
  public sealed class AspMvcAreaMasterLocationFormatAttribute : Attribute
  {
    public AspMvcAreaMasterLocationFormatAttribute([NotNull] string format)
    {
      Format = format;
    }

    [NotNull] public string Format { get; private set; }
  }

  [AttributeUsage(AttributeTargets.Assembly | AttributeTargets.Field | AttributeTargets.Property, AllowMultiple = true)]
  public sealed class AspMvcAreaPartialViewLocationFormatAttribute : Attribute
  {
    public AspMvcAreaPartialViewLocationFormatAttribute([NotNull] string format)
    {
      Format = format;
    }

    [NotNull] public string Format { get; private set; }
  }

  [AttributeUsage(AttributeTargets.Assembly | AttributeTargets.Field | AttributeTargets.Property, AllowMultiple = true)]
  public sealed class AspMvcAreaViewLocationFormatAttribute : Attribute
  {
    public AspMvcAreaViewLocationFormatAttribute([NotNull] string format)
    {
      Format = format;
    }

    [NotNull] public string Format { get; private set; }
  }

  [AttributeUsage(AttributeTargets.Assembly | AttributeTargets.Field | AttributeTargets.Property, AllowMultiple = true)]
  public sealed class AspMvcMasterLocationFormatAttribute : Attribute
  {
    public AspMvcMasterLocationFormatAttribute([NotNull] string format)
    {
      Format = format;
    }

    [NotNull] public string Format { get; private set; }
  }

  [AttributeUsage(AttributeTargets.Assembly | AttributeTargets.Field | AttributeTargets.Property, AllowMultiple = true)]
  public sealed class AspMvcPartialViewLocationFormatAttribute : Attribute
  {
    public AspMvcPartialViewLocationFormatAttribute([NotNull] string format)
    {
      Format = format;
    }

    [NotNull] public string Format { get; private set; }
  }

  [AttributeUsage(AttributeTargets.Assembly | AttributeTargets.Field | AttributeTargets.Property, AllowMultiple = true)]
  public sealed class AspMvcViewLocationFormatAttribute : Attribute
  {
    public AspMvcViewLocationFormatAttribute([NotNull] string format)
    {
      Format = format;
    }

    [NotNull] public string Format { get; private set; }
  }

  /// <summary>
  /// ASP.NET MVC attribute. If applied to a parameter, indicates that the parameter
  /// is an MVC action. If applied to a method, the MVC action name is calculated
  /// implicitly from the context. Use this attribute for custom wrappers similar to
  /// <c>System.Web.Mvc.Html.ChildActionExtensions.RenderAction(HtmlHelper, String)</c>.
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter | AttributeTargets.Method)]
  public sealed class AspMvcActionAttribute : Attribute
  {
    public AspMvcActionAttribute() { }

    public AspMvcActionAttribute([NotNull] string anonymousProperty)
    {
      AnonymousProperty = anonymousProperty;
    }

    [CanBeNull] public string AnonymousProperty { get; private set; }
  }

  /// <summary>
  /// ASP.NET MVC attribute. Indicates that a parameter is an MVC area.
  /// Use this attribute for custom wrappers similar to
  /// <c>System.Web.Mvc.Html.ChildActionExtensions.RenderAction(HtmlHelper, String)</c>.
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter)]
  public sealed class AspMvcAreaAttribute : Attribute
  {
    public AspMvcAreaAttribute() { }

    public AspMvcAreaAttribute([NotNull] string anonymousProperty)
    {
      AnonymousProperty = anonymousProperty;
    }

    [CanBeNull] public string AnonymousProperty { get; private set; }
  }

  /// <summary>
  /// ASP.NET MVC attribute. If applied to a parameter, indicates that the parameter is
  /// an MVC controller. If applied to a method, the MVC controller name is calculated
  /// implicitly from the context. Use this attribute for custom wrappers similar to
  /// <c>System.Web.Mvc.Html.ChildActionExtensions.RenderAction(HtmlHelper, String, String)</c>.
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter | AttributeTargets.Method)]
  public sealed class AspMvcControllerAttribute : Attribute
  {
    public AspMvcControllerAttribute() { }

    public AspMvcControllerAttribute([NotNull] string anonymousProperty)
    {
      AnonymousProperty = anonymousProperty;
    }

    [CanBeNull] public string AnonymousProperty { get; private set; }
  }

  /// <summary>
  /// ASP.NET MVC attribute. Indicates that a parameter is an MVC Master. Use this attribute
  /// for custom wrappers similar to <c>System.Web.Mvc.Controller.View(String, String)</c>.
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter)]
  public sealed class AspMvcMasterAttribute : Attribute { }

  /// <summary>
  /// ASP.NET MVC attribute. Indicates that a parameter is an MVC model type. Use this attribute
  /// for custom wrappers similar to <c>System.Web.Mvc.Controller.View(String, Object)</c>.
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter)]
  public sealed class AspMvcModelTypeAttribute : Attribute { }

  /// <summary>
  /// ASP.NET MVC attribute. If applied to a parameter, indicates that the parameter is an MVC
  /// partial view. If applied to a method, the MVC partial view name is calculated implicitly
  /// from the context. Use this attribute for custom wrappers similar to
  /// <c>System.Web.Mvc.Html.RenderPartialExtensions.RenderPartial(HtmlHelper, String)</c>.
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter | AttributeTargets.Method)]
  public sealed class AspMvcPartialViewAttribute : Attribute { }

  /// <summary>
  /// ASP.NET MVC attribute. Allows disabling inspections for MVC views within a class or a method.
  /// </summary>
  [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method)]
  public sealed class AspMvcSuppressViewErrorAttribute : Attribute { }

  /// <summary>
  /// ASP.NET MVC attribute. Indicates that a parameter is an MVC display template.
  /// Use this attribute for custom wrappers similar to 
  /// <c>System.Web.Mvc.Html.DisplayExtensions.DisplayForModel(HtmlHelper, String)</c>.
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter)]
  public sealed class AspMvcDisplayTemplateAttribute : Attribute { }

  /// <summary>
  /// ASP.NET MVC attribute. Indicates that a parameter is an MVC editor template.
  /// Use this attribute for custom wrappers similar to
  /// <c>System.Web.Mvc.Html.EditorExtensions.EditorForModel(HtmlHelper, String)</c>.
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter)]
  public sealed class AspMvcEditorTemplateAttribute : Attribute { }

  /// <summary>
  /// ASP.NET MVC attribute. Indicates that a parameter is an MVC template.
  /// Use this attribute for custom wrappers similar to
  /// <c>System.ComponentModel.DataAnnotations.UIHintAttribute(System.String)</c>.
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter)]
  public sealed class AspMvcTemplateAttribute : Attribute { }

  /// <summary>
  /// ASP.NET MVC attribute. If applied to a parameter, indicates that the parameter
  /// is an MVC view component. If applied to a method, the MVC view name is calculated implicitly
  /// from the context. Use this attribute for custom wrappers similar to
  /// <c>System.Web.Mvc.Controller.View(Object)</c>.
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter | AttributeTargets.Method)]
  public sealed class AspMvcViewAttribute : Attribute { }

  /// <summary>
  /// ASP.NET MVC attribute. If applied to a parameter, indicates that the parameter
  /// is an MVC view component name.
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter)]
  public sealed class AspMvcViewComponentAttribute : Attribute { }

  /// <summary>
  /// ASP.NET MVC attribute. If applied to a parameter, indicates that the parameter
  /// is an MVC view component view. If applied to a method, the MVC view component view name is default.
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter | AttributeTargets.Method)]
  public sealed class AspMvcViewComponentViewAttribute : Attribute { }

  /// <summary>
  /// ASP.NET MVC attribute. When applied to a parameter of an attribute,
  /// indicates that this parameter is an MVC action name.
  /// </summary>
  /// <example><code>
  /// [ActionName("Foo")]
  /// public ActionResult Login(string returnUrl) {
  ///   ViewBag.ReturnUrl = Url.Action("Foo"); // OK
  ///   return RedirectToAction("Bar"); // Error: Cannot resolve action
  /// }
  /// </code></example>
  [AttributeUsage(AttributeTargets.Parameter | AttributeTargets.Property)]
  public sealed class AspMvcActionSelectorAttribute : Attribute { }

  [AttributeUsage(AttributeTargets.Parameter | AttributeTargets.Property | AttributeTargets.Field)]
  public sealed class HtmlElementAttributesAttribute : Attribute
  {
    public HtmlElementAttributesAttribute() { }

    public HtmlElementAttributesAttribute([NotNull] string name)
    {
      Name = name;
    }

    [CanBeNull] public string Name { get; private set; }
  }

  [AttributeUsage(AttributeTargets.Parameter | AttributeTargets.Field | AttributeTargets.Property)]
  public sealed class HtmlAttributeValueAttribute : Attribute
  {
    public HtmlAttributeValueAttribute([NotNull] string name)
    {
      Name = name;
    }

    [NotNull] public string Name { get; private set; }
  }

  /// <summary>
  /// Razor attribute. Indicates that a parameter or a method is a Razor section.
  /// Use this attribute for custom wrappers similar to 
  /// <c>System.Web.WebPages.WebPageBase.RenderSection(String)</c>.
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter | AttributeTargets.Method)]
  public sealed class RazorSectionAttribute : Attribute { }

  /// <summary>
  /// Indicates how method, constructor invocation or property access
  /// over collection type affects content of the collection.
  /// </summary>
  [AttributeUsage(AttributeTargets.Method | AttributeTargets.Constructor | AttributeTargets.Property)]
  public sealed class CollectionAccessAttribute : Attribute
  {
    public CollectionAccessAttribute(CollectionAccessType collectionAccessType)
    {
      CollectionAccessType = collectionAccessType;
    }

    public CollectionAccessType CollectionAccessType { get; private set; }
  }

  [Flags]
  public enum CollectionAccessType
  {
    /// <summary>Method does not use or modify content of the collection.</summary>
    None = 0,
    /// <summary>Method only reads content of the collection but does not modify it.</summary>
    Read = 1,
    /// <summary>Method can change content of the collection but does not add new elements.</summary>
    ModifyExistingContent = 2,
    /// <summary>Method can add new elements to the collection.</summary>
    UpdatedContent = ModifyExistingContent | 4
  }

  /// <summary>
  /// Indicates that the marked method is assertion method, i.e. it halts control flow if
  /// one of the conditions is satisfied. To set the condition, mark one of the parameters with 
  /// <see cref="AssertionConditionAttribute"/> attribute.
  /// </summary>
  [AttributeUsage(AttributeTargets.Method)]
  public sealed class AssertionMethodAttribute : Attribute { }

  /// <summary>
  /// Indicates the condition parameter of the assertion method. The method itself should be
  /// marked by <see cref="AssertionMethodAttribute"/> attribute. The mandatory argument of
  /// the attribute is the assertion type.
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter)]
  public sealed class AssertionConditionAttribute : Attribute
  {
    public AssertionConditionAttribute(AssertionConditionType conditionType)
    {
      ConditionType = conditionType;
    }

    public AssertionConditionType ConditionType { get; private set; }
  }

  /// <summary>
  /// Specifies assertion type. If the assertion method argument satisfies the condition,
  /// then the execution continues. Otherwise, execution is assumed to be halted.
  /// </summary>
  public enum AssertionConditionType
  {
    /// <summary>Marked parameter should be evaluated to true.</summary>
    IS_TRUE = 0,
    /// <summary>Marked parameter should be evaluated to false.</summary>
    IS_FALSE = 1,
    /// <summary>Marked parameter should be evaluated to null value.</summary>
    IS_NULL = 2,
    /// <summary>Marked parameter should be evaluated to not null value.</summary>
    IS_NOT_NULL = 3,
  }

  /// <summary>
  /// Indicates that the marked method unconditionally terminates control flow execution.
  /// For example, it could unconditionally throw exception.
  /// </summary>
  [Obsolete("Use [ContractAnnotation('=> halt')] instead")]
  [AttributeUsage(AttributeTargets.Method)]
  public sealed class TerminatesProgramAttribute : Attribute { }

  /// <summary>
  /// Indicates that method is pure LINQ method, with postponed enumeration (like Enumerable.Select,
  /// .Where). This annotation allows inference of [InstantHandle] annotation for parameters
  /// of delegate type by analyzing LINQ method chains.
  /// </summary>
  [AttributeUsage(AttributeTargets.Method)]
  public sealed class LinqTunnelAttribute : Attribute { }

  /// <summary>
  /// Indicates that IEnumerable, passed as parameter, is not enumerated.
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter)]
  public sealed class NoEnumerationAttribute : Attribute { }

  /// <summary>
  /// Indicates that parameter is regular expression pattern.
  /// </summary>
  [AttributeUsage(AttributeTargets.Parameter)]
  public sealed class RegexPatternAttribute : Attribute { }

  /// <summary>
  /// Prevents the Member Reordering feature from tossing members of the marked class.
  /// </summary>
  /// <remarks>
  /// The attribute must be mentioned in your member reordering patterns
  /// </remarks>
  [AttributeUsage(
    AttributeTargets.Class | AttributeTargets.Interface | AttributeTargets.Struct | AttributeTargets.Enum)]
  public sealed class NoReorderAttribute : Attribute { }

  /// <summary>
  /// XAML attribute. Indicates the type that has <c>ItemsSource</c> property and should be treated
  /// as <c>ItemsControl</c>-derived type, to enable inner items <c>DataContext</c> type resolve.
  /// </summary>
  [AttributeUsage(AttributeTargets.Class)]
  public sealed class XamlItemsControlAttribute : Attribute { }

  /// <summary>
  /// XAML attribute. Indicates the property of some <c>BindingBase</c>-derived type, that
  /// is used to bind some item of <c>ItemsControl</c>-derived type. This annotation will
  /// enable the <c>DataContext</c> type resolve for XAML bindings for such properties.
  /// </summary>
  /// <remarks>
  /// Property should have the tree ancestor of the <c>ItemsControl</c> type or
  /// marked with the <see cref="XamlItemsControlAttribute"/> attribute.
  /// </remarks>
  [AttributeUsage(AttributeTargets.Property)]
  public sealed class XamlItemBindingOfItemsControlAttribute : Attribute { }

  [AttributeUsage(AttributeTargets.Class, AllowMultiple = true)]
  public sealed class AspChildControlTypeAttribute : Attribute
  {
    public AspChildControlTypeAttribute([NotNull] string tagName, [NotNull] Type controlType)
    {
      TagName = tagName;
      ControlType = controlType;
    }

    [NotNull] public string TagName { get; private set; }

    [NotNull] public Type ControlType { get; private set; }
  }

  [AttributeUsage(AttributeTargets.Property | AttributeTargets.Method)]
  public sealed class AspDataFieldAttribute : Attribute { }

  [AttributeUsage(AttributeTargets.Property | AttributeTargets.Method)]
  public sealed class AspDataFieldsAttribute : Attribute { }

  [AttributeUsage(AttributeTargets.Property)]
  public sealed class AspMethodPropertyAttribute : Attribute { }

  [AttributeUsage(AttributeTargets.Class, AllowMultiple = true)]
  public sealed class AspRequiredAttributeAttribute : Attribute
  {
    public AspRequiredAttributeAttribute([NotNull] string attribute)
    {
      Attribute = attribute;
    }

    [NotNull] public string Attribute { get; private set; }
  }

  [AttributeUsage(AttributeTargets.Property)]
  public sealed class AspTypePropertyAttribute : Attribute
  {
    public bool CreateConstructorReferences { get; private set; }

    public AspTypePropertyAttribute(bool createConstructorReferences)
    {
      CreateConstructorReferences = createConstructorReferences;
    }
  }

  [AttributeUsage(AttributeTargets.Assembly, AllowMultiple = true)]
  public sealed class RazorImportNamespaceAttribute : Attribute
  {
    public RazorImportNamespaceAttribute([NotNull] string name)
    {
      Name = name;
    }

    [NotNull] public string Name { get; private set; }
  }

  [AttributeUsage(AttributeTargets.Assembly, AllowMultiple = true)]
  public sealed class RazorInjectionAttribute : Attribute
  {
    public RazorInjectionAttribute([NotNull] string type, [NotNull] string fieldName)
    {
      Type = type;
      FieldName = fieldName;
    }

    [NotNull] public string Type { get; private set; }

    [NotNull] public string FieldName { get; private set; }
  }

  [AttributeUsage(AttributeTargets.Assembly, AllowMultiple = true)]
  public sealed class RazorDirectiveAttribute : Attribute
  {
    public RazorDirectiveAttribute([NotNull] string directive)
    {
      Directive = directive;
    }

    [NotNull] public string Directive { get; private set; }
  }

  [AttributeUsage(AttributeTargets.Assembly, AllowMultiple = true)]
  public sealed class RazorPageBaseTypeAttribute : Attribute
  {
      public RazorPageBaseTypeAttribute([NotNull] string baseType)
      {
        BaseType = baseType;
      }
      public RazorPageBaseTypeAttribute([NotNull] string baseType, string pageName)
      {
          BaseType = baseType;
          PageName = pageName;
      }

      [NotNull] public string BaseType { get; private set; }
      [CanBeNull] public string PageName { get; private set; }
  }
    
  [AttributeUsage(AttributeTargets.Method)]
  public sealed class RazorHelperCommonAttribute : Attribute { }

  [AttributeUsage(AttributeTargets.Property)]
  public sealed class RazorLayoutAttribute : Attribute { }

  [AttributeUsage(AttributeTargets.Method)]
  public sealed class RazorWriteLiteralMethodAttribute : Attribute { }

  [AttributeUsage(AttributeTargets.Method)]
  public sealed class RazorWriteMethodAttribute : Attribute { }

  [AttributeUsage(AttributeTargets.Parameter)]
  public sealed class RazorWriteMethodParameterAttribute : Attribute { }
}

================================================
FILE: StickyNotes/Properties/AssemblyInfo.cs
================================================
using System.Reflection;
using System.Resources;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Windows;

// 有关程序集的一般信息由以下
// 控制。更改这些特性值可修改
// 与程序集关联的信息。
[assembly: AssemblyTitle("StickyNotes")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("StickyNotes")]
[assembly: AssemblyCopyright("Copyright ©  2019")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]

// 将 ComVisible 设置为 false 会使此程序集中的类型
//对 COM 组件不可见。如果需要从 COM 访问此程序集中的类型
//请将此类型的 ComVisible 特性设置为 true。
[assembly: ComVisible(false)]

//若要开始生成可本地化的应用程序,请设置
//.csproj 文件中的 <UICulture>CultureYouAreCodingWith</UICulture>
//例如,如果您在源文件中使用的是美国英语,
//使用的是美国英语,请将 <UICulture> 设置为 en-US。  然后取消
//对以下 NeutralResourceLanguage 特性的注释。  更新
//以下行中的“en-US”以匹配项目文件中的 UICulture 设置。

//[assembly: NeutralResourcesLanguage("en-US", UltimateResourceFallbackLocation.Satellite)]


[assembly: ThemeInfo(
    ResourceDictionaryLocation.None, //主题特定资源词典所处位置
                                     //(未在页面中找到资源时使用,
                                     //或应用程序资源字典中找到时使用)
    ResourceDictionaryLocation.SourceAssembly //常规资源词典所处位置
                                              //(未在页面中找到资源时使用,
                                              //、应用程序或任何主题专用资源字典中找到时使用)
)]


// 程序集的版本信息由下列四个值组成: 
//
//      主版本
//      次版本
//      生成号
//      修订号
//
// 可以指定所有值,也可以使用以下所示的 "*" 预置版本号和修订号
// 方法是按如下所示使用“*”: :
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: log4net.Config.XmlConfigurator(Watch = true)]

================================================
FILE: StickyNotes/Properties/Resources.Designer.cs
================================================
//------------------------------------------------------------------------------
// <auto-generated>
//     This code was generated by a tool.
//     Runtime Version:4.0.30319.42000
//
//     Changes to this file may cause incorrect behavior and will be lost if
//     the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------

namespace StickyNotes.Properties {
    using System;
    
    
    /// <summary>
    ///   A strongly-typed resource class, for looking up localized strings, etc.
    /// </summary>
    // This class was auto-generated by the StronglyTypedResourceBuilder
    // class via a tool like ResGen or Visual Studio.
    // To add or remove a member, edit your .ResX file then rerun ResGen
    // with the /str option, or rebuild your VS project.
    [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "17.0.0.0")]
    [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
    [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
    public class Resources {
        
        private static global::System.Resources.ResourceManager resourceMan;
        
        private static global::System.Globalization.CultureInfo resourceCulture;
        
        [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
        internal Resources() {
        }
        
        /// <summary>
        ///   Returns the cached ResourceManager instance used by this class.
        /// </summary>
        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
        public static global::System.Resources.ResourceManager ResourceManager {
            get {
                if (object.ReferenceEquals(resourceMan, null)) {
                    global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("StickyNotes.Properties.Resources", typeof(Resources).Assembly);
                    resourceMan = temp;
                }
                return resourceMan;
            }
        }
        
        /// <summary>
        ///   Overrides the current thread's CurrentUICulture property for all
        ///   resource lookups using this strongly typed resource class.
        /// </summary>
        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
        public static global::System.Globalization.CultureInfo Culture {
            get {
                return resourceCulture;
            }
            set {
                resourceCulture = value;
            }
        }
        
        /// <summary>
        ///   Looks up a localized string similar to http://stickynotes.lizhenghao.site/api.
        /// </summary>
        public static string ServerUrl {
            get {
                return ResourceManager.GetString("ServerUrl", resourceCulture);
            }
        }
        
        /// <summary>
        ///   Looks up a localized string similar to .
        /// </summary>
        public static string String1 {
            get {
                return ResourceManager.GetString("String1", resourceCulture);
            }
        }
        
        /// <summary>
        ///   Looks up a localized string similar to v4.8.0.
        /// </summary>
        public static string Version {
            get {
                return ResourceManager.GetString("Version", resourceCulture);
            }
        }
        
        /// <summary>
        ///   Looks up a localized string similar to version.json.
        /// </summary>
        public static string VersionFileName {
            get {
                return ResourceManager.GetString("VersionFileName", resourceCulture);
            }
        }
    }
}


================================================
FILE: StickyNotes/Properties/Resources.resx
================================================
<?xml version="1.0" encoding="utf-8"?>
<root>
  <!-- 
    Microsoft ResX Schema 
    
    Version 2.0
    
    The primary goals of this format is to allow a simple XML format 
    that is mostly human readable. The generation and parsing of the 
    various data types are done through the TypeConverter classes 
    associated with the data types.
    
    Example:
    
    ... ado.net/XML headers & schema ...
    <resheader name="resmimetype">text/microsoft-resx</resheader>
    <resheader name="version">2.0</resheader>
    <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
    <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
    <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
    <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
    <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
        <value>[base64 mime encoded serialized .NET Framework object]</value>
    </data>
    <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
        <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
        <comment>This is a comment</comment>
    </data>
                
    There are any number of "resheader" rows that contain simple 
    name/value pairs.
    
    Each data row contains a name, and value. The row also contains a 
    type or mimetype. Type corresponds to a .NET class that support 
    text/value conversion through the TypeConverter architecture. 
    Classes that don't support this are serialized and stored with the 
    mimetype set.
    
    The mimetype is used for serialized objects, and tells the 
    ResXResourceReader how to depersist the object. This is currently not 
    extensible. For a given mimetype the value must be set accordingly:
    
    Note - application/x-microsoft.net.object.binary.base64 is the format 
    that the ResXResourceWriter will generate, however the reader can 
    read any of the formats listed below.
    
    mimetype: application/x-microsoft.net.object.binary.base64
    value   : The object must be serialized with 
            : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
            : and then encoded with base64 encoding.
    
    mimetype: application/x-microsoft.net.object.soap.base64
    value   : The object must be serialized with 
            : System.Runtime.Serialization.Formatters.Soap.SoapFormatter
            : and then encoded with base64 encoding.

    mimetype: application/x-microsoft.net.object.bytearray.base64
    value   : The object must be serialized into a byte array 
            : using a System.ComponentModel.TypeConverter
            : and then encoded with base64 encoding.
    -->
  <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
    <xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
    <xsd:element name="root" msdata:IsDataSet="true">
      <xsd:complexType>
        <xsd:choice maxOccurs="unbounded">
          <xsd:element name="metadata">
            <xsd:complexType>
              <xsd:sequence>
                <xsd:element name="value" type="xsd:string" minOccurs="0" />
              </xsd:sequence>
              <xsd:attribute name="name" use="required" type="xsd:string" />
              <xsd:attribute name="type" type="xsd:string" />
              <xsd:attribute name="mimetype" type="xsd:string" />
              <xsd:attribute ref="xml:space" />
            </xsd:complexType>
          </xsd:element>
          <xsd:element name="assembly">
            <xsd:complexType>
              <xsd:attribute name="alias" type="xsd:string" />
              <xsd:attribute name="name" type="xsd:string" />
            </xsd:complexType>
          </xsd:element>
          <xsd:element name="data">
            <xsd:complexType>
              <xsd:sequence>
                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
                <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
              </xsd:sequence>
              <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
              <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
              <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
              <xsd:attribute ref="xml:space" />
            </xsd:complexType>
          </xsd:element>
          <xsd:element name="resheader">
            <xsd:complexType>
              <xsd:sequence>
                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
              </xsd:sequence>
              <xsd:attribute name="name" type="xsd:string" use="required" />
            </xsd:complexType>
          </xsd:element>
        </xsd:choice>
      </xsd:complexType>
    </xsd:element>
  </xsd:schema>
  <resheader name="resmimetype">
    <value>text/microsoft-resx</value>
  </resheader>
  <resheader name="version">
    <value>2.0</value>
  </resheader>
  <resheader name="reader">
    <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
  </resheader>
  <resheader name="writer">
    <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
  </resheader>
  <data name="ServerUrl" xml:space="preserve">
    <value>http://stickynotes.lizhenghao.site/api</value>
  </data>
  <data name="String1" xml:space="preserve">
    <value />
  </data>
  <data name="Version" xml:space="preserve">
    <value>v4.8.0</value>
    <comment>程序版本</comment>
  </data>
  <data name="VersionFileName" xml:space="preserve">
    <value>version.json</value>
  </data>
</root>

================================================
FILE: StickyNotes/Properties/Settings.Designer.cs
================================================
//------------------------------------------------------------------------------
// <auto-generated>
//     This code was generated by a tool.
//     Runtime Version:4.0.30319.42000
//
//     Changes to this file may cause incorrect behavior and will be lost if
//     the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------

namespace StickyNotes.Properties {
    
    
    [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
    [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "17.2.0.0")]
    internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
        
        private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
        
        public static Settings Default {
            get {
                return defaultInstance;
            }
        }
    }
}


================================================
FILE: StickyNotes/Properties/Settings.settings
================================================
<?xml version='1.0' encoding='utf-8'?>
<SettingsFile xmlns="uri:settings" CurrentProfile="(Default)">
  <Profiles>
    <Profile Name="(Default)" />
  </Profiles>
  <Settings />
</SettingsFile>

================================================
FILE: StickyNotes/StickyNotes.csproj
================================================
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
  <PropertyGroup>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
    <ProjectGuid>{8E1B2A13-29D3-47DB-A48D-E0D795F29C3C}</ProjectGuid>
    <OutputType>WinExe</OutputType>
    <RootNamespace>StickyNotes</RootNamespace>
    <AssemblyName>StickyNotes</AssemblyName>
    <TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
    <FileAlignment>512</FileAlignment>
    <ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
    <WarningLevel>4</WarningLevel>
    <AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
    <Deterministic>true</Deterministic>
    <NuGetPackageImportStamp>
    </NuGetPackageImportStamp>
    <IsWebBootstrapper>false</IsWebBootstrapper>
    <PublishUrl>C:\Users\lizhenghao\Downloads\</PublishUrl>
    <Install>true</Install>
    <InstallFrom>Disk</InstallFrom>
    <UpdateEnabled>false</UpdateEnabled>
    <UpdateMode>Foreground</UpdateMode>
    <UpdateInterval>7</UpdateInterval>
    <UpdateIntervalUnits>Days</UpdateIntervalUnits>
    <UpdatePeriodically>false</UpdatePeriodically>
    <UpdateRequired>false</UpdateRequired>
    <MapFileExtensions>true</MapFileExtensions>
    <ApplicationRevision>3</ApplicationRevision>
    <ApplicationVersion>1.0.0.%2a</ApplicationVersion>
    <UseApplicationTrust>false</UseApplicationTrust>
    <PublishWizardCompleted>true</PublishWizardCompleted>
    <BootstrapperEnabled>true</BootstrapperEnabled>
    <TargetFrameworkProfile />
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
    <PlatformTarget>AnyCPU</PlatformTarget>
    <DebugSymbols>true</DebugSymbols>
    <DebugType>full</DebugType>
    <Optimize>false</Optimize>
    <OutputPath>..\Build\</OutputPath>
    <DefineConstants>DEBUG;TRACE</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
    <PlatformTarget>AnyCPU</PlatformTarget>
    <DebugType>pdbonly</DebugType>
    <Optimize>true</Optimize>
    <OutputPath>..\Build\</OutputPath>
    <DefineConstants>TRACE</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
  </PropertyGroup>
  <PropertyGroup>
    <StartupObject>
    </StartupObject>
  </PropertyGroup>
  <PropertyGroup>
    <ApplicationIcon>MyLogo.ico</ApplicationIcon>
  </PropertyGroup>
  <PropertyGroup>
    <ManifestCertificateThumbprint>27CDE8CF70EFD6B5322195ECFD65BA3D8854A3C8</ManifestCertificateThumbprint>
  </PropertyGroup>
  <PropertyGroup>
    <ManifestKeyFile>
    </ManifestKeyFile>
  </PropertyGroup>
  <PropertyGroup>
    <GenerateManifests>false</GenerateManifests>
  </PropertyGroup>
  <PropertyGroup>
    <SignManifests>false</SignManifests>
  </PropertyGroup>
  <PropertyGroup>
    <SignAssembly>false</SignAssembly>
  </PropertyGroup>
  <PropertyGroup>
    <AssemblyOriginatorKeyFile>
    </AssemblyOriginatorKeyFile>
  </PropertyGroup>
  <PropertyGroup />
  <PropertyGroup>
    <TargetZone>LocalIntranet</TargetZone>
  </PropertyGroup>
  <ItemGroup>
    <Reference Include="System" />
    <Reference Include="System.Data" />
    <Reference Include="System.Drawing" />
    <Reference Include="System.Windows.Forms" />
    <Reference Include="System.Xml" />
    <Reference Include="Microsoft.CSharp" />
    <Reference Include="System.Core" />
    <Reference Include="System.Xml.Linq" />
    <Reference Include="System.Data.DataSetExtensions" />
    <Reference Include="System.Net.Http" />
    <Reference Include="System.Xaml">
      <RequiredTargetFramework>4.0</RequiredTargetFramework>
    </Reference>
    <Reference Include="WindowsBase" />
    <Reference Include="PresentationCore" />
    <Reference Include="PresentationFramework" />
  </ItemGroup>
  <ItemGroup>
    <ApplicationDefinition Include="App.xaml">
      <Generator>MSBuild:Compile</Generator>
      <SubType>Designer</SubType>
    </ApplicationDefinition>
    <Compile Include="Converter\DateTimeToVisibilityConverter.cs" />
    <Compile Include="Converter\boolToVisibilityConverter.cs" />
    <Compile Include="Converter\DeleteWindowMessageConverter.cs" />
    <Compile Include="Converter\LanguageConverter.cs" />
    <Compile Include="Converter\ShowAllHotKeyConverter.cs" />
    <Compile Include="Converter\ThemeConverter.cs" />
    <Compile Include="Data\ConstData.cs" />
    <Compile Include="Properties\Annotations.cs" />
    <Compile Include="UserControl\CardItem.xaml.cs">
      <DependentUpon>CardItem.xaml</DependentUpon>
    </Compile>
    <Compile Include="UserControl\CustomWarningDialog.xaml.cs">
      <DependentUpon>CustomWarningDialog.xaml</DependentUpon>
    </Compile>
    <Compile Include="Utils\DataHelper.cs" />
    <Compile Include="Utils\HotKeyUtil\HotKey.cs" />
    <Compile Include="Utils\HotKeyUtil\HotkeyEventArgs.cs" />
    <Compile Include="Utils\HotKeyUtil\HotKeyHandler.cs" />
    <Compile Include="Utils\HotKeyUtil\HotKeyManager.cs" />
    <Compile Include="Utils\HotKeyUtil\HotKeySetting.cs" />
    <Compile Include="Utils\HotKeyUtil\NativeMethods.cs" />
    <Compile Include="Utils\Logger.cs" />
    <Compile Include="Utils\Messages\ChangeWindowMessage.cs" />
    <Compile Include="Utils\LanguageManager.cs" />
    <Compile Include="Utils\ThemeAssist.cs" />
    <Compile Include="Utils\TimerUtil.cs" />
    <Compile Include="Utils\UpdateHelper.cs" />
    <Compile Include="Utils\WindowHide.cs" />
    <Compile Include="ViewModel\ListWindowViewModel.cs" />
    <Compile Include="ViewModel\SettingViewModel.cs" />
    <Compile Include="View\AboutWindow.xaml.cs">
      <DependentUpon>AboutWindow.xaml</DependentUpon>
    </Compile>
    <Compile Include="Data\ProgramData.cs" />
    <Compile Include="Utils\Messages\SaveMessage.cs" />
    <Compile Include="Utils\SystemTray.cs" />
    <Compile Include="Data\WindowsData.cs" />
    <Compile Include="Utils\WindowsManager.cs" />
    <Compile Include="ViewModel\MainViewModel.cs" />
    <Compile Include="View\ListWindow.xaml.cs">
      <DependentUpon>ListWindow.xaml</DependentUpon>
    </Compile>
    <Compile Include="View\SettingWindow.xaml.cs">
      <DependentUpon>SettingWindow.xaml</DependentUpon>
    </Compile>
    <Compile Include="ViewModel\ViewModelLocator.cs" />
    <Page Include="Style\Languages\Lan-en.xaml">
      <Generator>MSBuild:Compile</Generator>
      <SubType>Designer</SubType>
    </Page>
    <Page Include="Style\Languages\Lan-cn.xaml">
      <SubType>Designer</SubType>
      <Generator>MSBuild:Compile</Generator>
    </Page>
    <Page Include="Style\Themes\甘蓝.xaml">
      <Generator>MSBuild:Compile</Generator>
      <SubType>Designer</SubType>
    </Page>
    <Page Include="Style\Themes\冷灰.xaml">
      <SubType>Designer</SubType>
      <Generator>MSBuild:Compile</Generator>
    </Page>
    <Page Include="Style\Themes\乌云灰.xaml">
      <Generator>MSBuild:Compile</Generator>
      <SubType>Designer</SubType>
    </Page>
    <Page Include="Style\Themes\石材灰.xaml">
      <Generator>MSBuild:Compile</Generator>
      <SubType>Designer</SubType>
    </Page>
    <Page Include="Style\Themes\田园褐.xaml">
      <SubType>Designer</SubType>
      <Generator>MSBuild:Compile</Generator>
    </Page>
    <Page Include="UserControl\CardItem.xaml">
      <Generator>MSBuild:Compile</Generator>
      <SubType>Designer</SubType>
    </Page>
    <Page Include="UserControl\CustomWarningDialog.xaml">
      <SubType>Designer</SubType>
      <Generator>MSBuild:Compile</Generator>
    </Page>
    <Page Include="View\ListWindow.xaml">
      <SubType>Designer</SubType>
      <Generator>MSBuild:Compile</Generator>
    </Page>
    <Page Include="View\MainWindow.xaml">
      <Generator>MSBuild:Compile</Generator>
      <SubType>Designer</SubType>
    </Page>
    <Compile Include="App.xaml.cs">
      <DependentUpon>App.xaml</DependentUpon>
      <SubType>Code</SubType>
    </Compile>
    <Compile Include="View\MainWindow.xaml.cs">
      <DependentUpon>MainWindow.xaml</DependentUpon>
      <SubType>Code</SubType>
    </Compile>
    <Page Include="View\AboutWindow.xaml">
      <Generator>MSBuild:Compile</Generator>
      <SubType>Designer</SubType>
    </Page>
    <Page Include="Style\Color.xaml">
      <SubType>Designer</SubType>
      <Generator>MSBuild:Compile</Generator>
    </Page>
    <Page Include="Style\Control.xaml">
      <SubType>Designer</SubType>
      <Generator>MSBuild:Compile</Generator>
    </Page>
    <Page Include="Style\Font.xaml">
      <SubType>Designer</SubType>
      <Generator>MSBuild:Compile</Generator>
    </Page>
    <Page Include="View\SettingWindow.xaml">
      <SubType>Designer</SubType>
      <Generator>MSBuild:Compile</Generator>
    </Page>
    <Page Include="Style\Label.xaml">
      <SubType>Designer</SubType>
      <Generator>MSBuild:Compile</Generator>
    </Page>
    <Page Include="Style\Window.xaml">
      <SubType>Designer</SubType>
      <Generator>MSBuild:Compile</Generator>
    </Page>
  </ItemGroup>
  <ItemGroup>
    <Compile Include="Properties\AssemblyInfo.cs">
      <SubType>Code</SubType>
    </Compile>
    <Compile Include="Properties\Resources.Designer.cs">
      <AutoGen>True</AutoGen>
      <DesignTime>True</DesignTime>
      <DependentUpon>Resources.resx</DependentUpon>
    </Compile>
    <Compile Include="Properties\Settings.Designer.cs">
      <AutoGen>True</AutoGen>
      <DependentUpon>Settings.settings</DependentUpon>
      <DesignTimeSharedInput>True</DesignTimeSharedInput>
    </Compile>
    <EmbeddedResource Include="Properties\Resources.resx">
      <Generator>PublicResXFileCodeGenerator</Generator>
      <LastGenOutput>Resources.Designer.cs</LastGenOutput>
    </EmbeddedResource>
    <None Include="Properties\Settings.settings">
      <Generator>SettingsSingleFileGenerator</Generator>
      <LastGenOutput>Settings.Designer.cs</LastGenOutput>
    </None>
    <Resource Include="Resources\Fonts\Lato-Black.ttf" />
    <Resource Include="Resources\Fonts\Lato-BlackItalic.ttf" />
    <Resource Include="Resources\Fonts\Lato-Bold.ttf" />
    <Resource Include="Resources\Fonts\Lato-BoldItalic.ttf" />
    <Resource Include="Resources\Fonts\Lato-Hairline.ttf" />
    <Resource Include="Resources\Fonts\Lato-HairlineItalic.ttf" />
    <Resource Include="Resources\Fonts\Lato-Heavy.ttf" />
    <Resource Include="Resources\Fonts\Lato-HeavyItalic.ttf" />
    <Resource Include="Resources\Fonts\Lato-Italic.ttf" />
    <Resource Include="Resources\Fonts\Lato-Light.ttf" />
    <Resource Include="Resources\Fonts\Lato-LightItalic.ttf" />
    <Resource Include="Resources\Fonts\Lato-Medium.ttf" />
    <Resource Include="Resources\Fonts\Lato-MediumItalic.ttf" />
    <Resource Include="Resources\Fonts\Lato-Regular.ttf" />
    <Resource Include="Resources\Fonts\Lato-Semibold.ttf" />
    <Resource Include="Resources\Fonts\Lato-SemiboldItalic.ttf" />
    <Resource Include="Resources\Fonts\Lato-Thin.ttf" />
    <Resource Include="Resources\Fonts\Lato-ThinItalic.ttf" />
  </ItemGroup>
  <ItemGroup>
    <None Include="App.config">
      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
    </None>
  </ItemGroup>
  <ItemGroup>
    <BootstrapperPackage Include=".NETFramework,Version=v4.6">
      <Visible>False</Visible>
      <ProductName>Microsoft .NET Framework 4.6 %28x86 and x64%29</ProductName>
      <Install>true</Install>
    </BootstrapperPackage>
    <BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
      <Visible>False</Visible>
      <ProductName>.NET Framework 3.5 SP1</ProductName>
      <Install>false</Install>
    </BootstrapperPackage>
  </ItemGroup>
  <ItemGroup>
    <Resource Include="MyLogo.ico">
      <CopyToOutputDirectory>Always</CopyToOutputDirectory>
    </Resource>
  </ItemGroup>
  <ItemGroup>
    <Resource Include="FodyWeavers.xml" />
  </ItemGroup>
  <ItemGroup>
    <PackageReference Include="CommonServiceLocator">
      <Version>2.0.2</Version>
    </PackageReference>
    <PackageReference Include="ControlzEx">
      <Version>5.0.1</Version>
    </PackageReference>
    <PackageReference Include="Costura.Fody">
      <Version>4.1.0</Version>
    </PackageReference>
    <PackageReference Include="Fody">
      <Version>6.0.0</Version>
      <IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
      <PrivateAssets>all</PrivateAssets>
    </PackageReference>
    <PackageReference Include="HandyControl">
      <Version>3.3.0</Version>
    </PackageReference>
    <PackageReference Include="log4net">
      <Version>2.0.14</Version>
    </PackageReference>
    <PackageReference Include="MahApps.Metro">
      <Version>2.4.7</Version>
    </PackageReference>
    <PackageReference Include="MahApps.Metro.IconPacks.Modern">
      <Version>4.11.0</Version>
    </PackageReference>
    <PackageReference Include="MaterialDesignColors">
      <Version>1.1.1</Version>
    </PackageReference>
    <PackageReference Include="MaterialDesignThemes">
      <Version>2.5.0.1205</Version>
    </PackageReference>
    <PackageReference Include="MvvmLight">
      <Version>5.4.1.1</Version>
    </PackageReference>
    <PackageReference Include="MvvmLightLibs">
      <Version>5.4.1.1</Version>
    </PackageReference>
    <PackageReference Include="Newtonsoft.Json">
      <Version>13.0.1</Version>
    </PackageReference>
    <PackageReference Include="PropertyChanged.Fody">
      <Version>2.6.0</Version>
    </PackageReference>
    <PackageReference Include="SqlSugar">
      <Version>5.0.9.1</Version>
    </PackageReference>
    <PackageReference Include="System.Data.SQLite">
      <Version>1.0.116</Version>
    </PackageReference>
  </ItemGroup>
  <ItemGroup>
    <ProjectReference Include="..\Common\Common.csproj">
      <Project>{EB437726-8891-46DE-9D88-271242DB82BC}</Project>
      <Name>Common</Name>
    </ProjectReference>
    <ProjectReference Include="..\Contract\Contract.csproj">
      <Project>{5CB7E208-C6E8-4593-BAF9-B8D396FBFE41}</Project>
      <Name>Contract</Name>
    </ProjectReference>
    <ProjectReference Include="..\DB\DB.csproj">
      <Project>{0E9DA473-F7C4-401B-B1AE-455313699794}</Project>
      <Name>DB</Name>
    </ProjectReference>
  </ItemGroup>
  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
</Project>

================================================
FILE: StickyNotes/Style/Color.xaml
================================================
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="clr-namespace:StickyNotes">

    <!--  蓝色主题  -->
    <Color x:Key="ForgroundColorBlue">#6495ED</Color>
    <Color x:Key="ForgroundColorBlue100">#6495CA</Color>
    <Color x:Key="BackgroundColorBlue">#F0F8FF</Color>

    <!--  灰色主题  -->
    <Color x:Key="BackgroundColorGray">#fafafa</Color>
    <Color x:Key="ForgroundColorGray">#757575</Color>
    <Color x:Key="ForgroundColorGray100">#DDFFFFFF</Color>


    <!--  橘黄色主题  -->
    <Color x:Key="BackgroundColorOrange">#fff3e0</Color>
    <Color x:Key="ForgroundColorOrange100">#ffe0b2</Color>
    <Color x:Key="ForgroundColorOrange">#ffd180</Color>

    <!-- <Color x:Key="Primary400">#ffa726</Color> -->

    <!-- <Color x:Key="Primary800Foreground">#FFFFFFFF</Color> -->
    <Color x:Key="ForgroundColorDefault">#dadbed</Color>
    <Color x:Key="ForgroundColorDefault100">#dadbed</Color>
    <Color x:Key="ForgroundColorDefault200">#dadbed</Color>
    <Color x:Key="BackgroundColorGrayDefault">#EEEEEE</Color>
    <Color x:Key="TitleColorGrayDefault">#DDDDDD</Color>
    <SolidColorBrush x:Key="GrayBackgroundDefault" Color="{StaticResource BackgroundColorGray}"></SolidColorBrush>
    <SolidColorBrush x:Key="PrimaryBrush" Color="Red"></SolidColorBrush>
    <SolidColorBrush x:Key="GrayTitleDefault" Color="{StaticResource TitleColorGrayDefault}"></SolidColorBrush>
    

</ResourceDictionary>

================================================
FILE: StickyNotes/Style/Control.xaml
================================================
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="clr-namespace:StickyNotes" xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes" xmlns:Converters="clr-namespace:MaterialDesignThemes.Wpf.Converters;assembly=MaterialDesignThemes.Wpf">
    <!--  菜单栏按钮模板  -->
    <Style x:Key="Button_Menu" TargetType="{x:Type Button}">
        <Setter Property="Width" Value="24" />
        <Setter Property="Height" Value="24" />
        <Setter Property="Margin" Value="2" />
        <Setter Property="BorderThickness" Value="0" />
        <Setter Property="Foreground" Value="Black" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Button}">
                    <Border
                        Background="Transparent"
                        x:Name="MyBackgroundElement"
                        BorderBrush="{DynamicResource MahApps.Brushes.Button.Border}"
                        BorderThickness="0">
                        <ContentPresenter
                            x:Name="ButtonContentPresenter"
                            HorizontalAlignment="Center"
                            VerticalAlignment="Center" />
                    </Border>
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsMouseOver" Value="True">
                            <Setter TargetName="MyBackgroundElement" Property="Background" Value="{DynamicResource MahApps.Brushes.Button.AccentedSquare.Background.MouseOver}" />
                            <Setter TargetName="MyBackgroundElement" Property="Opacity" Value="0.7" />
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
        <Setter Property="Cursor" Value="Hand" />
    </Style>



    <!--  富文本模板  -->
    <Style x:Key="RichText_Content" TargetType="{x:Type RichTextBox}">
        <Setter Property="FontFamily" Value="{StaticResource FontAwesome}" />
        <Setter Property="Padding" Value="0,5,0,0" />
        <Setter Property="Background" Value="AliceBlue" />
        <Setter Property="HorizontalAlignment" Value="Left" />
    </Style>
   
</ResourceDictionary>

================================================
FILE: StickyNotes/Style/Font.xaml
================================================
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:system="clr-namespace:System;assembly=mscorlib">

    <FontFamily x:Key="LatoThin">pack://application;,,,/Resources/Fonts/#Lato Thin</FontFamily>
    <FontFamily x:Key="LatoRegular">pack://application;,,,/Resources/Fonts/#Lato Regular</FontFamily>
    <FontFamily x:Key="LatoBold">pack://application;,,,/Resources/Fonts/#Lato Black</FontFamily>
    <FontFamily x:Key="FontAwesome">pack://application;,,,/Resources/Fonts/#FontAwesome</FontFamily>


    <system:Double x:Key="FontSizeSmaller">10</system:Double>
    <system:Double x:Key="FontSizeSmall">12</system:Double>
    <system:Double x:Key="FontSizeRegular">14</system:Double>
    <system:Double x:Key="FontSizeLarge">20</system:Double>
    <system:Double x:Key="FontSizeXLarge">24</system:Double>
    <system:Double x:Key="FontSizeXXLarge">30</system:Double>



    <system:String x:Key="FontAwesomeChatIcon">&#xf086;</system:String>
    <system:String x:Key="FontAwesomeUserIcon">&#xf007;</system:String>
    <system:String x:Key="FontAwesomePictureIcon">&#xf1c5;</system:String>
    <system:String x:Key="FontAwesomeCogIcon">&#xf013;</system:String>
    <system:String x:Key="FontAwesomeSearchIcon">&#xf002;</system:String>
    <system:String x:Key="FontAwesomeEllipsisIcon">&#xf141;</system:String>
    <system:String x:Key="FontAwesomeEllipsisVerticalIcon">&#xf142;</system:String>
    <system:String x:Key="FontAwesomePaperclipIcon">&#xf0c6;</system:String>
    <system:String x:Key="FontAwesomeEmojiIcon">&#xf118;</system:String>
    <system:String x:Key="FontAwesomeArrowLeftIcon">&#xf060;</system:String>
    <system:String x:Key="FontAwesomeTickIcon">&#xf00c;</system:String>
    <system:String x:Key="FontAwesomeCloseIcon">&#xf00d;</system:String>
</ResourceDictionary>


================================================
FILE: StickyNotes/Style/Label.xaml
================================================
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="clr-namespace:StickyNotes">
    <Style x:Key="TitleLabelStyle" TargetType="{x:Type Label}">
        <Setter Property="HorizontalAlignment" Value="Center" />
        <Setter Property="VerticalAlignment" Value="Center" />
        <Setter Property="FontSize" Value="18" />
        <Setter Property="Opacity" Value="0.6" />
        <Setter Property="FontFamily" Value="{StaticResource LatoRegular}" />
    </Style>
</ResourceDictionary>

================================================
FILE: StickyNotes/Style/Languages/Lan-cn.xaml
================================================
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:sys="clr-namespace:System;assembly=mscorlib">
    <sys:String x:Key="menuList">笔记列表</sys:String>
    <sys:String x:Key="menuSetting">设置</sys:String>
    <sys:String x:Key="menuAbout">关于</sys:String>
    <sys:String x:Key="setting-AllWindowTop">所有窗体置顶</sys:String>
    <sys:String x:Key="setting-AutoStartUp">开机自启动</sys:String>
    <sys:String x:Key="setting-AutoCheckUpdate">自动检查更新</sys:String>
    <sys:String x:Key="setting-Theme">主题颜色</sys:String>
    <sys:String x:Key="setting-ShortCut">快捷键</sys:String>
    <sys:String x:Key="setting-ShowOrHide">显示/隐藏所有便签</sys:String>

    <sys:String x:Key="about-about">关于</sys:String>
    <sys:String x:Key="about-projectAddress">项目地址</sys:String>
    <sys:String x:Key="about-githubLabel">Github地址</sys:String>
    <sys:String x:Key="about-versionInfo">版本信息:</sys:String>
    <sys:String x:Key="about-aboutContent">使用过程中出现什么BUG或者好的建议,欢迎在github上提建议</sys:String>
    <sys:String x:Key="about-addressContent">后续更新都会在上面的地址中发布,好用的话欢迎点个Star~</sys:String>


    <sys:String x:Key="tooltip-addNote">新增便签</sys:String>
    <sys:String x:Key="tooltip-menu">菜单</sys:String>
    <sys:String x:Key="tooltip-delNote">删除便签</sys:String>
    <sys:String x:Key="tooltip-hideNote">隐藏便签</sys:String>
    <sys:String x:Key="main-confirmDelLabel">是否删除当前便签?</sys:String>
    <sys:String x:Key="main-confirm">确定</sys:String>
    <sys:String x:Key="main-cancel">取消</sys:String>
    <sys:String x:Key="main-warning">警告</sys:String>

    <sys:String x:Key="setting-Language">语言</sys:String>
    <sys:String x:Key="list-search">搜索...</sys:String>
    <sys:String x:Key="list-coldgray">冷 灰</sys:String>
    <sys:String x:Key="list-pastoralbrown">田园褐</sys:String>
    <sys:String x:Key="list-stonegray">石材灰</sys:String>
    <sys:String x:Key="list-darkcloudgrey">乌云灰</sys:String>
    <sys:String x:Key="list-blue">甘蓝</sys:String>
    <sys:String x:Key="list-themediy">主题自定义</sys:String>
    <sys:String x:Key="setting-langsetting">语言设置</sys:String>
    <sys:String x:Key="setting-more">更多</sys:String>
    <sys:String x:Key="setting-close">关闭</sys:String>
    <sys:String x:Key="setting-back">返回</sys:String>
    <sys:String x:Key="main-topmost">置顶</sys:String>
    <sys:String x:Key="global-new">新建</sys:String>
    <sys:String x:Key="global-exit">退出</sys:String>


</ResourceDictionary>

================================================
FILE: StickyNotes/Style/Languages/Lan-en.xaml
================================================
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:sys="clr-namespace:System;assembly=mscorlib">
    <sys:String x:Key="menuList">Note List</sys:String>
    <sys:String x:Key="menuSetting">Setting</sys:String>
    <sys:String x:Key="menuAbout">About</sys:String>
    <sys:String x:Key="setting-AllWindowTop">All Notes TopMost</sys:String>
    <sys:String x:Key="setting-AutoStartUp">Auto Startup</sys:String>
    <sys:String x:Key="setting-AutoCheckUpdate">Auto Check Update</sys:String>
    <sys:String x:Key="setting-Theme">Theme</sys:String>
    <sys:String x:Key="setting-ShortCut">Shortcut</sys:String>
    <sys:String x:Key="setting-ShowOrHide">Show/Hidden All Notes</sys:String>

    <sys:String x:Key="about-about">About</sys:String>
    <sys:String x:Key="about-projectAddress">Project Address</sys:String>
    <sys:String x:Key="about-githubLabel">Github Address</sys:String>
    <sys:String x:Key="about-versionInfo">Version :</sys:String>
    <sys:String x:Key="about-aboutContent">If there are any bugs or good suggestions during use, please let me know on github</sys:String>
    <sys:String x:Key="about-addressContent">Subsequent updates will be released at the above address. If it is useful, please give me a star~</sys:String>

    <sys:String x:Key="tooltip-addNote">Add note</sys:String>
    <sys:String x:Key="tooltip-menu">Menu</sys:String>

    <sys:String x:Key="tooltip-delNote">Delete Note</sys:String>
    <sys:String x:Key="tooltip-hideNote">Hide Note</sys:String>
    <sys:String x:Key="main-confirmDelLabel">Are you sure you to delete?</sys:String>
    <sys:String x:Key="main-confirm">Yes</sys:String>
    <sys:String x:Key="main-cancel">Cancel</sys:String>
    <sys:String x:Key="main-warning">Warning</sys:String>

    <sys:String x:Key="setting-Language">Language</sys:String>

    <sys:String x:Key="list-search">Search...</sys:String>
    <sys:String x:Key="list-coldgray">ColdGray</sys:String>
    <sys:String x:Key="list-pastoralbrown">Brown</sys:String>
    <sys:String x:Key="list-stonegray">StoneGray</sys:String>
    <sys:String x:Key="list-darkcloudgrey">CloudGray</sys:String>
    <sys:String x:Key="list-blue">Blue</sys:String>
    <sys:String x:Key="list-themediy">Theme Custom</sys:String>
    <sys:String x:Key="setting-langsetting">Language Setting</sys:String>
    <sys:String x:Key="setting-more">More</sys:String>
    <sys:String x:Key="setting-close">Close</sys:String>
    <sys:String x:Key="setting-back">Back</sys:String>
    <sys:String x:Key="main-topmost">Topmost</sys:String>
    <sys:String x:Key="global-new">New</sys:String>
    <sys:String x:Key="global-exit">Quit</sys:String>
</ResourceDictionary>

================================================
FILE: StickyNotes/Style/Themes/乌云灰.xaml
================================================
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="clr-namespace:StickyNotes">
    <SolidColorBrush x:Key="PrimaryBrush" Color="#7a7b79" />
    <SolidColorBrush x:Key="PrimaryBrush100" Color="#887a7b79" />
</ResourceDictionary>

================================================
FILE: StickyNotes/Style/Themes/冷灰.xaml
================================================
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="clr-namespace:StickyNotes">
    <SolidColorBrush x:Key="PrimaryBrush" Color="#d5d5d5" />
    <SolidColorBrush x:Key="PrimaryBrush100" Color="#88d5d5d5" />
</ResourceDictionary>

================================================
FILE: StickyNotes/Style/Themes/甘蓝.xaml
================================================
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="clr-namespace:StickyNotes">
    <SolidColorBrush x:Key="PrimaryBrush" Color="#aad6e6" />
    <SolidColorBrush x:Key="PrimaryBrush100" Color="#88aad6e6" />
</ResourceDictionary>

================================================
FILE: StickyNotes/Style/Themes/田园褐.xaml
================================================
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="clr-namespace:StickyNotes">
    <SolidColorBrush x:Key="PrimaryBrush" Color="#d1bfac" />
    <SolidColorBrush x:Key="PrimaryBrush100" Color="#88d1bfac" />
</ResourceDictionary>

================================================
FILE: StickyNotes/Style/Themes/石材灰.xaml
================================================
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="clr-namespace:StickyNotes">
    <SolidColorBrush x:Key="PrimaryBrush" Color="#a59b95" />
    <SolidColorBrush x:Key="PrimaryBrush100" Color="#88a59b95" />
</ResourceDictionary>

================================================
FILE: StickyNotes/Style/Window.xaml
================================================
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="clr-namespace:StickyNotes">
    <Style x:Key="MainWindow" TargetType="{x:Type Window}">
        <Setter Property="MinHeight" Value="100" />
        <Setter Property="MinWidth" Value="100" />
        <Setter Property="AllowsTransparency" Value="True" />
        <Setter Property="BorderThickness" Value="8" />
        <Setter Property="WindowStyle" Value="None" />
        <Setter Property="ShowInTaskbar" Value="False" />
        <Setter Property="WindowChrome.WindowChrome">
            <Setter.Value>
                <WindowChrome
                    CaptionHeight="0"
                    CornerRadius="24"
                    ResizeBorderThickness="12" />
            </Setter.Value>
        </Setter>
        <Setter Property="Effect">
            <Setter.Value>
                <DropShadowEffect
                    BlurRadius="2"
                    Direction="90"
                    ShadowDepth="1"
                    Color="DarkGray" />
            </Setter.Value>
        </Setter>

    </Style>
</ResourceDictionary>


================================================
FILE: StickyNotes/UserControl/CardItem.xaml
================================================
<UserControl x:Class="StickyNotes.UserControl.CardItem"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             xmlns:local="clr-namespace:StickyNotes.UserControl"
               xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes" xmlns:converter="clr-namespace:StickyNotes.Converter"
             mc:Ignorable="d" 
             MinHeight="100"
            xmlns:hc="https://handyorg.github.io/handycontrol"
             
             MaxHeight="300"
             d:DesignHeight="300" d:DesignWidth="800">
    <UserControl.Resources>
        <converter:DateTimeToVisibilityConverter x:Key="DateTimeConverter"></converter:DateTimeToVisibilityConverter>
        <Style x:Key="HeaderColor" TargetType="{x:Type StackPanel}">
            <Setter Property="Cursor" Value="Hand"></Setter>
            <Style.Triggers>
                <DataTrigger Binding="{Binding IsShowOnScreen,RelativeSource={RelativeSource AncestorType={x:Type local:CardI
gitextract_uf0toj3p/

├── .gitattributes
├── .gitignore
├── .travis.yml
├── Common/
│   ├── AdministratorUtil.cs
│   ├── ComUtil.cs
│   ├── Common.csproj
│   ├── DownloadFileHelper.cs
│   ├── FileHelper.cs
│   ├── FodyWeavers.xml
│   ├── FodyWeavers.xsd
│   ├── HttpHelper.cs
│   ├── JsonHelper.cs
│   ├── Lang/
│   │   ├── LangBase.cs
│   │   ├── LangCN.cs
│   │   ├── LangEN.cs
│   │   ├── LangExtension.cs
│   │   └── Language.cs
│   ├── LangHelper.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── WindowHelper.cs
│   ├── packages.config
│   ├── version.Designer.cs
│   └── version.json
├── Contract/
│   ├── Contract.csproj
│   ├── ProgramData.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   └── SoftwareUpdate.cs
├── DB/
│   ├── App.config
│   ├── Config.cs
│   ├── DB.csproj
│   ├── Init.cs
│   ├── ProgramDB.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── Repository.cs
│   ├── Versions.cs
│   ├── WindowsDataDB.cs
│   └── packages.config
├── LICENSE
├── README.md
├── StickyNotes/
│   ├── App.config
│   ├── App.xaml
│   ├── App.xaml.cs
│   ├── Converter/
│   │   ├── DateTimeToVisibilityConverter.cs
│   │   ├── DeleteWindowMessageConverter.cs
│   │   ├── LanguageConverter.cs
│   │   ├── ShowAllHotKeyConverter.cs
│   │   ├── ThemeConverter.cs
│   │   └── boolToVisibilityConverter.cs
│   ├── Data/
│   │   ├── ConstData.cs
│   │   ├── ProgramData.cs
│   │   └── WindowsData.cs
│   ├── FodyWeavers.xml
│   ├── FodyWeavers.xsd
│   ├── Properties/
│   │   ├── Annotations.cs
│   │   ├── AssemblyInfo.cs
│   │   ├── Resources.Designer.cs
│   │   ├── Resources.resx
│   │   ├── Settings.Designer.cs
│   │   └── Settings.settings
│   ├── StickyNotes.csproj
│   ├── Style/
│   │   ├── Color.xaml
│   │   ├── Control.xaml
│   │   ├── Font.xaml
│   │   ├── Label.xaml
│   │   ├── Languages/
│   │   │   ├── Lan-cn.xaml
│   │   │   └── Lan-en.xaml
│   │   ├── Themes/
│   │   │   ├── 乌云灰.xaml
│   │   │   ├── 冷灰.xaml
│   │   │   ├── 甘蓝.xaml
│   │   │   ├── 田园褐.xaml
│   │   │   └── 石材灰.xaml
│   │   └── Window.xaml
│   ├── UserControl/
│   │   ├── CardItem.xaml
│   │   ├── CardItem.xaml.cs
│   │   ├── CustomWarningDialog.xaml
│   │   └── CustomWarningDialog.xaml.cs
│   ├── Utils/
│   │   ├── DataHelper.cs
│   │   ├── HotKeyUtil/
│   │   │   ├── HotKey.cs
│   │   │   ├── HotKeyHandler.cs
│   │   │   ├── HotKeyManager.cs
│   │   │   ├── HotKeySetting.cs
│   │   │   ├── HotkeyEventArgs.cs
│   │   │   └── NativeMethods.cs
│   │   ├── HttpHelper.cs
│   │   ├── LanguageManager.cs
│   │   ├── Logger.cs
│   │   ├── Messages/
│   │   │   ├── ChangeWindowMessage.cs
│   │   │   └── SaveMessage.cs
│   │   ├── SystemTray.cs
│   │   ├── ThemeAssist.cs
│   │   ├── TimerUtil.cs
│   │   ├── UpdateHelper.cs
│   │   ├── WindowHide.cs
│   │   └── WindowsManager.cs
│   ├── View/
│   │   ├── AboutWindow.xaml
│   │   ├── AboutWindow.xaml.cs
│   │   ├── ListWindow.xaml
│   │   ├── ListWindow.xaml.cs
│   │   ├── MainWindow.xaml
│   │   ├── MainWindow.xaml.cs
│   │   ├── SettingWindow-DESKTOP-HA5D6OQ.xaml
│   │   ├── SettingWindow.xaml
│   │   ├── SettingWindow.xaml-DESKTOP-HA5D6OQ.cs
│   │   └── SettingWindow.xaml.cs
│   └── ViewModel/
│       ├── ListWindowViewModel.cs
│       ├── MainViewModel-DESKTOP-HA5D6OQ.cs
│       ├── MainViewModel.cs
│       ├── SettingViewModel-DESKTOP-HA5D6OQ.cs
│       ├── SettingViewModel.cs
│       └── ViewModelLocator.cs
├── StickyNotes.sln
├── StikyNotes.sln.DotSettings
├── UpdateApp/
│   ├── App.config
│   ├── App.xaml
│   ├── App.xaml.cs
│   ├── FodyWeavers.xml
│   ├── FodyWeavers.xsd
│   ├── MainWindow.xaml
│   ├── MainWindow.xaml.cs
│   ├── MainWindowViewModel.cs
│   ├── Properties/
│   │   ├── AssemblyInfo.cs
│   │   ├── Resources.Designer.cs
│   │   ├── Resources.resx
│   │   ├── Settings.Designer.cs
│   │   └── Settings.settings
│   ├── UpdateApp.csproj
│   └── packages.config
├── version.json
└── 更新日志.md
Condensed preview — 129 files, each showing path, character count, and a content snippet. Download the .json file or copy for the full structured content (464K chars).
[
  {
    "path": ".gitattributes",
    "chars": 2518,
    "preview": "###############################################################################\n# Set default behavior to automatically..."
  },
  {
    "path": ".gitignore",
    "chars": 4326,
    "preview": "## Ignore Visual Studio temporary files, build results, and\n## files generated by popular Visual Studio add-ons.\n\n# User..."
  },
  {
    "path": ".travis.yml",
    "chars": 41,
    "preview": "language: csharp\nsolution: StikyNotes.sln"
  },
  {
    "path": "Common/AdministratorUtil.cs",
    "chars": 2120,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\nusi..."
  },
  {
    "path": "Common/ComUtil.cs",
    "chars": 790,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Diagnostics;\nusing System.IO;\nusing System.Linq;\nusing Sys..."
  },
  {
    "path": "Common/Common.csproj",
    "chars": 5097,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<Project ToolsVersion=\"15.0\" xmlns=\"http://schemas.microsoft.com/developer/msbui..."
  },
  {
    "path": "Common/DownloadFileHelper.cs",
    "chars": 8150,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.IO;\nusing System.Linq;\nusing System.Net;\nusing System.Text..."
  },
  {
    "path": "Common/FileHelper.cs",
    "chars": 1461,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.IO;\nusing System.IO.Compression;\nusing System.Linq;\nusing..."
  },
  {
    "path": "Common/FodyWeavers.xml",
    "chars": 184,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<Weavers xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:noNamespaceSc..."
  },
  {
    "path": "Common/FodyWeavers.xsd",
    "chars": 4038,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<xs:schema xmlns:xs=\"http://www.w3.org/2001/XMLSchema\">\n  <!-- This file was gen..."
  },
  {
    "path": "Common/HttpHelper.cs",
    "chars": 2024,
    "preview": "using Newtonsoft.Json;\nusing RestSharp;\nusing System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System..."
  },
  {
    "path": "Common/JsonHelper.cs",
    "chars": 1418,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.IO;\nusing System.Linq;\nusing System.Text;\nusing System.Thr..."
  },
  {
    "path": "Common/Lang/LangBase.cs",
    "chars": 881,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.ComponentModel;\nusing System.Linq;\nusing System.Text;\nusin..."
  },
  {
    "path": "Common/Lang/LangCN.cs",
    "chars": 582,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.ComponentModel;\nusing System.Linq;\nusing System.Text;\nusin..."
  },
  {
    "path": "Common/Lang/LangEN.cs",
    "chars": 622,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.ComponentModel;\nusing System.Linq;\nusing System.Text;\nusin..."
  },
  {
    "path": "Common/Lang/LangExtension.cs",
    "chars": 621,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\nusi..."
  },
  {
    "path": "Common/Lang/Language.cs",
    "chars": 214,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\n\nna..."
  },
  {
    "path": "Common/LangHelper.cs",
    "chars": 938,
    "preview": "using Common.Lang;\nusing System;\nusing System.Collections.Generic;\nusing System.ComponentModel;\nusing System.Linq;\nusin..."
  },
  {
    "path": "Common/Properties/AssemblyInfo.cs",
    "chars": 1380,
    "preview": "using System.Reflection;\nusing System.Runtime.CompilerServices;\nusing System.Runtime.InteropServices;\n\n// General Infor..."
  },
  {
    "path": "Common/WindowHelper.cs",
    "chars": 605,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\nusi..."
  },
  {
    "path": "Common/packages.config",
    "chars": 383,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<packages>\n  <package id=\"Fody\" version=\"6.6.2\" targetFramework=\"net46\" developm..."
  },
  {
    "path": "Common/version.Designer.cs",
    "chars": 1045,
    "preview": "//------------------------------------------------------------------------------\n// <auto-generated>\n//     This code w..."
  },
  {
    "path": "Common/version.json",
    "chars": 227,
    "preview": "{\n  \"StickyNotesVersion\": {\n    \"MajorVersionNumber\": 5,\n    \"MinorVersionNumber\": 0,\n    \"RevisionNumebr\": 1\n  },\n  \"U..."
  },
  {
    "path": "Contract/Contract.csproj",
    "chars": 2493,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<Project ToolsVersion=\"15.0\" xmlns=\"http://schemas.microsoft.com/developer/msbui..."
  },
  {
    "path": "Contract/ProgramData.cs",
    "chars": 990,
    "preview": "\nusing Common.Lang;\nusing System;\nusing System.Collections.ObjectModel;\nusing System.ComponentModel;\nusing System.Runti..."
  },
  {
    "path": "Contract/Properties/AssemblyInfo.cs",
    "chars": 1384,
    "preview": "using System.Reflection;\nusing System.Runtime.CompilerServices;\nusing System.Runtime.InteropServices;\n\n// General Infor..."
  },
  {
    "path": "Contract/SoftwareUpdate.cs",
    "chars": 2266,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\n\nna..."
  },
  {
    "path": "DB/App.config",
    "chars": 1760,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<configuration>\n  <configSections>\n    <!-- For more information on Entity Frame..."
  },
  {
    "path": "DB/Config.cs",
    "chars": 527,
    "preview": "using Common;\nusing System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Thread..."
  },
  {
    "path": "DB/DB.csproj",
    "chars": 6439,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<Project ToolsVersion=\"15.0\" xmlns=\"http://schemas.microsoft.com/developer/msbui..."
  },
  {
    "path": "DB/Init.cs",
    "chars": 665,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\n\nna..."
  },
  {
    "path": "DB/ProgramDB.cs",
    "chars": 1541,
    "preview": "using log4net;\nusing SqlSugar;\nusing System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nus..."
  },
  {
    "path": "DB/Properties/AssemblyInfo.cs",
    "chars": 1372,
    "preview": "using System.Reflection;\nusing System.Runtime.CompilerServices;\nusing System.Runtime.InteropServices;\n\n// General Infor..."
  },
  {
    "path": "DB/Repository.cs",
    "chars": 1285,
    "preview": "using log4net;\nusing SqlSugar;\nusing System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nus..."
  },
  {
    "path": "DB/Versions.cs",
    "chars": 927,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\n\nna..."
  },
  {
    "path": "DB/WindowsDataDB.cs",
    "chars": 877,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\n\nna..."
  },
  {
    "path": "DB/packages.config",
    "chars": 722,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<packages>\n  <package id=\"EntityFramework\" version=\"6.4.4\" targetFramework=\"net4..."
  },
  {
    "path": "LICENSE",
    "chars": 1067,
    "preview": "MIT License\n\nCopyright (c) 2019 LiZhengHao\n\nPermission is hereby granted, free of charge, to any person obtaining a copy..."
  },
  {
    "path": "README.md",
    "chars": 820,
    "preview": "**此项目已不再维护 2023年5月29日**\n\n# StikyNotes\n\n![#](https://img.shields.io/badge/building-pass-brightgreen)\n![star](https://img...."
  },
  {
    "path": "StickyNotes/App.config",
    "chars": 989,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<configuration>\n  <configSections>\n    <!--log4net配置-->\n    <section name=\"log4ne..."
  },
  {
    "path": "StickyNotes/App.xaml",
    "chars": 3729,
    "preview": "<Application\n    x:Class=\"StickyNotes.App\"\n    xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n    xml..."
  },
  {
    "path": "StickyNotes/App.xaml.cs",
    "chars": 9498,
    "preview": "using Common;\nusing Common.Lang;\nusing DB;\nusing MahApps.Metro.Controls;\nusing StickyNotes.Utils;\nusing StickyNotes.Vie..."
  },
  {
    "path": "StickyNotes/Converter/DateTimeToVisibilityConverter.cs",
    "chars": 648,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Globalization;\nusing System.Linq;\nusing System.Text;\nusing..."
  },
  {
    "path": "StickyNotes/Converter/DeleteWindowMessageConverter.cs",
    "chars": 694,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Globalization;\nusing System.Linq;\nusing System.Runtime.Int..."
  },
  {
    "path": "StickyNotes/Converter/LanguageConverter.cs",
    "chars": 1197,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Globalization;\nusing System.Linq;\nusing System.Text;\nusing..."
  },
  {
    "path": "StickyNotes/Converter/ShowAllHotKeyConverter.cs",
    "chars": 2621,
    "preview": "using StickyNotes.Utils.HotKeyUtil;\nusing System;\nusing System.Collections.Generic;\nusing System.Globalization;\nusing S..."
  },
  {
    "path": "StickyNotes/Converter/ThemeConverter.cs",
    "chars": 1258,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Globalization;\nusing System.Linq;\nusing System.Text;\nusing..."
  },
  {
    "path": "StickyNotes/Converter/boolToVisibilityConverter.cs",
    "chars": 658,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Globalization;\nusing System.Linq;\nusing System.Text;\nusing..."
  },
  {
    "path": "StickyNotes/Data/ConstData.cs",
    "chars": 323,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\n\nna..."
  },
  {
    "path": "StickyNotes/Data/ProgramData.cs",
    "chars": 2843,
    "preview": "using Common.Lang;\nusing GalaSoft.MvvmLight.Messaging;\nusing StickyNotes.Annotations;\nusing StickyNotes.Utils;\nusing St..."
  },
  {
    "path": "StickyNotes/Data/WindowsData.cs",
    "chars": 3132,
    "preview": "using StickyNotes.Annotations;\nusing System;\nusing System.ComponentModel;\nusing System.Runtime.CompilerServices;\nusing..."
  },
  {
    "path": "StickyNotes/FodyWeavers.xml",
    "chars": 267,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<Weavers xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:noNamespaceSc..."
  },
  {
    "path": "StickyNotes/FodyWeavers.xsd",
    "chars": 8372,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<xs:schema xmlns:xs=\"http://www.w3.org/2001/XMLSchema\">\n  <!-- This file was gen..."
  },
  {
    "path": "StickyNotes/Properties/Annotations.cs",
    "chars": 41721,
    "preview": "/* MIT License\n\nCopyright (c) 2016 JetBrains http://www.jetbrains.com\n\nPermission is hereby granted, free of charge, to..."
  },
  {
    "path": "StickyNotes/Properties/AssemblyInfo.cs",
    "chars": 1658,
    "preview": "using System.Reflection;\nusing System.Resources;\nusing System.Runtime.CompilerServices;\nusing System.Runtime.InteropSer..."
  },
  {
    "path": "StickyNotes/Properties/Resources.Designer.cs",
    "chars": 3928,
    "preview": "//------------------------------------------------------------------------------\n// <auto-generated>\n//     This code w..."
  },
  {
    "path": "StickyNotes/Properties/Resources.resx",
    "chars": 6084,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<root>\n  <!-- \n    Microsoft ResX Schema \n    \n    Version 2.0\n    \n    The prim..."
  },
  {
    "path": "StickyNotes/Properties/Settings.Designer.cs",
    "chars": 1066,
    "preview": "//------------------------------------------------------------------------------\n// <auto-generated>\n//     This code w..."
  },
  {
    "path": "StickyNotes/Properties/Settings.settings",
    "chars": 193,
    "preview": "<?xml version='1.0' encoding='utf-8'?>\n<SettingsFile xmlns=\"uri:settings\" CurrentProfile=\"(Default)\">\n  <Profiles>..."
  },
  {
    "path": "StickyNotes/StickyNotes.csproj",
    "chars": 14700,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<Project ToolsVersion=\"15.0\" xmlns=\"http://schemas.microsoft.com/developer/msbui..."
  },
  {
    "path": "StickyNotes/Style/Color.xaml",
    "chars": 1513,
    "preview": "<ResourceDictionary\n    xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n    xmlns:x=\"http://schemas.m..."
  },
  {
    "path": "StickyNotes/Style/Control.xaml",
    "chars": 2356,
    "preview": "<ResourceDictionary\n    xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n    xmlns:x=\"http://schemas.m..."
  },
  {
    "path": "StickyNotes/Style/Font.xaml",
    "chars": 1896,
    "preview": "<ResourceDictionary\n    xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n    xmlns:x=\"http://schemas.m..."
  },
  {
    "path": "StickyNotes/Style/Label.xaml",
    "chars": 599,
    "preview": "<ResourceDictionary\n    xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n    xmlns:x=\"http://schemas.m..."
  },
  {
    "path": "StickyNotes/Style/Languages/Lan-cn.xaml",
    "chars": 2461,
    "preview": "<ResourceDictionary\n    xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n    xmlns:x=\"http://schemas.m..."
  },
  {
    "path": "StickyNotes/Style/Languages/Lan-en.xaml",
    "chars": 2773,
    "preview": "<ResourceDictionary\n    xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n    xmlns:x=\"http://schemas.m..."
  },
  {
    "path": "StickyNotes/Style/Themes/乌云灰.xaml",
    "chars": 343,
    "preview": "<ResourceDictionary\n    xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n    xmlns:x=\"http://schemas.m..."
  },
  {
    "path": "StickyNotes/Style/Themes/冷灰.xaml",
    "chars": 343,
    "preview": "<ResourceDictionary\n    xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n    xmlns:x=\"http://schemas.m..."
  },
  {
    "path": "StickyNotes/Style/Themes/甘蓝.xaml",
    "chars": 343,
    "preview": "<ResourceDictionary\n    xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n    xmlns:x=\"http://schemas.m..."
  },
  {
    "path": "StickyNotes/Style/Themes/田园褐.xaml",
    "chars": 343,
    "preview": "<ResourceDictionary\n    xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n    xmlns:x=\"http://schemas.m..."
  },
  {
    "path": "StickyNotes/Style/Themes/石材灰.xaml",
    "chars": 343,
    "preview": "<ResourceDictionary\n    xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n    xmlns:x=\"http://schemas.m..."
  },
  {
    "path": "StickyNotes/Style/Window.xaml",
    "chars": 1196,
    "preview": "<ResourceDictionary\n    xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n    xmlns:x=\"http://schemas.m..."
  },
  {
    "path": "StickyNotes/UserControl/CardItem.xaml",
    "chars": 3976,
    "preview": "<UserControl x:Class=\"StickyNotes.UserControl.CardItem\"\n             xmlns=\"http://schemas.microsoft.com/winfx/2006/xam..."
  },
  {
    "path": "StickyNotes/UserControl/CardItem.xaml.cs",
    "chars": 2284,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\nusi..."
  },
  {
    "path": "StickyNotes/UserControl/CustomWarningDialog.xaml",
    "chars": 2120,
    "preview": "<UserControl x:Class=\"StickyNotes.UserControl.CustomWarningDialog\"\n             xmlns=\"http://schemas.microsoft.com/win..."
  },
  {
    "path": "StickyNotes/UserControl/CustomWarningDialog.xaml.cs",
    "chars": 1104,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\nusi..."
  },
  {
    "path": "StickyNotes/Utils/DataHelper.cs",
    "chars": 3000,
    "preview": "using DB;\nusing Newtonsoft.Json;\nusing StickyNotes.Utils;\nusing System;\nusing System.Collections.Generic;\nusing System...."
  },
  {
    "path": "StickyNotes/Utils/HotKeyUtil/HotKey.cs",
    "chars": 2897,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\nusi..."
  },
  {
    "path": "StickyNotes/Utils/HotKeyUtil/HotKeyHandler.cs",
    "chars": 1272,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\nusi..."
  },
  {
    "path": "StickyNotes/Utils/HotKeyUtil/HotKeyManager.cs",
    "chars": 14411,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Runtime.InteropServices;\nusing System.T..."
  },
  {
    "path": "StickyNotes/Utils/HotKeyUtil/HotKeySetting.cs",
    "chars": 287,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\n\nna..."
  },
  {
    "path": "StickyNotes/Utils/HotKeyUtil/HotkeyEventArgs.cs",
    "chars": 133,
    "preview": "namespace StickyNotes.Utils.HotKeyUtil\n{\n    public class HotkeyEventArgs\n    {\n        public HotKeyType Type { get; s..."
  },
  {
    "path": "StickyNotes/Utils/HotKeyUtil/NativeMethods.cs",
    "chars": 2529,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Runtime.InteropServices;\nusing System.T..."
  },
  {
    "path": "StickyNotes/Utils/HttpHelper.cs",
    "chars": 199,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\n\nna..."
  },
  {
    "path": "StickyNotes/Utils/LanguageManager.cs",
    "chars": 2197,
    "preview": "using Common.Lang;\nusing System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.T..."
  },
  {
    "path": "StickyNotes/Utils/Logger.cs",
    "chars": 405,
    "preview": "using log4net;\nusing System.Reflection;\n\nnamespace StickyNotes.Utils\n{\n    public static class Logger\n    {\n        pub..."
  },
  {
    "path": "StickyNotes/Utils/Messages/ChangeWindowMessage.cs",
    "chars": 437,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\n\nna..."
  },
  {
    "path": "StickyNotes/Utils/Messages/SaveMessage.cs",
    "chars": 357,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.ComponentModel;\nusing System.Linq;\nusing System.Runtime.Co..."
  },
  {
    "path": "StickyNotes/Utils/SystemTray.cs",
    "chars": 1793,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.IO;\nusing System.Linq;\nusing System.Text;\nusing System.Thr..."
  },
  {
    "path": "StickyNotes/Utils/ThemeAssist.cs",
    "chars": 2035,
    "preview": "using ControlzEx.Theming;\nusing System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing S..."
  },
  {
    "path": "StickyNotes/Utils/TimerUtil.cs",
    "chars": 775,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\nusi..."
  },
  {
    "path": "StickyNotes/Utils/UpdateHelper.cs",
    "chars": 6495,
    "preview": "\nusing Common;\nusing Contract;\nusing System;\nusing System.Collections.Generic;\nusing System.Diagnostics;\nusing System.I..."
  },
  {
    "path": "StickyNotes/Utils/WindowHide.cs",
    "chars": 8918,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Drawing;\nusing System.Runtime.InteropServices;\nusing Syste..."
  },
  {
    "path": "StickyNotes/Utils/WindowsManager.cs",
    "chars": 510,
    "preview": "using StickyNotes.View;\nusing System.Collections.Generic;\n\nnamespace StickyNotes\n{\n    public class WindowsManager..."
  },
  {
    "path": "StickyNotes/View/AboutWindow.xaml",
    "chars": 3343,
    "preview": "<Controls:MetroWindow\n    x:Class=\"StickyNotes.View.AboutWindow\"\n    xmlns=\"http://schemas.microsoft.com/winfx/2006/xam..."
  },
  {
    "path": "StickyNotes/View/AboutWindow.xaml.cs",
    "chars": 1135,
    "preview": "using System;\nusing System.Diagnostics;\nusing System.Windows;\nusing System.Windows.Documents;\nusing Common;\nusing Contr..."
  },
  {
    "path": "StickyNotes/View/ListWindow.xaml",
    "chars": 30936,
    "preview": "<hc:Window x:Class=\"StickyNotes.View.ListWindow\"\n  xmlns:Controls=\"clr-namespace:MahApps.Metro.Controls;assembly=MahApp..."
  },
  {
    "path": "StickyNotes/View/ListWindow.xaml.cs",
    "chars": 1217,
    "preview": "using ControlzEx.Theming;\nusing GalaSoft.MvvmLight.Command;\nusing MahApps.Metro.Controls;\nusing StickyNotes.ViewModel;..."
  },
  {
    "path": "StickyNotes/View/MainWindow.xaml",
    "chars": 16994,
    "preview": "<metro:MetroWindow\n    x:Class=\"StickyNotes.MainWindow\"\n    xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/present..."
  },
  {
    "path": "StickyNotes/View/MainWindow.xaml.cs",
    "chars": 2629,
    "preview": "using ControlzEx.Theming;\nusing MahApps.Metro.Controls;\nusing StickyNotes.Utils;\nusing StickyNotes.Utils.HotKeyUtil;\nus..."
  },
  {
    "path": "StickyNotes/View/SettingWindow-DESKTOP-HA5D6OQ.xaml",
    "chars": 6476,
    "preview": "<Controls:MetroWindow\n    x:Class=\"StikyNotes.SettingWindow\"\n    xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/pr..."
  },
  {
    "path": "StickyNotes/View/SettingWindow.xaml",
    "chars": 7556,
    "preview": "<Controls:MetroWindow\n    x:Class=\"StickyNotes.SettingWindow\"\n    xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/p..."
  },
  {
    "path": "StickyNotes/View/SettingWindow.xaml-DESKTOP-HA5D6OQ.cs",
    "chars": 3121,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Collections.ObjectModel;\nusing System.Linq;\nusing System.R..."
  },
  {
    "path": "StickyNotes/View/SettingWindow.xaml.cs",
    "chars": 587,
    "preview": "using ControlzEx.Theming;\nusing MahApps.Metro.Controls;\n\nnamespace StickyNotes\n{\n    /// <summary>\n    /// SettingWindo..."
  },
  {
    "path": "StickyNotes/ViewModel/ListWindowViewModel.cs",
    "chars": 15176,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Collections.ObjectModel;\nusing System.ComponentModel;\nusin..."
  },
  {
    "path": "StickyNotes/ViewModel/MainViewModel-DESKTOP-HA5D6OQ.cs",
    "chars": 4633,
    "preview": "using System;\nusing System.Windows;\nusing System.Windows.Input;\nusing System.Windows.Threading;\nusing GalaSoft.MvvmLight..."
  },
  {
    "path": "StickyNotes/ViewModel/MainViewModel.cs",
    "chars": 16356,
    "preview": "using GalaSoft.MvvmLight;\nusing GalaSoft.MvvmLight.Command;\nusing StickyNotes.Utils.HotKeyUtil;\nusing System;\nusing Sys..."
  },
  {
    "path": "StickyNotes/ViewModel/SettingViewModel-DESKTOP-HA5D6OQ.cs",
    "chars": 6710,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Collections.ObjectModel;\nusing System.Collections.Speciali..."
  },
  {
    "path": "StickyNotes/ViewModel/SettingViewModel.cs",
    "chars": 9169,
    "preview": "using Common.Lang;\nusing GalaSoft.MvvmLight;\nusing GalaSoft.MvvmLight.Command;\nusing StickyNotes.Utils;\nusing StickyNot..."
  },
  {
    "path": "StickyNotes/ViewModel/ViewModelLocator.cs",
    "chars": 2036,
    "preview": "/*\n  In App.xaml:\n  <Application.Resources>\n      <vm:ViewModelLocator xmlns:vm=\"clr-namespace:StickyNotes\"..."
  },
  {
    "path": "StickyNotes.sln",
    "chars": 2979,
    "preview": "\nMicrosoft Visual Studio Solution File, Format Version 12.00\n# Visual Studio Version 17\nVisualStudioVersion = 17.2.3252..."
  },
  {
    "path": "StikyNotes.sln.DotSettings",
    "chars": 453,
    "preview": "<wpf:ResourceDictionary xml:space=\"preserve\" xmlns:x=\"http://schemas.microsoft.com/winfx/2006/xaml\" xmlns:s=\"clr-namesp..."
  },
  {
    "path": "UpdateApp/App.config",
    "chars": 545,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<configuration>\n    <startup> \n        <supportedRuntime version=\"v4.0\" sku=\".NE..."
  },
  {
    "path": "UpdateApp/App.xaml",
    "chars": 1173,
    "preview": "<Application x:Class=\"UpdateApp.App\"\n             xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"..."
  },
  {
    "path": "UpdateApp/App.xaml.cs",
    "chars": 1295,
    "preview": "using Common;\nusing System;\nusing System.Collections.Generic;\nusing System.Configuration;\nusing System.Data;\nusing Syst..."
  },
  {
    "path": "UpdateApp/FodyWeavers.xml",
    "chars": 261,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<Weavers xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:noNamespaceSc..."
  },
  {
    "path": "UpdateApp/FodyWeavers.xsd",
    "chars": 11561,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<xs:schema xmlns:xs=\"http://www.w3.org/2001/XMLSchema\">\n  <!-- This file was gen..."
  },
  {
    "path": "UpdateApp/MainWindow.xaml",
    "chars": 5627,
    "preview": "<mah:MetroWindow x:Class=\"UpdateApp.MainWindow\"\n        xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentatio..."
  },
  {
    "path": "UpdateApp/MainWindow.xaml.cs",
    "chars": 805,
    "preview": "using Common;\nusing Contract;\nusing MahApps.Metro.Controls;\nusing MahApps.Metro.Controls.Dialogs;\nusing Notifications.W..."
  },
  {
    "path": "UpdateApp/MainWindowViewModel.cs",
    "chars": 6913,
    "preview": "using Common;\nusing Common.Lang;\nusing Contract;\nusing GalaSoft.MvvmLight;\nusing GalaSoft.MvvmLight.Command;\nusing MahA..."
  },
  {
    "path": "UpdateApp/Properties/AssemblyInfo.cs",
    "chars": 2366,
    "preview": "using System.Reflection;\nusing System.Resources;\nusing System.Runtime.CompilerServices;\nusing System.Runtime.InteropSer..."
  },
  {
    "path": "UpdateApp/Properties/Resources.Designer.cs",
    "chars": 4263,
    "preview": "//------------------------------------------------------------------------------\n// <auto-generated>\n//     This code w..."
  },
  {
    "path": "UpdateApp/Properties/Resources.resx",
    "chars": 6274,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<root>\n  <!-- \n    Microsoft ResX Schema \n    \n    Version 2.0\n    \n    The prim..."
  },
  {
    "path": "UpdateApp/Properties/Settings.Designer.cs",
    "chars": 1064,
    "preview": "//------------------------------------------------------------------------------\n// <auto-generated>\n//     This code w..."
  },
  {
    "path": "UpdateApp/Properties/Settings.settings",
    "chars": 193,
    "preview": "<?xml version='1.0' encoding='utf-8'?>\n<SettingsFile xmlns=\"uri:settings\" CurrentProfile=\"(Default)\">\n  <Profiles>..."
  },
  {
    "path": "UpdateApp/UpdateApp.csproj",
    "chars": 14991,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<Project ToolsVersion=\"15.0\" xmlns=\"http://schemas.microsoft.com/developer/msbui..."
  },
  {
    "path": "UpdateApp/packages.config",
    "chars": 4769,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<packages>\n  <package id=\"CommonServiceLocator\" version=\"2.0.2\" targetFramework=..."
  },
  {
    "path": "version.json",
    "chars": 175,
    "preview": "{\"StickyNotesVersion\":{\"MajorVersionNumber\":5,\"MinorVersionNumber\":0,\"RevisionNumebr\":1},\"UpdateAppVersion\":{\"MajorVersi..."
  },
  {
    "path": "更新日志.md",
    "chars": 1919,
    "preview": "# 更新日志\n\n## ⚡功能更新 2022年1月24日\n\n1. 支持多语言切换(英语、中文)\n\n## ✔功能修复 2022年1月23日\n\n1. 修复便签列表删除便签时需要打开后再删除的问题\n\n## ⚡功能更新 2022年1月22日\n\n1...."
  }
]

About this extraction

This page contains the full source code of the li-zheng-hao/StickyNotes GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 129 files (428.4 KB), approximately 99.9k tokens. 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.

Copied to clipboard!