Merge pull request #21 from Lakritzator/feature/dotnetcore3
Making the repository ready for dotnet core 3.x and azure devops
@@ -1,42 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd">
|
|
||||||
<metadata>
|
|
||||||
<id>Hardcodet.NotifyIcon.Wpf</id>
|
|
||||||
<version>1.0.7</version>
|
|
||||||
<title>Hardcodet WPF NotifyIcon</title>
|
|
||||||
<authors>Philipp Sumi</authors>
|
|
||||||
<owners>Philipp Sumi</owners>
|
|
||||||
<licenseUrl>http://www.codeproject.com/info/cpol10.aspx</licenseUrl>
|
|
||||||
<projectUrl>http://www.hardcodet.net/projects/wpf-notifyicon</projectUrl>
|
|
||||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
|
||||||
<description>This is an implementation of a NotifyIcon (aka system tray icon or taskbar icon) for the WPF platform. It does not just rely on the Windows Forms NotifyIcon component, but is a purely independent control which leverages several features of the WPF framework in order to display rich tooltips, popups, context menus, and balloon messages. It can be used directly in code or embedded in any XAML file.
|
|
||||||
|
|
||||||
Source code and extensive sample application available at http://www.hardcodet.net/projects/wpf-notifyicon</description>
|
|
||||||
<summary>NotifyIcon (aka system tray icon or taskbar icon) for the WPF platform.</summary>
|
|
||||||
<releaseNotes>Bugfixes. Contains source and binaries for .NET 3.5 - 4.51.</releaseNotes>
|
|
||||||
<copyright>Copyright (c) 2016 Philipp Sumi</copyright>
|
|
||||||
<language />
|
|
||||||
<tags>NotifyIcon WPF Tray Notify ToolTip Popup Balloon Toast</tags>
|
|
||||||
</metadata>
|
|
||||||
<files>
|
|
||||||
<file src="..\Binaries\net35\Hardcodet.Wpf.TaskbarNotification.dll" target="lib\net35\Hardcodet.Wpf.TaskbarNotification.dll" />
|
|
||||||
<file src="..\Binaries\net35\Hardcodet.Wpf.TaskbarNotification.pdb" target="lib\net35\Hardcodet.Wpf.TaskbarNotification.pdb" />
|
|
||||||
<file src="..\Binaries\net35\Hardcodet.Wpf.TaskbarNotification.xml" target="lib\net35\Hardcodet.Wpf.TaskbarNotification.xml" />
|
|
||||||
<file src="..\Binaries\net35-client\Hardcodet.Wpf.TaskbarNotification.dll" target="lib\net35-client\Hardcodet.Wpf.TaskbarNotification.dll" />
|
|
||||||
<file src="..\Binaries\net35-client\Hardcodet.Wpf.TaskbarNotification.pdb" target="lib\net35-client\Hardcodet.Wpf.TaskbarNotification.pdb" />
|
|
||||||
<file src="..\Binaries\net35-client\Hardcodet.Wpf.TaskbarNotification.xml" target="lib\net35-client\Hardcodet.Wpf.TaskbarNotification.xml" />
|
|
||||||
<file src="..\Binaries\net40\Hardcodet.Wpf.TaskbarNotification.dll" target="lib\net40\Hardcodet.Wpf.TaskbarNotification.dll" />
|
|
||||||
<file src="..\Binaries\net40\Hardcodet.Wpf.TaskbarNotification.pdb" target="lib\net40\Hardcodet.Wpf.TaskbarNotification.pdb" />
|
|
||||||
<file src="..\Binaries\net40\Hardcodet.Wpf.TaskbarNotification.xml" target="lib\net40\Hardcodet.Wpf.TaskbarNotification.xml" />
|
|
||||||
<file src="..\Binaries\net40-client\Hardcodet.Wpf.TaskbarNotification.dll" target="lib\net40-client\Hardcodet.Wpf.TaskbarNotification.dll" />
|
|
||||||
<file src="..\Binaries\net40-client\Hardcodet.Wpf.TaskbarNotification.pdb" target="lib\net40-client\Hardcodet.Wpf.TaskbarNotification.pdb" />
|
|
||||||
<file src="..\Binaries\net40-client\Hardcodet.Wpf.TaskbarNotification.xml" target="lib\net40-client\Hardcodet.Wpf.TaskbarNotification.xml" />
|
|
||||||
<file src="..\Binaries\net45\Hardcodet.Wpf.TaskbarNotification.dll" target="lib\net45\Hardcodet.Wpf.TaskbarNotification.dll" />
|
|
||||||
<file src="..\Binaries\net45\Hardcodet.Wpf.TaskbarNotification.pdb" target="lib\net45\Hardcodet.Wpf.TaskbarNotification.pdb" />
|
|
||||||
<file src="..\Binaries\net45\Hardcodet.Wpf.TaskbarNotification.xml" target="lib\net45\Hardcodet.Wpf.TaskbarNotification.xml" />
|
|
||||||
<file src="..\Binaries\net451\Hardcodet.Wpf.TaskbarNotification.dll" target="lib\net451\Hardcodet.Wpf.TaskbarNotification.dll" />
|
|
||||||
<file src="..\Binaries\net451\Hardcodet.Wpf.TaskbarNotification.pdb" target="lib\net451\Hardcodet.Wpf.TaskbarNotification.pdb" />
|
|
||||||
<file src="..\Binaries\net451\Hardcodet.Wpf.TaskbarNotification.xml" target="lib\net451\Hardcodet.Wpf.TaskbarNotification.xml" />
|
|
||||||
<file src="readme.txt" target="readme.txt" />
|
|
||||||
</files>
|
|
||||||
</package>
|
|
||||||
@@ -1,31 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd">
|
|
||||||
<metadata>
|
|
||||||
<id>Hardcodet.Wpf.TaskbarNotification</id>
|
|
||||||
<version>1.0.5</version>
|
|
||||||
<title>Hardcodet.Wpf.TaskbarNotification</title>
|
|
||||||
<authors>Philipp Sumi</authors>
|
|
||||||
<owners>Philipp Sumi</owners>
|
|
||||||
<licenseUrl>http://www.codeproject.com/info/cpol10.aspx</licenseUrl>
|
|
||||||
<projectUrl>http://www.hardcodet.net/projects/wpf-notifyicon</projectUrl>
|
|
||||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
|
||||||
<description>THIS PACKAGE IS OBSOLETE.
|
|
||||||
|
|
||||||
Please switch to the officially maintained NuGet package: Hardcodet.NotifyIcon.WPF
|
|
||||||
|
|
||||||
This is an implementation of a NotifyIcon (aka system tray icon or taskbar icon) for the WPF platform. It does not just rely on the Windows Forms NotifyIcon component, but is a purely independent control which leverages several features of the WPF framework in order to display rich tooltips, popups, context menus, and balloon messages. It can be used directly in code or embedded in any XAML file.
|
|
||||||
|
|
||||||
Source code and extensive sample application available at http://www.hardcodet.net/projects/wpf-notifyicon</description>
|
|
||||||
<summary>This package is obsolete. Please switch to the maintained NuGet package: Hardcodet.NotifyIcon.WPF</summary>
|
|
||||||
<releaseNotes>Mostly bug fixes and full x64 / Win 8 support. Contains source and binaries for .NET 3.5 - 4.51.</releaseNotes>
|
|
||||||
<copyright>Copyright (c) 2013 Philipp Sumi</copyright>
|
|
||||||
<language />
|
|
||||||
<tags>NotifyIcon WPF Tray Notify ToolTip Popup Balloon Toast</tags>
|
|
||||||
<dependencies>
|
|
||||||
<dependency id="Hardcodet.NotifyIcon.Wpf" version="1.0.5" />
|
|
||||||
</dependencies>
|
|
||||||
</metadata>
|
|
||||||
<files>
|
|
||||||
<file src="readme.from.legacy.package.txt" target="readme.txt" />
|
|
||||||
</files>
|
|
||||||
</package>
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
Hardcodet NotifyIcon for WPF
|
|
||||||
****************************
|
|
||||||
|
|
||||||
THIS PACKAGE IS OBSOLETE.
|
|
||||||
|
|
||||||
This package has a dependency to the official package in order to keep things working for you, but consider switching to the official NuGet package: Hardcodet.NotifyIcon.Wpf
|
|
||||||
|
|
||||||
For direct NuGet links, source code or samples, please visit the project page:
|
|
||||||
http://www.hardcodet.net/projects/wpf-notifyicon
|
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
Hardcodet NotifyIcon for WPF
|
|
||||||
****************************
|
|
||||||
|
|
||||||
This is an implementation of a NotifyIcon (aka system tray icon or taskbar icon) for the WPF platform. It does not just rely on the Windows Forms NotifyIcon component, but is a purely independent control which leverages several features of the WPF framework in order to display rich tooltips, popups, context menus, and balloon messages. It can be used directly in code or embedded in any XAML file.
|
|
||||||
|
|
||||||
This package contains only binaries. For source code and samples, please visit the project page:
|
|
||||||
http://www.hardcodet.net/projects/wpf-notifyicon
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
"C:\Program Files (x86)\MSBuild\12.0\Bin\msbuild.exe" NotifyIconWpf\NotifyIconWpf.csproj /p:Configuration=Release;TargetFrameworkVersion=v3.5;TargetFrameworkProfile="";OutputPath=..\..\Binaries\net35 /t:Rebuild
|
|
||||||
"C:\Program Files (x86)\MSBuild\12.0\Bin\msbuild.exe" NotifyIconWpf\NotifyIconWpf.csproj /p:Configuration=Release;TargetFrameworkVersion=v3.5;TargetFrameworkProfile="Client";OutputPath=..\..\Binaries\net35-client /t:Rebuild
|
|
||||||
|
|
||||||
"C:\Program Files (x86)\MSBuild\12.0\Bin\msbuild.exe" NotifyIconWpf\NotifyIconWpf.csproj /p:Configuration=Release;TargetFrameworkVersion=v4.0;TargetFrameworkProfile="";OutputPath=..\..\Binaries\net40 /t:Rebuild
|
|
||||||
"C:\Program Files (x86)\MSBuild\12.0\Bin\msbuild.exe" NotifyIconWpf\NotifyIconWpf.csproj /p:Configuration=Release;TargetFrameworkVersion=v4.0;TargetFrameworkProfile="Client";OutputPath=..\..\Binaries\net40-client /t:Rebuild
|
|
||||||
|
|
||||||
"C:\Program Files (x86)\MSBuild\12.0\Bin\msbuild.exe" NotifyIconWpf\NotifyIconWpf.csproj /p:Configuration=Release;TargetFrameworkVersion=v4.5;TargetFrameworkProfile="";OutputPath=..\..\Binaries\net45 /t:Rebuild
|
|
||||||
|
|
||||||
"C:\Program Files (x86)\MSBuild\12.0\Bin\msbuild.exe" NotifyIconWpf\NotifyIconWpf.csproj /p:Configuration=Release;TargetFrameworkVersion=v4.5.1;TargetFrameworkProfile="";OutputPath=..\..\Binaries\net451 /t:Rebuild
|
|
||||||
@@ -1,20 +0,0 @@
|
|||||||
del /s /ah /f *.suo
|
|
||||||
del /s /f *.user
|
|
||||||
del /s /f *.cache
|
|
||||||
del /s /f *.scc
|
|
||||||
del /s /f *.vssscc
|
|
||||||
del /s /f *.vspscc
|
|
||||||
del /s /f *.keep
|
|
||||||
del /s /ah /f vssver2.scc
|
|
||||||
|
|
||||||
rd /s /q bin obj ClientBin _Resharper.* _Upgrade*
|
|
||||||
|
|
||||||
del dirs.txt
|
|
||||||
dir /s /b /ad bin > dirs.txt
|
|
||||||
dir /s /b /ad obj >> dirs.txt
|
|
||||||
dir /s /b /ad ClientBin >> dirs.txt
|
|
||||||
dir /s /b /ad _Resharper.* >> dirs.txt
|
|
||||||
dir /s /b /ad _Upgrade* >> dirs.txt
|
|
||||||
|
|
||||||
for /f "delims=;" %%i in (dirs.txt) DO rd /s /q "%%i"
|
|
||||||
del dirs.txt
|
|
||||||
@@ -1,43 +0,0 @@
|
|||||||
<Project>
|
|
||||||
|
|
||||||
<PropertyGroup>
|
|
||||||
<TargetFrameworks>net40;net45;net452;net46;net462;net47;net472</TargetFrameworks>
|
|
||||||
<LangVersion>7.3</LangVersion>
|
|
||||||
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
|
|
||||||
<AppendTargetFrameworkToOutputPath>true</AppendTargetFrameworkToOutputPath>
|
|
||||||
<DebugType>full</DebugType>
|
|
||||||
<DebugSymbols>true</DebugSymbols>
|
|
||||||
|
|
||||||
<IsSampleProject>$(MSBuildProjectName.Contains('Sample'))</IsSampleProject>
|
|
||||||
</PropertyGroup>
|
|
||||||
|
|
||||||
<Choose>
|
|
||||||
<When Condition=" '$(IsSampleProject)' != 'true' ">
|
|
||||||
<PropertyGroup>
|
|
||||||
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
|
||||||
</PropertyGroup>
|
|
||||||
|
|
||||||
<ItemGroup>
|
|
||||||
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.0.0-beta2*" PrivateAssets="All" />
|
|
||||||
</ItemGroup>
|
|
||||||
|
|
||||||
<!-- SourceLink -->
|
|
||||||
<PropertyGroup>
|
|
||||||
<!-- Optional: Declare that the Repository URL can be published to NuSpec -->
|
|
||||||
<PublishRepositoryUrl>true</PublishRepositoryUrl>
|
|
||||||
<!-- Optional: Embed source files that are not tracked by the source control manager to the PDB -->
|
|
||||||
<EmbedUntrackedSources>true</EmbedUntrackedSources>
|
|
||||||
<!-- https://github.com/dotnet/sourcelink/blob/master/docs/README.md#embedallsources -->
|
|
||||||
<EmbedAllSources>true</EmbedAllSources>
|
|
||||||
<!-- Optional: Include PDB in the built .nupkg -->
|
|
||||||
<AllowedOutputExtensionsInPackageBuildOutputFolder>$(AllowedOutputExtensionsInPackageBuildOutputFolder);.pdb</AllowedOutputExtensionsInPackageBuildOutputFolder>
|
|
||||||
</PropertyGroup>
|
|
||||||
</When>
|
|
||||||
</Choose>
|
|
||||||
|
|
||||||
<ItemGroup>
|
|
||||||
<None Remove="**\*.png;**\*.jpg;**\*.ico" />
|
|
||||||
<Resource Include="**\*.png;**\*.jpg;**\*.ico" />
|
|
||||||
</ItemGroup>
|
|
||||||
|
|
||||||
</Project>
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
{
|
|
||||||
"msbuild-sdks": {
|
|
||||||
"MSBuild.Sdk.Extras": "1.6.65"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
56
azure-pipelines.yml
Normal file
@@ -0,0 +1,56 @@
|
|||||||
|
# .NET Desktop
|
||||||
|
# Build and run tests for .NET Desktop or Windows classic desktop solutions.
|
||||||
|
# Add steps that publish symbols, save build artifacts, and more:
|
||||||
|
# https://docs.microsoft.com/azure/devops/pipelines/apps/windows/dot-net
|
||||||
|
|
||||||
|
trigger:
|
||||||
|
batch: true
|
||||||
|
branches:
|
||||||
|
include:
|
||||||
|
- master
|
||||||
|
- feature/*
|
||||||
|
exclude:
|
||||||
|
- gh-pages
|
||||||
|
|
||||||
|
stages:
|
||||||
|
- stage: Build
|
||||||
|
jobs:
|
||||||
|
- job: Build
|
||||||
|
pool:
|
||||||
|
vmImage: 'Windows-latest'
|
||||||
|
|
||||||
|
variables:
|
||||||
|
solution: '**/src/*.sln'
|
||||||
|
buildPlatform: 'Any CPU'
|
||||||
|
buildConfiguration: 'Release'
|
||||||
|
|
||||||
|
steps:
|
||||||
|
|
||||||
|
- task: NuGetToolInstaller@1
|
||||||
|
inputs:
|
||||||
|
versionSpec: '5.5.1'
|
||||||
|
|
||||||
|
- task: UseDotNet@2
|
||||||
|
displayName: 'Use .NET Core sdk 3.1.2'
|
||||||
|
inputs:
|
||||||
|
packageType: sdk
|
||||||
|
version: 3.1.201
|
||||||
|
|
||||||
|
- task: DotNetCoreCLI@2
|
||||||
|
displayName: Build
|
||||||
|
inputs:
|
||||||
|
command: build
|
||||||
|
projects: '$(solution)'
|
||||||
|
arguments: '--configuration $(buildConfiguration) /p:Platform="$(buildPlatform)"'
|
||||||
|
|
||||||
|
- task: CopyFiles@2
|
||||||
|
displayName: 'Copy Files to: $(Build.ArtifactStagingDirectory)'
|
||||||
|
inputs:
|
||||||
|
SourceFolder: '$(System.DefaultWorkingDirectory)'
|
||||||
|
Contents: |
|
||||||
|
**\bin\$(buildConfiguration)\*.nupkg
|
||||||
|
TargetFolder: '$(Build.ArtifactStagingDirectory)'
|
||||||
|
flattenFolders: true
|
||||||
|
|
||||||
|
- publish: $(Build.ArtifactStagingDirectory)
|
||||||
|
artifact: drop
|
||||||
@@ -1,7 +1,19 @@
|
|||||||
hardcodet.net NotifyIcon for WPF - Changelog
|
hardcodet.net NotifyIcon for WPF - Changelog
|
||||||
Copyright (c) 2009-2016 Philipp Sumi
|
Copyright (c) 2009-2020 Philipp Sumi
|
||||||
Contact and Information: http://www.hardcodet.net
|
Contact and Information: http://www.hardcodet.net
|
||||||
|
|
||||||
|
1.0.9 (2020.xx.xx)
|
||||||
|
*****
|
||||||
|
|
||||||
|
ADD Added dotnet core 3.0 and 3.1 support
|
||||||
|
|
||||||
|
|
||||||
|
1.0.8 (2016.04.02)
|
||||||
|
*****
|
||||||
|
|
||||||
|
FIX Delayed message sink listener causing interop issues.
|
||||||
|
|
||||||
|
|
||||||
1.0.7 (2016.04.01)
|
1.0.7 (2016.04.01)
|
||||||
*****
|
*****
|
||||||
|
|
||||||
77
src/Directory.Build.props
Normal file
@@ -0,0 +1,77 @@
|
|||||||
|
<Project>
|
||||||
|
<PropertyGroup>
|
||||||
|
<LangVersion>latest</LangVersion>
|
||||||
|
<UseWindowsForms>true</UseWindowsForms>
|
||||||
|
<UseWPF>true</UseWPF>
|
||||||
|
<AppendTargetFrameworkToOutputPath>true</AppendTargetFrameworkToOutputPath>
|
||||||
|
<IsSampleProject>$(MSBuildProjectName.Contains('Sample'))</IsSampleProject>
|
||||||
|
<Copyright>Copyright (c) 2009-2020 Philipp Sumi</Copyright>
|
||||||
|
<Company>hardcodet.net</Company>
|
||||||
|
<Authors>Philipp Sumi</Authors>
|
||||||
|
<PackageIcon>icon.png</PackageIcon>
|
||||||
|
<RepositoryUrl>https://github.com/hardcodet/wpf-notifyicon</RepositoryUrl>
|
||||||
|
<RepositoryType>git</RepositoryType>
|
||||||
|
<PackageProjectUrl>hhttp://www.hardcodet.net/projects/wpf-notifyicon</PackageProjectUrl>
|
||||||
|
<PackageLicenseExpression>CPOL-1.02</PackageLicenseExpression>
|
||||||
|
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||||
|
<Description>This is an implementation of a NotifyIcon (aka system tray icon or taskbar icon) for the WPF platform. It does not just rely on the Windows Forms NotifyIcon component, but is a purely independent control which leverages several features of the WPF framework in order to display rich tooltips, popups, context menus, and balloon messages. It can be used directly in code or embedded in any XAML file.
|
||||||
|
|
||||||
|
Source code and extensive sample application available at http://www.hardcodet.net/projects/wpf-notifyicon</Description>
|
||||||
|
<Summary>NotifyIcon (aka system tray icon or taskbar icon) for the WPF platform.</Summary>
|
||||||
|
<language />
|
||||||
|
<tags>NotifyIcon WPF Tray Notify ToolTip Popup Balloon Toast</tags>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<PropertyGroup Condition="$(TargetFramework.StartsWith('net4'))">
|
||||||
|
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<PropertyGroup Condition="'$(Configuration)' == 'Debug'">
|
||||||
|
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||||
|
<DebugSymbols>True</DebugSymbols>
|
||||||
|
<CheckForOverflowUnderflow>true</CheckForOverflowUnderflow>
|
||||||
|
<DebugType>embedded</DebugType>
|
||||||
|
<Optimize>false</Optimize>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<PropertyGroup Condition="'$(Configuration)' == 'Release'">
|
||||||
|
<Optimize>true</Optimize>
|
||||||
|
<DebugType>embedded</DebugType>
|
||||||
|
<DebugSymbols>True</DebugSymbols>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<Choose>
|
||||||
|
<When Condition=" '$(IsSampleProject)' != 'true' ">
|
||||||
|
<PropertyGroup>
|
||||||
|
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
||||||
|
<IsPackable>true</IsPackable>
|
||||||
|
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<PackageReference Include="Nerdbank.GitVersioning" Version="3.1.91">
|
||||||
|
<PrivateAssets>all</PrivateAssets>
|
||||||
|
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
|
||||||
|
</PackageReference>
|
||||||
|
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.0.0" PrivateAssets="All"/>
|
||||||
|
<None Include="$(SolutionDir)\icon.png" Pack="true" PackagePath="\"/>
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
|
<!-- SourceLink -->
|
||||||
|
<PropertyGroup>
|
||||||
|
<!-- Optional: Declare that the Repository URL can be published to NuSpec -->
|
||||||
|
<PublishRepositoryUrl>true</PublishRepositoryUrl>
|
||||||
|
<!-- Optional: Embed source files that are not tracked by the source control manager to the PDB -->
|
||||||
|
<EmbedUntrackedSources>true</EmbedUntrackedSources>
|
||||||
|
<!-- https://github.com/dotnet/sourcelink/blob/master/docs/README.md#embedallsources -->
|
||||||
|
<EmbedAllSources>true</EmbedAllSources>
|
||||||
|
</PropertyGroup>
|
||||||
|
</When>
|
||||||
|
</Choose>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<None Remove="**\*.png;**\*.jpg;**\*.ico" />
|
||||||
|
<Resource Include="**\*.png;**\*.jpg;**\*.ico" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
|
</Project>
|
||||||
@@ -5,9 +5,11 @@ VisualStudioVersion = 16.0.28711.60
|
|||||||
MinimumVisualStudioVersion = 10.0.40219.1
|
MinimumVisualStudioVersion = 10.0.40219.1
|
||||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{C37AE34D-A8C4-4AEC-995C-3C763300934E}"
|
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{C37AE34D-A8C4-4AEC-995C-3C763300934E}"
|
||||||
ProjectSection(SolutionItems) = preProject
|
ProjectSection(SolutionItems) = preProject
|
||||||
|
..\azure-pipelines.yml = ..\azure-pipelines.yml
|
||||||
Changelog.txt = Changelog.txt
|
Changelog.txt = Changelog.txt
|
||||||
Directory.Build.props = Directory.Build.props
|
Directory.Build.props = Directory.Build.props
|
||||||
global.json = global.json
|
global.json = global.json
|
||||||
|
version.json = version.json
|
||||||
EndProjectSection
|
EndProjectSection
|
||||||
EndProject
|
EndProject
|
||||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NotifyIconWpf", "NotifyIconWpf\NotifyIconWpf.csproj", "{7AC63864-7638-41C4-969C-D3197EF2BED9}"
|
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NotifyIconWpf", "NotifyIconWpf\NotifyIconWpf.csproj", "{7AC63864-7638-41C4-969C-D3197EF2BED9}"
|
||||||
@@ -6,9 +6,12 @@ using System.Runtime.InteropServices;
|
|||||||
|
|
||||||
namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// This contains the logic to access the location of the app bar and communicate with it.
|
||||||
|
/// </summary>
|
||||||
public class AppBarInfo
|
public class AppBarInfo
|
||||||
{
|
{
|
||||||
[DllImport("user32.dll")]
|
[DllImport("user32.dll", CharSet = CharSet.Unicode)]
|
||||||
private static extern IntPtr FindWindow(string lpClassName, string lpWindowName);
|
private static extern IntPtr FindWindow(string lpClassName, string lpWindowName);
|
||||||
|
|
||||||
[DllImport("shell32.dll")]
|
[DllImport("shell32.dll")]
|
||||||
@@ -18,24 +21,22 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
private static extern int SystemParametersInfo(uint uiAction, uint uiParam,
|
private static extern int SystemParametersInfo(uint uiAction, uint uiParam,
|
||||||
IntPtr pvParam, uint fWinIni);
|
IntPtr pvParam, uint fWinIni);
|
||||||
|
|
||||||
|
|
||||||
private const int ABE_BOTTOM = 3;
|
|
||||||
private const int ABE_LEFT = 0;
|
|
||||||
private const int ABE_RIGHT = 2;
|
|
||||||
private const int ABE_TOP = 1;
|
|
||||||
|
|
||||||
private const int ABM_GETTASKBARPOS = 0x00000005;
|
private const int ABM_GETTASKBARPOS = 0x00000005;
|
||||||
|
|
||||||
// SystemParametersInfo constants
|
|
||||||
private const uint SPI_GETWORKAREA = 0x0030;
|
|
||||||
|
|
||||||
private APPBARDATA m_data;
|
private APPBARDATA m_data;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Get on which edge the app bar is located
|
||||||
|
/// </summary>
|
||||||
public ScreenEdge Edge
|
public ScreenEdge Edge
|
||||||
{
|
{
|
||||||
get { return (ScreenEdge) m_data.uEdge; }
|
get { return (ScreenEdge) m_data.uEdge; }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Get the working area
|
||||||
|
/// </summary>
|
||||||
public Rectangle WorkArea
|
public Rectangle WorkArea
|
||||||
{
|
{
|
||||||
get { return GetRectangle(m_data.rc); }
|
get { return GetRectangle(m_data.rc); }
|
||||||
@@ -44,9 +45,14 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
private Rectangle GetRectangle(RECT rc)
|
private Rectangle GetRectangle(RECT rc)
|
||||||
{
|
{
|
||||||
return new Rectangle(rc.left, rc.top, rc.right - rc.left, rc.bottom - rc.top);
|
return new Rectangle(rc.left, rc.top, rc.right - rc.left, rc.bottom - rc.top);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void GetPosition(string strClassName, string strWindowName)
|
/// <summary>
|
||||||
|
/// Update the location of the appbar with the specified classname and window name.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="strClassName">string</param>
|
||||||
|
/// <param name="strWindowName">string</param>
|
||||||
|
private void GetPosition(string strClassName, string strWindowName)
|
||||||
{
|
{
|
||||||
m_data = new APPBARDATA();
|
m_data = new APPBARDATA();
|
||||||
m_data.cbSize = (uint) Marshal.SizeOf(m_data.GetType());
|
m_data.cbSize = (uint) Marshal.SizeOf(m_data.GetType());
|
||||||
@@ -68,23 +74,41 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Updates the system taskbar position
|
||||||
|
/// </summary>
|
||||||
public void GetSystemTaskBarPosition()
|
public void GetSystemTaskBarPosition()
|
||||||
{
|
{
|
||||||
GetPosition("Shell_TrayWnd", null);
|
GetPosition("Shell_TrayWnd", null);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// A value that specifies an edge of the screen.
|
||||||
|
/// </summary>
|
||||||
public enum ScreenEdge
|
public enum ScreenEdge
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Undefined
|
||||||
|
/// </summary>
|
||||||
Undefined = -1,
|
Undefined = -1,
|
||||||
Left = ABE_LEFT,
|
/// <summary>
|
||||||
Top = ABE_TOP,
|
/// Left edge.
|
||||||
Right = ABE_RIGHT,
|
/// </summary>
|
||||||
Bottom = ABE_BOTTOM
|
Left = 0,
|
||||||
|
/// <summary>
|
||||||
|
/// Top edge.
|
||||||
|
/// </summary>
|
||||||
|
Top = 1,
|
||||||
|
/// <summary>
|
||||||
|
/// Right edge.
|
||||||
|
/// </summary>
|
||||||
|
Right = 2,
|
||||||
|
/// <summary>
|
||||||
|
/// Bottom edge.
|
||||||
|
/// </summary>
|
||||||
|
Bottom = 3
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
[StructLayout(LayoutKind.Sequential)]
|
[StructLayout(LayoutKind.Sequential)]
|
||||||
private struct APPBARDATA
|
private struct APPBARDATA
|
||||||
{
|
{
|
||||||
@@ -1,17 +1,17 @@
|
|||||||
<Project Sdk="MSBuild.Sdk.Extras">
|
<Project Sdk="Microsoft.NET.Sdk.WindowsDesktop">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<RootNamespace>Hardcodet.Wpf.TaskbarNotification</RootNamespace>
|
<RootNamespace>Hardcodet.Wpf.TaskbarNotification</RootNamespace>
|
||||||
<AssemblyName>Hardcodet.Wpf.TaskbarNotification</AssemblyName>
|
<AssemblyName>Hardcodet.Wpf.TaskbarNotification</AssemblyName>
|
||||||
<AssemblyTitle>NotifyIcon for WPF</AssemblyTitle>
|
<AssemblyTitle>NotifyIcon for WPF</AssemblyTitle>
|
||||||
<Company>hardcodet.net</Company>
|
|
||||||
<Product>NotifyIcon WPF</Product>
|
<Product>NotifyIcon WPF</Product>
|
||||||
<Description>NotifyIcon implementation for the WPF platform.</Description>
|
<TargetFrameworks>net45;net472;netcoreapp3.0;netcoreapp3.1</TargetFrameworks>
|
||||||
<Copyright>Copyright © Philipp Sumi 2013</Copyright>
|
|
||||||
<AssemblyVersion>1.0.8.0</AssemblyVersion>
|
|
||||||
<FileVersion>1.0.8.0</FileVersion>
|
|
||||||
<ExtrasEnableWpfProjectSetup>true</ExtrasEnableWpfProjectSetup>
|
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
|
||||||
|
<ItemGroup Condition="'$(TargetFramework)' != 'net45'">
|
||||||
|
<PackageReference Include="System.Resources.Extensions" Version="4.7.0" PrivateAssets="All" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
|
<ItemGroup Condition="$(TargetFramework.StartsWith('net4'))">
|
||||||
<Reference Include="System.Xaml" />
|
<Reference Include="System.Xaml" />
|
||||||
<Reference Include="WindowsBase" />
|
<Reference Include="WindowsBase" />
|
||||||
<Reference Include="PresentationCore" />
|
<Reference Include="PresentationCore" />
|
||||||
6
src/NuGet.Config
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<configuration>
|
||||||
|
<packageSources>
|
||||||
|
<add key="nugetv3" value="https://api.nuget.org/v3/index.json" />
|
||||||
|
</packageSources>
|
||||||
|
</configuration>
|
||||||
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 41 KiB After Width: | Height: | Size: 41 KiB |
|
Before Width: | Height: | Size: 502 B After Width: | Height: | Size: 502 B |
|
Before Width: | Height: | Size: 667 B After Width: | Height: | Size: 667 B |
|
Before Width: | Height: | Size: 6.9 KiB After Width: | Height: | Size: 6.9 KiB |
|
Before Width: | Height: | Size: 113 KiB After Width: | Height: | Size: 113 KiB |
|
Before Width: | Height: | Size: 7.6 KiB After Width: | Height: | Size: 7.6 KiB |
|
Before Width: | Height: | Size: 237 B After Width: | Height: | Size: 237 B |
@@ -1,15 +1,20 @@
|
|||||||
<Project Sdk="MSBuild.Sdk.Extras">
|
<Project Sdk="Microsoft.NET.Sdk.WindowsDesktop">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<OutputType>WinExe</OutputType>
|
<OutputType>WinExe</OutputType>
|
||||||
|
<TargetFrameworks>net472;netcoreapp3.1</TargetFrameworks>
|
||||||
<RootNamespace>Samples</RootNamespace>
|
<RootNamespace>Samples</RootNamespace>
|
||||||
<AssemblyTitle>Sample Project</AssemblyTitle>
|
<AssemblyTitle>Sample Project</AssemblyTitle>
|
||||||
<Product>Sample Project</Product>
|
<Product>Sample Project</Product>
|
||||||
<ExtrasEnableWpfProjectSetup>true</ExtrasEnableWpfProjectSetup>
|
<GenerateResourceUsePreserializedResources>true</GenerateResourceUsePreserializedResources>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\NotifyIconWpf\NotifyIconWpf.csproj" />
|
<ProjectReference Include="..\NotifyIconWpf\NotifyIconWpf.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup Condition="'$(TargetFramework)' != 'net45'">
|
||||||
|
<PackageReference Include="System.Resources.Extensions" Version="4.7.0" PrivateAssets="All"/>
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
|
<ItemGroup Condition="$(TargetFramework.StartsWith('net4'))">
|
||||||
<Reference Include="PresentationFramework.Aero" />
|
<Reference Include="PresentationFramework.Aero" />
|
||||||
<Reference Include="System.Xaml" />
|
<Reference Include="System.Xaml" />
|
||||||
<Reference Include="System.Data.DataSetExtensions" />
|
<Reference Include="System.Data.DataSetExtensions" />
|
||||||
|
Before Width: | Height: | Size: 20 KiB After Width: | Height: | Size: 20 KiB |