From a91d33b0787ff8c3e42b7f1dd590c55cb2be1389 Mon Sep 17 00:00:00 2001 From: NaBian <836904362@qq.com> Date: Tue, 10 Sep 2019 23:41:10 +0800 Subject: [PATCH] modified the branch --- .../Data/MessageToken.cs | 4 + .../Data/MessageToken.tt | 4 +- .../Controls/NotifyIconDemoCtl.xaml | 59 +++--- .../Controls/NotifyIconDemoViewModel.cs | 21 ++ .../Controls/Other/NotifyIcon.cs | 191 ++++++++++++------ .../{ToolTipIcon.cs => NotifyIconInfoType.cs} | 10 +- .../HandyControl_Shared.projitems | 2 +- .../Tools/Interop/NativeMethods.cs | 1 + 8 files changed, 201 insertions(+), 91 deletions(-) rename src/Shared/HandyControl_Shared/Data/Enum/{ToolTipIcon.cs => NotifyIconInfoType.cs} (76%) diff --git a/src/Shared/HandyControlDemo_Shared/Data/MessageToken.cs b/src/Shared/HandyControlDemo_Shared/Data/MessageToken.cs index 3ffee119..818d5fba 100644 --- a/src/Shared/HandyControlDemo_Shared/Data/MessageToken.cs +++ b/src/Shared/HandyControlDemo_Shared/Data/MessageToken.cs @@ -198,5 +198,9 @@ public static readonly string BlogsView = nameof(BlogsView); + public static readonly string NotifyIconDemo = nameof(NotifyIconDemo); + + public static readonly string NotifyIconContextDemo = nameof(NotifyIconContextDemo); + } } \ No newline at end of file diff --git a/src/Shared/HandyControlDemo_Shared/Data/MessageToken.tt b/src/Shared/HandyControlDemo_Shared/Data/MessageToken.tt index 2978eea6..01e20c31 100644 --- a/src/Shared/HandyControlDemo_Shared/Data/MessageToken.tt +++ b/src/Shared/HandyControlDemo_Shared/Data/MessageToken.tt @@ -110,7 +110,9 @@ var messageList = new List "MainWindow", "OverView", "ProjectsView", - "BlogsView" + "BlogsView", + "NotifyIconDemo", + "NotifyIconContextDemo" }; #> namespace HandyControlDemo.Data diff --git a/src/Shared/HandyControlDemo_Shared/UserControl/Controls/NotifyIconDemoCtl.xaml b/src/Shared/HandyControlDemo_Shared/UserControl/Controls/NotifyIconDemoCtl.xaml index 98d1ac7c..4149ef39 100644 --- a/src/Shared/HandyControlDemo_Shared/UserControl/Controls/NotifyIconDemoCtl.xaml +++ b/src/Shared/HandyControlDemo_Shared/UserControl/Controls/NotifyIconDemoCtl.xaml @@ -5,35 +5,42 @@ xmlns:hc="https://handyorg.github.io/handycontrol" xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity" xmlns:command="http://www.galasoft.ch/mvvmlight" + xmlns:data="clr-namespace:HandyControlDemo.Data" DataContext="{Binding NotifyIconDemo,Source={StaticResource Locator}}" Background="{DynamicResource RegionBrush}"> - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + +