mirror of
https://github.com/ckaczor/wpf-notifyicon.git
synced 2026-02-16 18:49:54 -05:00
CHG Reformatting code (NTFY-20).
git-svn-id: https://svn.evolvesoftware.ch/repos/evolve.net/WPF/NotifyIcon@192 9f600761-6f11-4665-b6dc-0185e9171623
This commit is contained in:
@@ -33,14 +33,17 @@ namespace Hardcodet.Wpf.TaskbarNotification
|
|||||||
/// The balloon message is displayed without an icon.
|
/// The balloon message is displayed without an icon.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
None,
|
None,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// An information is displayed.
|
/// An information is displayed.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
Info,
|
Info,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// A warning is displayed.
|
/// A warning is displayed.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
Warning,
|
Warning,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// An error is displayed.
|
/// An error is displayed.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@@ -10,28 +10,34 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
/// No icon is displayed.
|
/// No icon is displayed.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
None = 0x00,
|
None = 0x00,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// An information icon is displayed.
|
/// An information icon is displayed.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
Info = 0x01,
|
Info = 0x01,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// A warning icon is displayed.
|
/// A warning icon is displayed.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
Warning = 0x02,
|
Warning = 0x02,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// An error icon is displayed.
|
/// An error icon is displayed.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
Error = 0x03,
|
Error = 0x03,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Windows XP Service Pack 2 (SP2) and later.
|
/// Windows XP Service Pack 2 (SP2) and later.
|
||||||
/// Use a custom icon as the title icon.
|
/// Use a custom icon as the title icon.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
User = 0x04,
|
User = 0x04,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Windows XP (Shell32.dll version 6.0) and later.
|
/// Windows XP (Shell32.dll version 6.0) and later.
|
||||||
/// Do not play the associated sound. Applies only to balloon ToolTips.
|
/// Do not play the associated sound. Applies only to balloon ToolTips.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
NoSound = 0x10,
|
NoSound = 0x10,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Windows Vista (Shell32.dll version 6.0.6) and later. The large version
|
/// Windows Vista (Shell32.dll version 6.0.6) and later. The large version
|
||||||
/// of the icon should be used as the balloon icon. This corresponds to the
|
/// of the icon should be used as the balloon icon. This corresponds to the
|
||||||
@@ -46,10 +52,10 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
/// SM_CXICON x SM_CYICON version in the supplied icon (hBalloonIcon).
|
/// SM_CXICON x SM_CYICON version in the supplied icon (hBalloonIcon).
|
||||||
/// </summary>
|
/// </summary>
|
||||||
LargeIcon = 0x20,
|
LargeIcon = 0x20,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Windows 7 and later.
|
/// Windows 7 and later.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
RespectQuietTime = 0x80
|
RespectQuietTime = 0x80
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -14,20 +14,24 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
/// The message ID is set.
|
/// The message ID is set.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
Message = 0x01,
|
Message = 0x01,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The notification icon is set.
|
/// The notification icon is set.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
Icon = 0x02,
|
Icon = 0x02,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The tooltip is set.
|
/// The tooltip is set.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
Tip = 0x04,
|
Tip = 0x04,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// State information (<see cref="IconState"/>) is set. This
|
/// State information (<see cref="IconState"/>) is set. This
|
||||||
/// applies to both <see cref="NotifyIconData.IconState"/> and
|
/// applies to both <see cref="NotifyIconData.IconState"/> and
|
||||||
/// <see cref="NotifyIconData.StateMask"/>.
|
/// <see cref="NotifyIconData.StateMask"/>.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
State = 0x08,
|
State = 0x08,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The balloon ToolTip is set. Accordingly, the following
|
/// The balloon ToolTip is set. Accordingly, the following
|
||||||
/// members are set: <see cref="NotifyIconData.BalloonText"/>,
|
/// members are set: <see cref="NotifyIconData.BalloonText"/>,
|
||||||
@@ -40,7 +44,6 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
/// Internal identifier is set. Reserved, thus commented out.
|
/// Internal identifier is set. Reserved, thus commented out.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
//Guid = 0x20,
|
//Guid = 0x20,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Windows Vista (Shell32.dll version 6.0.6) and later. If the ToolTip
|
/// Windows Vista (Shell32.dll version 6.0.6) and later. If the ToolTip
|
||||||
/// cannot be displayed immediately, discard it.<br/>
|
/// cannot be displayed immediately, discard it.<br/>
|
||||||
@@ -50,6 +53,7 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
/// This modifies and must be combined with the <see cref="Info"/> flag.
|
/// This modifies and must be combined with the <see cref="Info"/> flag.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
Realtime = 0x40,
|
Realtime = 0x40,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Windows Vista (Shell32.dll version 6.0.6) and later.
|
/// Windows Vista (Shell32.dll version 6.0.6) and later.
|
||||||
/// Use the standard ToolTip. Normally, when uVersion is set
|
/// Use the standard ToolTip. Normally, when uVersion is set
|
||||||
|
|||||||
@@ -10,6 +10,7 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
/// The icon is visible.
|
/// The icon is visible.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
Visible = 0x00,
|
Visible = 0x00,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Hide the icon.
|
/// Hide the icon.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@@ -1,6 +1,4 @@
|
|||||||
|
namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
||||||
|
|
||||||
namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Event flags for clicked events.
|
/// Event flags for clicked events.
|
||||||
@@ -12,34 +10,42 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
/// taskbar icon's area.
|
/// taskbar icon's area.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
MouseMove,
|
MouseMove,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The right mouse button was clicked.
|
/// The right mouse button was clicked.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
IconRightMouseDown,
|
IconRightMouseDown,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The left mouse button was clicked.
|
/// The left mouse button was clicked.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
IconLeftMouseDown,
|
IconLeftMouseDown,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The right mouse button was released.
|
/// The right mouse button was released.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
IconRightMouseUp,
|
IconRightMouseUp,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The left mouse button was released.
|
/// The left mouse button was released.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
IconLeftMouseUp,
|
IconLeftMouseUp,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The middle mouse button was clicked.
|
/// The middle mouse button was clicked.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
IconMiddleMouseDown,
|
IconMiddleMouseDown,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The middle mouse button was released.
|
/// The middle mouse button was released.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
IconMiddleMouseUp,
|
IconMiddleMouseUp,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The taskbar icon was double clicked.
|
/// The taskbar icon was double clicked.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
IconDoubleClick,
|
IconDoubleClick,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The balloon tip was clicked.
|
/// The balloon tip was clicked.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@@ -1,5 +1,3 @@
|
|||||||
|
|
||||||
|
|
||||||
namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@@ -12,18 +10,22 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
/// The taskbar icon is being created.
|
/// The taskbar icon is being created.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
Add = 0x00,
|
Add = 0x00,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The settings of the taskbar icon are being updated.
|
/// The settings of the taskbar icon are being updated.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
Modify = 0x01,
|
Modify = 0x01,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The taskbar icon is deleted.
|
/// The taskbar icon is deleted.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
Delete = 0x02,
|
Delete = 0x02,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Focus is returned to the taskbar icon. Currently not in use.
|
/// Focus is returned to the taskbar icon. Currently not in use.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
SetFocus = 0x03,
|
SetFocus = 0x03,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Shell32.dll version 5.0 and later only. Instructs the taskbar
|
/// Shell32.dll version 5.0 and later only. Instructs the taskbar
|
||||||
/// to behave according to the version number specified in the
|
/// to behave according to the version number specified in the
|
||||||
|
|||||||
@@ -11,11 +11,13 @@
|
|||||||
/// a <see cref="NotifyIconData"/> size of 488.
|
/// a <see cref="NotifyIconData"/> size of 488.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
Win95 = 0x0,
|
Win95 = 0x0,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Behavior representing Win2000 an higher. Expects
|
/// Behavior representing Win2000 an higher. Expects
|
||||||
/// a <see cref="NotifyIconData"/> size of 504.
|
/// a <see cref="NotifyIconData"/> size of 504.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
Win2000 = 0x3,
|
Win2000 = 0x3,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Extended tooltip support, which is available
|
/// Extended tooltip support, which is available
|
||||||
/// for Vista and later.
|
/// for Vista and later.
|
||||||
|
|||||||
@@ -50,11 +50,8 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
internal class AppBarInfo
|
internal class AppBarInfo
|
||||||
{
|
{
|
||||||
|
|
||||||
[DllImport("user32.dll")]
|
[DllImport("user32.dll")]
|
||||||
private static extern IntPtr FindWindow(String lpClassName, String lpWindowName);
|
private static extern IntPtr FindWindow(String lpClassName, String lpWindowName);
|
||||||
|
|
||||||
@@ -105,7 +102,6 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public void GetPosition(string strClassName, string strWindowName)
|
public void GetPosition(string strClassName, string strWindowName)
|
||||||
{
|
{
|
||||||
m_data = new APPBARDATA();
|
m_data = new APPBARDATA();
|
||||||
@@ -135,8 +131,6 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public enum ScreenEdge
|
public enum ScreenEdge
|
||||||
{
|
{
|
||||||
Undefined = -1,
|
Undefined = -1,
|
||||||
@@ -166,6 +160,5 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
public Int32 right;
|
public Int32 right;
|
||||||
public Int32 bottom;
|
public Int32 bottom;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -22,7 +22,6 @@
|
|||||||
// THIS COPYRIGHT NOTICE MAY NOT BE REMOVED FROM THIS FILE
|
// THIS COPYRIGHT NOTICE MAY NOT BE REMOVED FROM THIS FILE
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
using System.ComponentModel;
|
using System.ComponentModel;
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
@@ -36,7 +35,6 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public class WindowMessageSink : IDisposable
|
public class WindowMessageSink : IDisposable
|
||||||
{
|
{
|
||||||
|
|
||||||
#region members
|
#region members
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@@ -84,7 +82,6 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|
||||||
#region events
|
#region events
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@@ -112,7 +109,6 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|
||||||
#region construction
|
#region construction
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@@ -149,7 +145,6 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|
||||||
#region CreateMessageWindow
|
#region CreateMessageWindow
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@@ -187,7 +182,8 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
taskbarRestartMessageId = WinApi.RegisterWindowMessage("TaskbarCreated");
|
taskbarRestartMessageId = WinApi.RegisterWindowMessage("TaskbarCreated");
|
||||||
|
|
||||||
// Create the message window
|
// Create the message window
|
||||||
MessageWindowHandle = WinApi.CreateWindowEx(0, WindowId, "", 0, 0, 0, 1, 1, IntPtr.Zero, IntPtr.Zero, IntPtr.Zero, IntPtr.Zero);
|
MessageWindowHandle = WinApi.CreateWindowEx(0, WindowId, "", 0, 0, 0, 1, 1, IntPtr.Zero, IntPtr.Zero,
|
||||||
|
IntPtr.Zero, IntPtr.Zero);
|
||||||
|
|
||||||
if (MessageWindowHandle == IntPtr.Zero)
|
if (MessageWindowHandle == IntPtr.Zero)
|
||||||
{
|
{
|
||||||
@@ -201,7 +197,6 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|
||||||
#region Handle Window Messages
|
#region Handle Window Messages
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@@ -238,7 +233,8 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
switch (lParam.ToInt32())
|
switch (lParam.ToInt32())
|
||||||
{
|
{
|
||||||
case 0x200:
|
case 0x200:
|
||||||
MouseEventReceived(MouseEvent.MouseMove); break;
|
MouseEventReceived(MouseEvent.MouseMove);
|
||||||
|
break;
|
||||||
|
|
||||||
case 0x201:
|
case 0x201:
|
||||||
MouseEventReceived(MouseEvent.IconLeftMouseDown);
|
MouseEventReceived(MouseEvent.IconLeftMouseDown);
|
||||||
@@ -306,12 +302,10 @@ namespace Hardcodet.Wpf.TaskbarNotification.Interop
|
|||||||
Debug.WriteLine("Unhandled NotifyIcon message ID: " + lParam);
|
Debug.WriteLine("Unhandled NotifyIcon message ID: " + lParam);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|
||||||
#region Dispose
|
#region Dispose
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||||
@@ -10,11 +10,11 @@
|
|||||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||||
<RootNamespace>Hardcodet.Wpf.TaskbarNotification</RootNamespace>
|
<RootNamespace>Hardcodet.Wpf.TaskbarNotification</RootNamespace>
|
||||||
<AssemblyName>Hardcodet.Wpf.TaskbarNotification</AssemblyName>
|
<AssemblyName>Hardcodet.Wpf.TaskbarNotification</AssemblyName>
|
||||||
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
|
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
|
||||||
<FileAlignment>512</FileAlignment>
|
<FileAlignment>512</FileAlignment>
|
||||||
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
|
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
|
||||||
<WarningLevel>4</WarningLevel>
|
<WarningLevel>4</WarningLevel>
|
||||||
<TargetFrameworkSubset>Client</TargetFrameworkSubset>
|
<TargetFrameworkProfile>Client</TargetFrameworkProfile>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||||
<DebugSymbols>true</DebugSymbols>
|
<DebugSymbols>true</DebugSymbols>
|
||||||
@@ -25,6 +25,7 @@
|
|||||||
<ErrorReport>prompt</ErrorReport>
|
<ErrorReport>prompt</ErrorReport>
|
||||||
<WarningLevel>4</WarningLevel>
|
<WarningLevel>4</WarningLevel>
|
||||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||||
|
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||||
<DebugType>pdbonly</DebugType>
|
<DebugType>pdbonly</DebugType>
|
||||||
@@ -34,6 +35,7 @@
|
|||||||
<ErrorReport>prompt</ErrorReport>
|
<ErrorReport>prompt</ErrorReport>
|
||||||
<WarningLevel>4</WarningLevel>
|
<WarningLevel>4</WarningLevel>
|
||||||
<DocumentationFile>bin\Release\Hardcodet.Wpf.TaskbarNotification.xml</DocumentationFile>
|
<DocumentationFile>bin\Release\Hardcodet.Wpf.TaskbarNotification.xml</DocumentationFile>
|
||||||
|
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
@@ -41,6 +43,7 @@
|
|||||||
<RequiredTargetFramework>3.5</RequiredTargetFramework>
|
<RequiredTargetFramework>3.5</RequiredTargetFramework>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System.Drawing" />
|
<Reference Include="System.Drawing" />
|
||||||
|
<Reference Include="System.Xaml" />
|
||||||
<Reference Include="WindowsBase" />
|
<Reference Include="WindowsBase" />
|
||||||
<Reference Include="PresentationCore" />
|
<Reference Include="PresentationCore" />
|
||||||
<Reference Include="PresentationFramework" />
|
<Reference Include="PresentationFramework" />
|
||||||
|
|||||||
@@ -35,32 +35,38 @@ namespace Hardcodet.Wpf.TaskbarNotification
|
|||||||
/// tray icon with the left mouse button.
|
/// tray icon with the left mouse button.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
LeftClick,
|
LeftClick,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The item is displayed if the user clicks the
|
/// The item is displayed if the user clicks the
|
||||||
/// tray icon with the right mouse button.
|
/// tray icon with the right mouse button.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
RightClick,
|
RightClick,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The item is displayed if the user double-clicks the
|
/// The item is displayed if the user double-clicks the
|
||||||
/// tray icon.
|
/// tray icon.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
DoubleClick,
|
DoubleClick,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The item is displayed if the user clicks the
|
/// The item is displayed if the user clicks the
|
||||||
/// tray icon with the left or the right mouse button.
|
/// tray icon with the left or the right mouse button.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
LeftOrRightClick,
|
LeftOrRightClick,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The item is displayed if the user clicks the
|
/// The item is displayed if the user clicks the
|
||||||
/// tray icon with the left mouse button or if a
|
/// tray icon with the left mouse button or if a
|
||||||
/// double-click is being performed.
|
/// double-click is being performed.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
LeftOrDoubleClick,
|
LeftOrDoubleClick,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The item is displayed if the user clicks the
|
/// The item is displayed if the user clicks the
|
||||||
/// tray icon with the middle mouse button.
|
/// tray icon with the middle mouse button.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
MiddleClick,
|
MiddleClick,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The item is displayed whenever a click occurs.
|
/// The item is displayed whenever a click occurs.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@@ -6,21 +6,25 @@ using System.Windows.Markup;
|
|||||||
// General Information about an assembly is controlled through the following
|
// General Information about an assembly is controlled through the following
|
||||||
// set of attributes. Change these attribute values to modify the information
|
// set of attributes. Change these attribute values to modify the information
|
||||||
// associated with an assembly.
|
// associated with an assembly.
|
||||||
|
|
||||||
[assembly: AssemblyTitle("NotifyIcon for WPF")]
|
[assembly: AssemblyTitle("NotifyIcon for WPF")]
|
||||||
[assembly: AssemblyDescription("NotifyIcon Implementation for the WPF platform.")]
|
[assembly: AssemblyDescription("NotifyIcon implementation for the WPF platform.")]
|
||||||
[assembly: AssemblyConfiguration("")]
|
[assembly: AssemblyConfiguration("")]
|
||||||
[assembly: AssemblyCompany("hardcodet.net")]
|
[assembly: AssemblyCompany("hardcodet.net")]
|
||||||
[assembly: AssemblyProduct("NotifyIcon WPF")]
|
[assembly: AssemblyProduct("NotifyIcon WPF")]
|
||||||
[assembly: AssemblyCopyright("Copyright © Philipp Sumi 2009")]
|
[assembly: AssemblyCopyright("Copyright © Philipp Sumi 2046")]
|
||||||
[assembly: AssemblyTrademark("")]
|
[assembly: AssemblyTrademark("")]
|
||||||
[assembly: AssemblyCulture("")]
|
[assembly: AssemblyCulture("")]
|
||||||
|
|
||||||
//provides simplified declaration
|
//provides simplified declaration
|
||||||
|
|
||||||
|
[assembly: XmlnsPrefix("http://www.hardcodet.net/taskbar", "tb")]
|
||||||
[assembly: XmlnsDefinition("http://www.hardcodet.net/taskbar", "Hardcodet.Wpf.TaskbarNotification")]
|
[assembly: XmlnsDefinition("http://www.hardcodet.net/taskbar", "Hardcodet.Wpf.TaskbarNotification")]
|
||||||
|
|
||||||
// Setting ComVisible to false makes the types in this assembly not visible
|
// 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
|
// to COM components. If you need to access a type in this assembly from
|
||||||
// COM, set the ComVisible attribute to true on that type.
|
// COM, set the ComVisible attribute to true on that type.
|
||||||
|
|
||||||
[assembly: ComVisible(false)]
|
[assembly: ComVisible(false)]
|
||||||
|
|
||||||
//In order to begin building localizable applications, set
|
//In order to begin building localizable applications, set
|
||||||
@@ -53,5 +57,6 @@ using System.Windows.Markup;
|
|||||||
// You can specify all the values or you can default the Build and Revision Numbers
|
// You can specify all the values or you can default the Build and Revision Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
// [assembly: AssemblyVersion("1.0.*")]
|
// [assembly: AssemblyVersion("1.0.*")]
|
||||||
[assembly: AssemblyVersion("1.0.4.0")]
|
|
||||||
[assembly: AssemblyFileVersion("1.0.4.0")]
|
[assembly: AssemblyVersion("1.1.0.0")]
|
||||||
|
[assembly: AssemblyFileVersion("1.1.0.0")]
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
// <auto-generated>
|
// <auto-generated>
|
||||||
// This code was generated by a tool.
|
// This code was generated by a tool.
|
||||||
// Runtime Version:2.0.50727.3053
|
// Runtime Version:4.0.30319.18408
|
||||||
//
|
//
|
||||||
// Changes to this file may cause incorrect behavior and will be lost if
|
// Changes to this file may cause incorrect behavior and will be lost if
|
||||||
// the code is regenerated.
|
// the code is regenerated.
|
||||||
@@ -19,7 +19,7 @@ namespace Hardcodet.Wpf.TaskbarNotification.Properties {
|
|||||||
// class via a tool like ResGen or Visual Studio.
|
// class via a tool like ResGen or Visual Studio.
|
||||||
// To add or remove a member, edit your .ResX file then rerun ResGen
|
// To add or remove a member, edit your .ResX file then rerun ResGen
|
||||||
// with the /str option, or rebuild your VS project.
|
// with the /str option, or rebuild your VS project.
|
||||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "2.0.0.0")]
|
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
|
||||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||||
internal class Resources {
|
internal class Resources {
|
||||||
@@ -60,6 +60,9 @@ namespace Hardcodet.Wpf.TaskbarNotification.Properties {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Looks up a localized resource of type System.Drawing.Icon similar to (Icon).
|
||||||
|
/// </summary>
|
||||||
internal static System.Drawing.Icon DefaultTrayIcon {
|
internal static System.Drawing.Icon DefaultTrayIcon {
|
||||||
get {
|
get {
|
||||||
object obj = ResourceManager.GetObject("DefaultTrayIcon", resourceCulture);
|
object obj = ResourceManager.GetObject("DefaultTrayIcon", resourceCulture);
|
||||||
|
|||||||
@@ -61,7 +61,8 @@ namespace Hardcodet.Wpf.TaskbarNotification
|
|||||||
{
|
{
|
||||||
isDesignMode =
|
isDesignMode =
|
||||||
(bool)
|
(bool)
|
||||||
DependencyPropertyDescriptor.FromProperty(DesignerProperties.IsInDesignModeProperty, typeof (FrameworkElement))
|
DependencyPropertyDescriptor.FromProperty(DesignerProperties.IsInDesignModeProperty,
|
||||||
|
typeof (FrameworkElement))
|
||||||
.Metadata.DefaultValue;
|
.Metadata.DefaultValue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -13,6 +13,5 @@ namespace Samples
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public partial class App : Application
|
public partial class App : Application
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -71,7 +71,8 @@ namespace Samples.Commands
|
|||||||
get
|
get
|
||||||
{
|
{
|
||||||
return (bool)
|
return (bool)
|
||||||
DependencyPropertyDescriptor.FromProperty(DesignerProperties.IsInDesignModeProperty, typeof(FrameworkElement))
|
DependencyPropertyDescriptor.FromProperty(DesignerProperties.IsInDesignModeProperty,
|
||||||
|
typeof (FrameworkElement))
|
||||||
.Metadata.DefaultValue;
|
.Metadata.DefaultValue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -91,8 +92,6 @@ namespace Samples.Commands
|
|||||||
return tb == null ? null : TryFindParent<Window>(tb);
|
return tb == null ? null : TryFindParent<Window>(tb);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#region TryFindParent helper
|
#region TryFindParent helper
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|||||||
@@ -8,7 +8,6 @@ namespace Samples.Commands
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public class HideSampleWindowCommand : CommandBase<HideSampleWindowCommand>
|
public class HideSampleWindowCommand : CommandBase<HideSampleWindowCommand>
|
||||||
{
|
{
|
||||||
|
|
||||||
public override void Execute(object parameter)
|
public override void Execute(object parameter)
|
||||||
{
|
{
|
||||||
GetTaskbarWindow(parameter).Hide();
|
GetTaskbarWindow(parameter).Hide();
|
||||||
@@ -21,7 +20,5 @@ namespace Samples.Commands
|
|||||||
Window win = GetTaskbarWindow(parameter);
|
Window win = GetTaskbarWindow(parameter);
|
||||||
return win != null && win.IsVisible;
|
return win != null && win.IsVisible;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -30,8 +30,10 @@
|
|||||||
FontSize="14"
|
FontSize="14"
|
||||||
FontStyle="Italic"
|
FontStyle="Italic"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
Text="WPF NotifyIcon 1.0.4 - Samples" /></TextBlock>
|
<Run
|
||||||
|
Text="WPF NotifyIcon 1.0.4 - Samples" />
|
||||||
|
</TextBlock>
|
||||||
<Button
|
<Button
|
||||||
HorizontalAlignment="Left"
|
HorizontalAlignment="Left"
|
||||||
Margin="10,133,0,0"
|
Margin="10,133,0,0"
|
||||||
@@ -46,8 +48,10 @@
|
|||||||
Margin="10,50,0,0"
|
Margin="10,50,0,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
Text="Tutorials:" /></TextBlock>
|
<Run
|
||||||
|
Text="Tutorials:" />
|
||||||
|
</TextBlock>
|
||||||
<TextBlock
|
<TextBlock
|
||||||
HorizontalAlignment="Left"
|
HorizontalAlignment="Left"
|
||||||
Margin="10,75.96,0,0"
|
Margin="10,75.96,0,0"
|
||||||
@@ -55,8 +59,10 @@
|
|||||||
TextWrapping="Wrap"
|
TextWrapping="Wrap"
|
||||||
Width="224.31"
|
Width="224.31"
|
||||||
Height="47.04"
|
Height="47.04"
|
||||||
d:LayoutOverrides="HorizontalAlignment"><Run
|
d:LayoutOverrides="HorizontalAlignment">
|
||||||
Text="Tutorials follow the contents of the CodeProject article. Check the "Tutorials" folder for the source code." /></TextBlock>
|
<Run
|
||||||
|
Text="Tutorials follow the contents of the CodeProject article. Check the "Tutorials" folder for the source code." />
|
||||||
|
</TextBlock>
|
||||||
<Button
|
<Button
|
||||||
HorizontalAlignment="Left"
|
HorizontalAlignment="Left"
|
||||||
Margin="10,170,0,0"
|
Margin="10,170,0,0"
|
||||||
@@ -117,14 +123,18 @@
|
|||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
TextWrapping="Wrap"
|
TextWrapping="Wrap"
|
||||||
HorizontalAlignment="Right"
|
HorizontalAlignment="Right"
|
||||||
d:LayoutOverrides="HorizontalAlignment, Width"><Run
|
d:LayoutOverrides="HorizontalAlignment, Width">
|
||||||
Text="Showcase Sample:" /></TextBlock>
|
<Run
|
||||||
|
Text="Showcase Sample:" />
|
||||||
|
</TextBlock>
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Margin="255.31,75.96,145.38,0"
|
Margin="255.31,75.96,145.38,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
TextWrapping="Wrap"
|
TextWrapping="Wrap"
|
||||||
Height="47.04"><Run
|
Height="47.04">
|
||||||
Text="An interactive sample that shows off most features on a single NotifyIcon." /></TextBlock>
|
<Run
|
||||||
|
Text="An interactive sample that shows off most features on a single NotifyIcon." />
|
||||||
|
</TextBlock>
|
||||||
<Button
|
<Button
|
||||||
Margin="255.31,133,0,0"
|
Margin="255.31,133,0,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
@@ -153,7 +163,8 @@
|
|||||||
</Hyperlink>
|
</Hyperlink>
|
||||||
<LineBreak />
|
<LineBreak />
|
||||||
<LineBreak />
|
<LineBreak />
|
||||||
<Run Text="Critical feedback is appreciated - please post bug reports, requests, questions etc. to the CodeProject forum"/>
|
<Run
|
||||||
|
Text="Critical feedback is appreciated - please post bug reports, requests, questions etc. to the CodeProject forum" />
|
||||||
<Run Language="de-ch" Text=":" />
|
<Run Language="de-ch" Text=":" />
|
||||||
<LineBreak />
|
<LineBreak />
|
||||||
<Hyperlink NavigateUri="http://www.codeproject.com/KB/WPF/wpf_notifyicon.aspx">
|
<Hyperlink NavigateUri="http://www.codeproject.com/KB/WPF/wpf_notifyicon.aspx">
|
||||||
@@ -176,11 +187,17 @@
|
|||||||
VerticalAlignment="Bottom"
|
VerticalAlignment="Bottom"
|
||||||
Height="22.42"
|
Height="22.42"
|
||||||
TextWrapping="Wrap"
|
TextWrapping="Wrap"
|
||||||
FontWeight="Bold"><Run
|
FontWeight="Bold">
|
||||||
Text="WPF NotifyIcon is free software, released under the" /><Run
|
<Run
|
||||||
Text=" " /><Hyperlink
|
Text="WPF NotifyIcon is free software, released under the" />
|
||||||
NavigateUri="http://www.codeproject.com/info/cpol10.aspx"><Run
|
<Run
|
||||||
Text="CodeProject Open License" /></Hyperlink></TextBlock>
|
Text=" " />
|
||||||
|
<Hyperlink
|
||||||
|
NavigateUri="http://www.codeproject.com/info/cpol10.aspx">
|
||||||
|
<Run
|
||||||
|
Text="CodeProject Open License" />
|
||||||
|
</Hyperlink>
|
||||||
|
</TextBlock>
|
||||||
<Path
|
<Path
|
||||||
Fill="#FFFFFFFF"
|
Fill="#FFFFFFFF"
|
||||||
Stretch="Fill"
|
Stretch="Fill"
|
||||||
|
|||||||
@@ -7,6 +7,7 @@ using System.Windows;
|
|||||||
// General Information about an assembly is controlled through the following
|
// General Information about an assembly is controlled through the following
|
||||||
// set of attributes. Change these attribute values to modify the information
|
// set of attributes. Change these attribute values to modify the information
|
||||||
// associated with an assembly.
|
// associated with an assembly.
|
||||||
|
|
||||||
[assembly: AssemblyTitle("Sample Project")]
|
[assembly: AssemblyTitle("Sample Project")]
|
||||||
[assembly: AssemblyDescription("")]
|
[assembly: AssemblyDescription("")]
|
||||||
[assembly: AssemblyConfiguration("")]
|
[assembly: AssemblyConfiguration("")]
|
||||||
@@ -19,6 +20,7 @@ using System.Windows;
|
|||||||
// Setting ComVisible to false makes the types in this assembly not visible
|
// 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
|
// to COM components. If you need to access a type in this assembly from
|
||||||
// COM, set the ComVisible attribute to true on that type.
|
// COM, set the ComVisible attribute to true on that type.
|
||||||
|
|
||||||
[assembly: ComVisible(false)]
|
[assembly: ComVisible(false)]
|
||||||
|
|
||||||
//In order to begin building localizable applications, set
|
//In order to begin building localizable applications, set
|
||||||
@@ -51,5 +53,6 @@ using System.Windows;
|
|||||||
// You can specify all the values or you can default the Build and Revision Numbers
|
// You can specify all the values or you can default the Build and Revision Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
// [assembly: AssemblyVersion("1.0.*")]
|
// [assembly: AssemblyVersion("1.0.*")]
|
||||||
|
|
||||||
[assembly: AssemblyVersion("1.0.0.0")]
|
[assembly: AssemblyVersion("1.0.0.0")]
|
||||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
[assembly: AssemblyFileVersion("1.0.0.0")]
|
||||||
@@ -1,4 +1,5 @@
|
|||||||
<?xml version='1.0' encoding='utf-8'?>
|
<?xml version='1.0' encoding='utf-8'?>
|
||||||
|
|
||||||
<SettingsFile xmlns="uri:settings" CurrentProfile="(Default)">
|
<SettingsFile xmlns="uri:settings" CurrentProfile="(Default)">
|
||||||
<Profiles>
|
<Profiles>
|
||||||
<Profile Name="(Default)" />
|
<Profile Name="(Default)" />
|
||||||
|
|||||||
@@ -115,9 +115,13 @@
|
|||||||
<TextBlock Margin="72,49.2,10,0"
|
<TextBlock Margin="72,49.2,10,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
Foreground="#FFECAD25"
|
Foreground="#FFECAD25"
|
||||||
TextWrapping="Wrap"><Run Text="This is a user control. The animation uses the attached "/><Run FontStyle="Italic"
|
TextWrapping="Wrap">
|
||||||
|
<Run Text="This is a user control. The animation uses the attached " />
|
||||||
|
<Run FontStyle="Italic"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
Text="BalloonShowing "/><Run Text="event."/></TextBlock>
|
Text="BalloonShowing " />
|
||||||
|
<Run Text="event." />
|
||||||
|
</TextBlock>
|
||||||
<Path Fill="#FFFFFFFF"
|
<Path Fill="#FFFFFFFF"
|
||||||
Stretch="Fill"
|
Stretch="Fill"
|
||||||
Margin="72,38.2,34,0"
|
Margin="72,38.2,34,0"
|
||||||
|
|||||||
@@ -48,7 +48,6 @@ namespace Samples
|
|||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|
||||||
public FancyBalloon()
|
public FancyBalloon()
|
||||||
{
|
{
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
|
|||||||
@@ -43,12 +43,9 @@ namespace Samples
|
|||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public FancyToolTip()
|
public FancyToolTip()
|
||||||
{
|
{
|
||||||
this.InitializeComponent();
|
this.InitializeComponent();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -22,7 +22,8 @@
|
|||||||
<Border Background="{DynamicResource MenuBackground}"
|
<Border Background="{DynamicResource MenuBackground}"
|
||||||
BorderBrush="{TemplateBinding BorderBrush}"
|
BorderBrush="{TemplateBinding BorderBrush}"
|
||||||
BorderThickness="{TemplateBinding BorderThickness}">
|
BorderThickness="{TemplateBinding BorderThickness}">
|
||||||
<ScrollViewer Style="{DynamicResource {ComponentResourceKey ResourceId=MenuScrollViewer, TypeInTargetAssembly={x:Type FrameworkElement}}}"
|
<ScrollViewer
|
||||||
|
Style="{DynamicResource {ComponentResourceKey ResourceId=MenuScrollViewer, TypeInTargetAssembly={x:Type FrameworkElement}}}"
|
||||||
Uid="ScrollViewer_9"
|
Uid="ScrollViewer_9"
|
||||||
CanContentScroll="True">
|
CanContentScroll="True">
|
||||||
<ItemsPresenter Margin="{TemplateBinding Padding}"
|
<ItemsPresenter Margin="{TemplateBinding Padding}"
|
||||||
|
|||||||
@@ -53,7 +53,6 @@
|
|||||||
Hyperlink.RequestNavigate="OnNavigationRequest">
|
Hyperlink.RequestNavigate="OnNavigationRequest">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
THE TASKBARICON ELEMENT WAS DECLARED INLINE IN ORDER TO USE DATABINDING
|
THE TASKBARICON ELEMENT WAS DECLARED INLINE IN ORDER TO USE DATABINDING
|
||||||
FOR ITS PROPERTIES. IN A REAL-LIFE APP, YOU'D PROBABLY RATHER DECLARE
|
FOR ITS PROPERTIES. IN A REAL-LIFE APP, YOU'D PROBABLY RATHER DECLARE
|
||||||
@@ -71,8 +70,7 @@
|
|||||||
MenuActivation="{Binding Path=SelectedItem, ElementName=lstMenuTrigger, Mode=Default}"
|
MenuActivation="{Binding Path=SelectedItem, ElementName=lstMenuTrigger, Mode=Default}"
|
||||||
PopupActivation="{Binding Path=SelectedItem, ElementName=lstPopupTrigger, Mode=Default}"
|
PopupActivation="{Binding Path=SelectedItem, ElementName=lstPopupTrigger, Mode=Default}"
|
||||||
DoubleClickCommand="{Commands:ShowSampleWindowCommand}"
|
DoubleClickCommand="{Commands:ShowSampleWindowCommand}"
|
||||||
DoubleClickCommandParameter="{Binding RelativeSource={RelativeSource Self}}"
|
DoubleClickCommandParameter="{Binding RelativeSource={RelativeSource Self}}">
|
||||||
>
|
|
||||||
|
|
||||||
<tb:TaskbarIcon.TrayPopup>
|
<tb:TaskbarIcon.TrayPopup>
|
||||||
<!-- the control will be put into a popup with an explicit DataContext -->
|
<!-- the control will be put into a popup with an explicit DataContext -->
|
||||||
@@ -89,8 +87,6 @@
|
|||||||
</tb:TaskbarIcon>
|
</tb:TaskbarIcon>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- ************************************************************************************* -->
|
<!-- ************************************************************************************* -->
|
||||||
<!-- ************************************************************************************* -->
|
<!-- ************************************************************************************* -->
|
||||||
<!-- EVERYTHING BELOW IS JUST PLUMBING FOR THE SAMPLE -->
|
<!-- EVERYTHING BELOW IS JUST PLUMBING FOR THE SAMPLE -->
|
||||||
@@ -112,7 +108,9 @@
|
|||||||
Margin="125,0,17,133"
|
Margin="125,0,17,133"
|
||||||
x:Name="txtBalloonTitle"
|
x:Name="txtBalloonTitle"
|
||||||
VerticalAlignment="Bottom"
|
VerticalAlignment="Bottom"
|
||||||
Height="23">WPF NotifyIcon</TextBox>
|
Height="23">
|
||||||
|
WPF NotifyIcon
|
||||||
|
</TextBox>
|
||||||
<TextBox
|
<TextBox
|
||||||
Margin="125,0,17,76"
|
Margin="125,0,17,76"
|
||||||
x:Name="txtBalloonText"
|
x:Name="txtBalloonText"
|
||||||
@@ -137,8 +135,10 @@
|
|||||||
VerticalAlignment="Bottom"
|
VerticalAlignment="Bottom"
|
||||||
Width="85"
|
Width="85"
|
||||||
Height="23"
|
Height="23"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
Text="Balloon Title" /></TextBlock>
|
<Run
|
||||||
|
Text="Balloon Title" />
|
||||||
|
</TextBlock>
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Margin="14,0,0,100"
|
Margin="14,0,0,100"
|
||||||
TextWrapping="Wrap"
|
TextWrapping="Wrap"
|
||||||
@@ -146,8 +146,10 @@
|
|||||||
Width="85"
|
Width="85"
|
||||||
Height="23"
|
Height="23"
|
||||||
VerticalAlignment="Bottom"
|
VerticalAlignment="Bottom"
|
||||||
d:LayoutOverrides="VerticalAlignment"><Run
|
d:LayoutOverrides="VerticalAlignment">
|
||||||
Text="Balloon Text" /></TextBlock>
|
<Run
|
||||||
|
Text="Balloon Text" />
|
||||||
|
</TextBlock>
|
||||||
<RadioButton
|
<RadioButton
|
||||||
Margin="14,0,0,32"
|
Margin="14,0,0,32"
|
||||||
VerticalAlignment="Bottom"
|
VerticalAlignment="Bottom"
|
||||||
@@ -177,11 +179,16 @@
|
|||||||
Margin="10,35.96,21,0"
|
Margin="10,35.96,21,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
Height="56.04"
|
Height="56.04"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
Text="Displays default balloon tips as supported by the OS. " /><Run
|
<Run
|
||||||
Text="You can use custom icons under all OS versions" /><Run
|
Text="Displays default balloon tips as supported by the OS. " />
|
||||||
Text=" (not supported by WinForms NotifyIcon)." /><Run
|
<Run
|
||||||
Text="." /></TextBlock>
|
Text="You can use custom icons under all OS versions" />
|
||||||
|
<Run
|
||||||
|
Text=" (not supported by WinForms NotifyIcon)." />
|
||||||
|
<Run
|
||||||
|
Text="." />
|
||||||
|
</TextBlock>
|
||||||
<Button
|
<Button
|
||||||
HorizontalAlignment="Right"
|
HorizontalAlignment="Right"
|
||||||
Margin="0,0,17,12.52"
|
Margin="0,0,17,12.52"
|
||||||
@@ -199,8 +206,10 @@
|
|||||||
Height="Auto"
|
Height="Auto"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
TextDecorations="Underline"
|
TextDecorations="Underline"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
Text="Standard (OS) Balloon Tips" /></TextBlock>
|
<Run
|
||||||
|
Text="Standard (OS) Balloon Tips" />
|
||||||
|
</TextBlock>
|
||||||
</Grid>
|
</Grid>
|
||||||
<Grid
|
<Grid
|
||||||
HorizontalAlignment="Left"
|
HorizontalAlignment="Left"
|
||||||
@@ -224,26 +233,45 @@
|
|||||||
VerticalAlignment="Bottom" />
|
VerticalAlignment="Bottom" />
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Margin="10,31.7,14,137"
|
Margin="10,31.7,14,137"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
Text="If the user clicks on the " /><Run
|
<Run
|
||||||
Text="Notify" /><Run
|
Text="If the user clicks on the " />
|
||||||
Text="Icon, a " /><Run
|
<Run
|
||||||
Text="P" /><Run
|
Text="Notify" />
|
||||||
Text="opup can be opened and displayed" /><Run
|
<Run
|
||||||
Text=" that allows the user to quickly interact with the application" /><Run
|
Text="Icon, a " />
|
||||||
Text=". " /><Run
|
<Run
|
||||||
Text="Unlike custom ToolTips, this works under all OS versions" /><Run
|
Text="P" />
|
||||||
Text=". " /><Run
|
<Run
|
||||||
Text="Which mouse button(s) opens the Popup is " /><Run
|
Text="opup can be opened and displayed" />
|
||||||
Text="determined by the " /><Run
|
<Run
|
||||||
|
Text=" that allows the user to quickly interact with the application" />
|
||||||
|
<Run
|
||||||
|
Text=". " />
|
||||||
|
<Run
|
||||||
|
Text="Unlike custom ToolTips, this works under all OS versions" />
|
||||||
|
<Run
|
||||||
|
Text=". " />
|
||||||
|
<Run
|
||||||
|
Text="Which mouse button(s) opens the Popup is " />
|
||||||
|
<Run
|
||||||
|
Text="determined by the " />
|
||||||
|
<Run
|
||||||
FontStyle="Italic"
|
FontStyle="Italic"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
Text="PopupActivation " /><Run
|
Text="PopupActivation " />
|
||||||
Text="property." /><Run
|
<Run
|
||||||
Text=" If both Popup and ContextMenu are configured for the same mouse buttons, ContextMenu takes precedence." /><LineBreak /><Run
|
Text="property." />
|
||||||
Text="(Note: " /><Run
|
<Run
|
||||||
Text="In case left-clicks are used, popups are displayed with a delay to ensure the user does not double-click." /><Run
|
Text=" If both Popup and ContextMenu are configured for the same mouse buttons, ContextMenu takes precedence." />
|
||||||
Text=")" /></TextBlock>
|
<LineBreak />
|
||||||
|
<Run
|
||||||
|
Text="(Note: " />
|
||||||
|
<Run
|
||||||
|
Text="In case left-clicks are used, popups are displayed with a delay to ensure the user does not double-click." />
|
||||||
|
<Run
|
||||||
|
Text=")" />
|
||||||
|
</TextBlock>
|
||||||
<TextBlock
|
<TextBlock
|
||||||
HorizontalAlignment="Left"
|
HorizontalAlignment="Left"
|
||||||
Margin="10,10,0,0"
|
Margin="10,10,0,0"
|
||||||
@@ -252,8 +280,10 @@
|
|||||||
Height="Auto"
|
Height="Auto"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
TextDecorations="Underline"
|
TextDecorations="Underline"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
Text="Popup Controls" /></TextBlock>
|
<Run
|
||||||
|
Text="Popup Controls" />
|
||||||
|
</TextBlock>
|
||||||
</Grid>
|
</Grid>
|
||||||
<Grid
|
<Grid
|
||||||
Margin="10,278,0,0"
|
Margin="10,278,0,0"
|
||||||
@@ -279,37 +309,61 @@
|
|||||||
Margin="10,0,25,93"
|
Margin="10,0,25,93"
|
||||||
TextWrapping="Wrap"
|
TextWrapping="Wrap"
|
||||||
Height="21"
|
Height="21"
|
||||||
VerticalAlignment="Bottom"><Run
|
VerticalAlignment="Bottom">
|
||||||
Text="ToolTipText" /><Run
|
<Run
|
||||||
Text=" (assigned to property and also used by several bindings)" /><Run
|
Text="ToolTipText" />
|
||||||
Text=":" /></TextBlock>
|
<Run
|
||||||
|
Text=" (assigned to property and also used by several bindings)" />
|
||||||
|
<Run
|
||||||
|
Text=":" />
|
||||||
|
</TextBlock>
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Margin="10,29.88,10,114"
|
Margin="10,29.88,10,114"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
Text="If the user moves the mouse over the " /><Run
|
<Run
|
||||||
Text="Notify" /><Run
|
Text="If the user moves the mouse over the " />
|
||||||
Text="Icon, " /><Run
|
<Run
|
||||||
Text="a ToolTip " /><Run
|
Text="Notify" />
|
||||||
Text="can be displayed. Starting from Windows Vista, we have convenient events to display and hide tooltips." /><Run
|
<Run
|
||||||
Text=" You can assign arbitrary UIElements (e.g. User Controls) to the " /><Run
|
Text="Icon, " />
|
||||||
|
<Run
|
||||||
|
Text="a ToolTip " />
|
||||||
|
<Run
|
||||||
|
Text="can be displayed. Starting from Windows Vista, we have convenient events to display and hide tooltips." />
|
||||||
|
<Run
|
||||||
|
Text=" You can assign arbitrary UIElements (e.g. User Controls) to the " />
|
||||||
|
<Run
|
||||||
FontStyle="Italic"
|
FontStyle="Italic"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
Text="TrayToolTip " /><Run
|
Text="TrayToolTip " />
|
||||||
Text="property." /><LineBreak /><Run
|
<Run
|
||||||
Text="" /><Run
|
Text="property." />
|
||||||
Text="If " /><Run
|
<LineBreak />
|
||||||
|
<Run
|
||||||
|
Text="" />
|
||||||
|
<Run
|
||||||
|
Text="If " />
|
||||||
|
<Run
|
||||||
FontStyle="Italic"
|
FontStyle="Italic"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
Text="TrayToolTip " /><Run
|
Text="TrayToolTip " />
|
||||||
Text="is not set or the app runs under an older OS (e.g. " /><Run
|
<Run
|
||||||
Text="Windows " /><Run
|
Text="is not set or the app runs under an older OS (e.g. " />
|
||||||
Text="xp), the " /><Run
|
<Run
|
||||||
Text="NotifyIcon " /><Run
|
Text="Windows " />
|
||||||
Text="falls back to the " /><Run
|
<Run
|
||||||
|
Text="xp), the " />
|
||||||
|
<Run
|
||||||
|
Text="NotifyIcon " />
|
||||||
|
<Run
|
||||||
|
Text="falls back to the " />
|
||||||
|
<Run
|
||||||
FontStyle="Italic"
|
FontStyle="Italic"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
Text="ToolTipText " /><Run
|
Text="ToolTipText " />
|
||||||
Text="property." /></TextBlock>
|
<Run
|
||||||
|
Text="property." />
|
||||||
|
</TextBlock>
|
||||||
<Button
|
<Button
|
||||||
HorizontalAlignment="Left"
|
HorizontalAlignment="Left"
|
||||||
Margin="10,0,0,10"
|
Margin="10,0,0,10"
|
||||||
@@ -323,8 +377,10 @@
|
|||||||
Margin="10,0,25,44"
|
Margin="10,0,25,44"
|
||||||
VerticalAlignment="Bottom"
|
VerticalAlignment="Bottom"
|
||||||
Height="16"
|
Height="16"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
Text="Click to fall back to ToolTipText (sets TrayToolTip to null):" /></TextBlock>
|
<Run
|
||||||
|
Text="Click to fall back to ToolTipText (sets TrayToolTip to null):" />
|
||||||
|
</TextBlock>
|
||||||
<TextBlock
|
<TextBlock
|
||||||
HorizontalAlignment="Left"
|
HorizontalAlignment="Left"
|
||||||
Margin="10,10,0,0"
|
Margin="10,10,0,0"
|
||||||
@@ -333,8 +389,10 @@
|
|||||||
Height="Auto"
|
Height="Auto"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
TextDecorations="Underline"
|
TextDecorations="Underline"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
Text="ToolTips and ToolTipText" /></TextBlock>
|
<Run
|
||||||
|
Text="ToolTips and ToolTipText" />
|
||||||
|
</TextBlock>
|
||||||
</Grid>
|
</Grid>
|
||||||
<Grid
|
<Grid
|
||||||
HorizontalAlignment="Left"
|
HorizontalAlignment="Left"
|
||||||
@@ -359,24 +417,34 @@
|
|||||||
Margin="10,97,48,0"
|
Margin="10,97,48,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
Height="22"
|
Height="22"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
Text="Mouse events that open the context menu:" /></TextBlock>
|
<Run
|
||||||
|
Text="Mouse events that open the context menu:" />
|
||||||
|
</TextBlock>
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Margin="10,30,10,0"
|
Margin="10,30,10,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
Height="57"
|
Height="57"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
Text="Assign a custon context menu through the " /><Run
|
<Run
|
||||||
|
Text="Assign a custon context menu through the " />
|
||||||
|
<Run
|
||||||
FontStyle="Italic"
|
FontStyle="Italic"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
Text="ContextMenu " /><Run
|
Text="ContextMenu " />
|
||||||
Text="property of the " /><Run
|
<Run
|
||||||
Text="Notify" /><Run
|
Text="property of the " />
|
||||||
Text="Icon. The " /><Run
|
<Run
|
||||||
|
Text="Notify" />
|
||||||
|
<Run
|
||||||
|
Text="Icon. The " />
|
||||||
|
<Run
|
||||||
FontStyle="Italic"
|
FontStyle="Italic"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
Text="MenuActivation " /><Run
|
Text="MenuActivation " />
|
||||||
Text="property determines what mouse events open the context menu." /></TextBlock>
|
<Run
|
||||||
|
Text="property determines what mouse events open the context menu." />
|
||||||
|
</TextBlock>
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Margin="10,10,0,0"
|
Margin="10,10,0,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
@@ -385,8 +453,10 @@
|
|||||||
Width="Auto"
|
Width="Auto"
|
||||||
HorizontalAlignment="Left"
|
HorizontalAlignment="Left"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
TextDecorations="Underline"><Run
|
TextDecorations="Underline">
|
||||||
Text="Context Menu" /></TextBlock>
|
<Run
|
||||||
|
Text="Context Menu" />
|
||||||
|
</TextBlock>
|
||||||
</Grid>
|
</Grid>
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Margin="10,10,0,0"
|
Margin="10,10,0,0"
|
||||||
@@ -395,8 +465,10 @@
|
|||||||
TextWrapping="Wrap"
|
TextWrapping="Wrap"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
FontSize="16"
|
FontSize="16"
|
||||||
HorizontalAlignment="Left"><Run
|
HorizontalAlignment="Left">
|
||||||
Text="WPF NotifyIcon" /></TextBlock>
|
<Run
|
||||||
|
Text="WPF NotifyIcon" />
|
||||||
|
</TextBlock>
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Margin="12,57.62,15.5,0"
|
Margin="12,57.62,15.5,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
@@ -404,15 +476,24 @@
|
|||||||
FontStyle="Italic"
|
FontStyle="Italic"
|
||||||
Foreground="#FF303030"
|
Foreground="#FF303030"
|
||||||
TextWrapping="Wrap"
|
TextWrapping="Wrap"
|
||||||
HorizontalAlignment="Stretch"><Run
|
HorizontalAlignment="Stretch">
|
||||||
Text="This " /><Run
|
<Run
|
||||||
Text="is a showcase of the different features of the WPF NotifyIcon. Have a look at the used controls and styles in order to see how binding can be supported. For a real-life " /><Run
|
Text="This " />
|
||||||
Text="example" /><Run
|
<Run
|
||||||
Text=", " /><Run
|
Text="is a showcase of the different features of the WPF NotifyIcon. Have a look at the used controls and styles in order to see how binding can be supported. For a real-life " />
|
||||||
|
<Run
|
||||||
|
Text="example" />
|
||||||
|
<Run
|
||||||
|
Text=", " />
|
||||||
|
<Run
|
||||||
Language="de-ch"
|
Language="de-ch"
|
||||||
Text="check out " /><Hyperlink
|
Text="check out " />
|
||||||
NavigateUri="http://www.hardcodet.net/netdrives/"><Run
|
<Hyperlink
|
||||||
Text="NetDrives" /></Hyperlink></TextBlock>
|
NavigateUri="http://www.hardcodet.net/netdrives/">
|
||||||
|
<Run
|
||||||
|
Text="NetDrives" />
|
||||||
|
</Hyperlink>
|
||||||
|
</TextBlock>
|
||||||
<Grid
|
<Grid
|
||||||
Margin="486.5,380.38,0,0"
|
Margin="486.5,380.38,0,0"
|
||||||
x:Name="CustomBalloons"
|
x:Name="CustomBalloons"
|
||||||
@@ -446,19 +527,34 @@
|
|||||||
Margin="10,35,24.377,0"
|
Margin="10,35,24.377,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
TextWrapping="Wrap"
|
TextWrapping="Wrap"
|
||||||
Height="119.68"><Run
|
Height="119.68">
|
||||||
Text="Custom " /><Run
|
<Run
|
||||||
Text="Balloons are much " /><Run
|
Text="Custom " />
|
||||||
Text="ore flexible then standard balloons " /><Run
|
<Run
|
||||||
Text="tips " /><Run
|
Text="Balloons are much " />
|
||||||
Text="when it comes to styling." /><Run
|
<Run
|
||||||
Text=" You can display arbitrary UI Elements (e.g. User Controls) as custom balloons." /><LineBreak /><Run
|
Text="ore flexible then standard balloons " />
|
||||||
Text="Apart from the richer UI, custom balloons also provide a" /><Run
|
<Run
|
||||||
Text="ttached properties and events that can be used to control behavior." /><Run
|
Text="tips " />
|
||||||
Text=" Custom balloons also work if the NotifyIcon is not visible." /><LineBreak /><Run
|
<Run
|
||||||
Text="(Hint: Hover over the " /><Run
|
Text="when it comes to styling." />
|
||||||
Text="balloon " /><Run
|
<Run
|
||||||
Text="to suspend the fade-out.)" /></TextBlock>
|
Text=" You can display arbitrary UI Elements (e.g. User Controls) as custom balloons." />
|
||||||
|
<LineBreak />
|
||||||
|
<Run
|
||||||
|
Text="Apart from the richer UI, custom balloons also provide a" />
|
||||||
|
<Run
|
||||||
|
Text="ttached properties and events that can be used to control behavior." />
|
||||||
|
<Run
|
||||||
|
Text=" Custom balloons also work if the NotifyIcon is not visible." />
|
||||||
|
<LineBreak />
|
||||||
|
<Run
|
||||||
|
Text="(Hint: Hover over the " />
|
||||||
|
<Run
|
||||||
|
Text="balloon " />
|
||||||
|
<Run
|
||||||
|
Text="to suspend the fade-out.)" />
|
||||||
|
</TextBlock>
|
||||||
<Button
|
<Button
|
||||||
Content="Close"
|
Content="Close"
|
||||||
x:Name="hideCustomBalloon"
|
x:Name="hideCustomBalloon"
|
||||||
@@ -476,8 +572,10 @@
|
|||||||
Height="Auto"
|
Height="Auto"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
TextDecorations="Underline"
|
TextDecorations="Underline"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
Text="Custom Balloons" /></TextBlock>
|
<Run
|
||||||
|
Text="Custom Balloons" />
|
||||||
|
</TextBlock>
|
||||||
</Grid>
|
</Grid>
|
||||||
<Grid
|
<Grid
|
||||||
Margin="10,114.5,0,0"
|
Margin="10,114.5,0,0"
|
||||||
@@ -525,8 +623,10 @@
|
|||||||
Width="Auto"
|
Width="Auto"
|
||||||
TextWrapping="Wrap"
|
TextWrapping="Wrap"
|
||||||
d:LayoutOverrides="Width"
|
d:LayoutOverrides="Width"
|
||||||
HorizontalAlignment="Left"><Run
|
HorizontalAlignment="Left">
|
||||||
Text="Select an image to switch icons:" /></TextBlock>
|
<Run
|
||||||
|
Text="Select an image to switch icons:" />
|
||||||
|
</TextBlock>
|
||||||
<TextBlock
|
<TextBlock
|
||||||
HorizontalAlignment="Left"
|
HorizontalAlignment="Left"
|
||||||
Margin="10,10,0,0"
|
Margin="10,10,0,0"
|
||||||
@@ -535,8 +635,10 @@
|
|||||||
Height="Auto"
|
Height="Auto"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
TextDecorations="Underline"
|
TextDecorations="Underline"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
Text="Icon / Visibility" /></TextBlock>
|
<Run
|
||||||
|
Text="Icon / Visibility" />
|
||||||
|
</TextBlock>
|
||||||
</Grid>
|
</Grid>
|
||||||
</Grid>
|
</Grid>
|
||||||
</Window>
|
</Window>
|
||||||
@@ -61,7 +61,6 @@ namespace Samples
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
private void showCustomBalloon_Click(object sender, RoutedEventArgs e)
|
private void showCustomBalloon_Click(object sender, RoutedEventArgs e)
|
||||||
{
|
{
|
||||||
FancyBalloon balloon = new FancyBalloon();
|
FancyBalloon balloon = new FancyBalloon();
|
||||||
|
|||||||
@@ -68,26 +68,38 @@
|
|||||||
FontSize="14"
|
FontSize="14"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
TextWrapping="Wrap"
|
TextWrapping="Wrap"
|
||||||
HorizontalAlignment="Center"><Run
|
HorizontalAlignment="Center">
|
||||||
|
<Run
|
||||||
Text="WPF NotifyIcon - Sample Application"
|
Text="WPF NotifyIcon - Sample Application"
|
||||||
Language="de-ch" /></TextBlock>
|
Language="de-ch" />
|
||||||
|
</TextBlock>
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Margin="10,38.62,10,0"
|
Margin="10,38.62,10,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
TextWrapping="Wrap"
|
TextWrapping="Wrap"
|
||||||
HorizontalAlignment="Left"><Run
|
HorizontalAlignment="Left">
|
||||||
Text="You should see this icon in your system tray:" /><Run
|
<Run
|
||||||
Text=" " /><InlineUIContainer>
|
Text="You should see this icon in your system tray:" />
|
||||||
|
<Run
|
||||||
|
Text=" " />
|
||||||
|
<InlineUIContainer>
|
||||||
<Image
|
<Image
|
||||||
Source="{Binding Path=IconSource}"
|
Source="{Binding Path=IconSource}"
|
||||||
Width="16"
|
Width="16"
|
||||||
Height="16" />
|
Height="16" />
|
||||||
</InlineUIContainer><LineBreak /><Run
|
</InlineUIContainer>
|
||||||
Text="This is your NotifyIcon." /><LineBreak /><Run
|
<LineBreak />
|
||||||
Text="" /><LineBreak /><Run
|
<Run
|
||||||
|
Text="This is your NotifyIcon." />
|
||||||
|
<LineBreak />
|
||||||
|
<Run
|
||||||
|
Text="" />
|
||||||
|
<LineBreak />
|
||||||
|
<Run
|
||||||
FontSize="10"
|
FontSize="10"
|
||||||
FontStyle="Italic"
|
FontStyle="Italic"
|
||||||
Text="You can change the displayed icon by selecting another image in the sample window." /></TextBlock>
|
Text="You can change the displayed icon by selecting another image in the sample window." />
|
||||||
|
</TextBlock>
|
||||||
|
|
||||||
</Grid>
|
</Grid>
|
||||||
</UserControl>
|
</UserControl>
|
||||||
@@ -13,7 +13,9 @@
|
|||||||
x:Name="MyNotifyIcon"
|
x:Name="MyNotifyIcon"
|
||||||
IconSource="/Icons/Error.ico"
|
IconSource="/Icons/Error.ico"
|
||||||
ToolTipText="hello world" />
|
ToolTipText="hello world" />
|
||||||
<TextBlock Margin="26,26,24,0" VerticalAlignment="Top" FontWeight="Bold" TextWrapping="Wrap"><Run Text="You should see an icon in the tray." Language="de-ch"/></TextBlock>
|
<TextBlock Margin="26,26,24,0" VerticalAlignment="Top" FontWeight="Bold" TextWrapping="Wrap">
|
||||||
|
<Run Text="You should see an icon in the tray." Language="de-ch" />
|
||||||
|
</TextBlock>
|
||||||
|
|
||||||
</Grid>
|
</Grid>
|
||||||
</Window>
|
</Window>
|
||||||
@@ -28,13 +28,14 @@
|
|||||||
<TextBlock
|
<TextBlock
|
||||||
Text="hello world"
|
Text="hello world"
|
||||||
HorizontalAlignment="Center"
|
HorizontalAlignment="Center"
|
||||||
VerticalAlignment="Center"
|
VerticalAlignment="Center" />
|
||||||
/>
|
|
||||||
</Border>
|
</Border>
|
||||||
</tb:TaskbarIcon.TrayToolTip>
|
</tb:TaskbarIcon.TrayToolTip>
|
||||||
|
|
||||||
</tb:TaskbarIcon>
|
</tb:TaskbarIcon>
|
||||||
<TextBlock Margin="26,26,24,0" VerticalAlignment="Top" FontWeight="Bold" TextWrapping="Wrap"><Run Text="Move mouse over NotifyIcon to show ToolTip" Language="de-ch"/></TextBlock>
|
<TextBlock Margin="26,26,24,0" VerticalAlignment="Top" FontWeight="Bold" TextWrapping="Wrap">
|
||||||
|
<Run Text="Move mouse over NotifyIcon to show ToolTip" Language="de-ch" />
|
||||||
|
</TextBlock>
|
||||||
|
|
||||||
</Grid>
|
</Grid>
|
||||||
</Window>
|
</Window>
|
||||||
@@ -1,8 +1,7 @@
|
|||||||
<UserControl
|
<UserControl
|
||||||
x:Class="Samples.Tutorials.ToolTips.SimpleUserControl"
|
x:Class="Samples.Tutorials.ToolTips.SimpleUserControl"
|
||||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
||||||
>
|
|
||||||
|
|
||||||
<!-- a simple user control which displays a fixed text within a border -->
|
<!-- a simple user control which displays a fixed text within a border -->
|
||||||
<Border
|
<Border
|
||||||
|
|||||||
@@ -19,7 +19,9 @@
|
|||||||
</tb:TaskbarIcon.TrayToolTip>
|
</tb:TaskbarIcon.TrayToolTip>
|
||||||
|
|
||||||
</tb:TaskbarIcon>
|
</tb:TaskbarIcon>
|
||||||
<TextBlock Margin="26,26,24,0" VerticalAlignment="Top" FontWeight="Bold" TextWrapping="Wrap"><Run Text="Move mouse over NotifyIcon to show ToolTip" Language="de-ch"/></TextBlock>
|
<TextBlock Margin="26,26,24,0" VerticalAlignment="Top" FontWeight="Bold" TextWrapping="Wrap">
|
||||||
|
<Run Text="Move mouse over NotifyIcon to show ToolTip" Language="de-ch" />
|
||||||
|
</TextBlock>
|
||||||
|
|
||||||
</Grid>
|
</Grid>
|
||||||
</Window>
|
</Window>
|
||||||
@@ -46,8 +46,10 @@
|
|||||||
<TextBlock Margin="26,26,24,0"
|
<TextBlock Margin="26,26,24,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
TextWrapping="Wrap"><Run Language="de-ch"
|
TextWrapping="Wrap">
|
||||||
Text="Right-click on NotifyIcon to open Context Menu" /></TextBlock>
|
<Run Language="de-ch"
|
||||||
|
Text="Right-click on NotifyIcon to open Context Menu" />
|
||||||
|
</TextBlock>
|
||||||
<TextBlock HorizontalAlignment="Left"
|
<TextBlock HorizontalAlignment="Left"
|
||||||
Margin="26,83,0,0"
|
Margin="26,83,0,0"
|
||||||
TextWrapping="Wrap"
|
TextWrapping="Wrap"
|
||||||
|
|||||||
@@ -16,38 +16,35 @@
|
|||||||
x:Name="btnShowStandardBalloon"
|
x:Name="btnShowStandardBalloon"
|
||||||
Click="btnShowStandardBalloon_Click"
|
Click="btnShowStandardBalloon_Click"
|
||||||
Margin="26,74,29,0"
|
Margin="26,74,29,0"
|
||||||
Content="Show Standard Balloon" Height="29" VerticalAlignment="Top"
|
Content="Show Standard Balloon" Height="29" VerticalAlignment="Top" />
|
||||||
/>
|
|
||||||
<Button
|
<Button
|
||||||
x:Name="btnShowCustomBalloon"
|
x:Name="btnShowCustomBalloon"
|
||||||
Click="btnShowCustomBalloon_Click"
|
Click="btnShowCustomBalloon_Click"
|
||||||
Margin="26,0,29,49"
|
Margin="26,0,29,49"
|
||||||
VerticalAlignment="Bottom"
|
VerticalAlignment="Bottom"
|
||||||
Height="27"
|
Height="27"
|
||||||
Content="Show Custom Balloon"
|
Content="Show Custom Balloon" />
|
||||||
/>
|
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Margin="26,26,24,0"
|
Margin="26,26,24,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
|
<Run
|
||||||
Language="de-ch"
|
Language="de-ch"
|
||||||
Text="Clicking on buttons shows balloon tips" /></TextBlock>
|
Text="Clicking on buttons shows balloon tips" />
|
||||||
|
</TextBlock>
|
||||||
<Button
|
<Button
|
||||||
x:Name="btnHideStandardBalloon"
|
x:Name="btnHideStandardBalloon"
|
||||||
Click="btnHideStandardBalloon_Click"
|
Click="btnHideStandardBalloon_Click"
|
||||||
Margin="26,113,29,122"
|
Margin="26,113,29,122"
|
||||||
Content="Hide Standard Balloon"
|
Content="Hide Standard Balloon" />
|
||||||
/>
|
|
||||||
<Button
|
<Button
|
||||||
x:Name="btnCloseCustomBalloon"
|
x:Name="btnCloseCustomBalloon"
|
||||||
Click="btnCloseCustomBalloon_Click"
|
Click="btnCloseCustomBalloon_Click"
|
||||||
Margin="26,0,29,12"
|
Margin="26,0,29,12"
|
||||||
VerticalAlignment="Bottom"
|
VerticalAlignment="Bottom"
|
||||||
Height="27"
|
Height="27"
|
||||||
Content="Close Custom Balloon"
|
Content="Close Custom Balloon" />
|
||||||
/>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</Grid>
|
</Grid>
|
||||||
|
|||||||
@@ -61,7 +61,5 @@ namespace Samples.Tutorials.Balloons
|
|||||||
{
|
{
|
||||||
MyNotifyIcon.CloseBalloon();
|
MyNotifyIcon.CloseBalloon();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -40,13 +40,19 @@
|
|||||||
Margin="26,26,24,0"
|
Margin="26,26,24,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
|
<Run
|
||||||
Language="de-ch"
|
Language="de-ch"
|
||||||
Text="Left / Double clicks on red NotifyIcon executes simple custom commands." /></TextBlock>
|
Text="Left / Double clicks on red NotifyIcon executes simple custom commands." />
|
||||||
|
</TextBlock>
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Margin="26,112,24,80"
|
Margin="26,112,24,80"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
TextWrapping="Wrap"><Run Language="de-ch" Text="Left / Double clicks on grey NotifyIcon executes routed commands."/><LineBreak/><Run Language="de-ch" Text="Single click: Cuts selected text"/><LineBreak/><Run Language="de-ch" Text="Double click: Paste text from clipboard"/></TextBlock>
|
TextWrapping="Wrap">
|
||||||
|
<Run Language="de-ch" Text="Left / Double clicks on grey NotifyIcon executes routed commands." />
|
||||||
|
<LineBreak /><Run Language="de-ch" Text="Single click: Cuts selected text" /><LineBreak />
|
||||||
|
<Run Language="de-ch" Text="Double click: Paste text from clipboard" />
|
||||||
|
</TextBlock>
|
||||||
<TextBox
|
<TextBox
|
||||||
Margin="26,0,24,48"
|
Margin="26,0,24,48"
|
||||||
VerticalAlignment="Bottom"
|
VerticalAlignment="Bottom"
|
||||||
|
|||||||
@@ -116,8 +116,6 @@
|
|||||||
IconSource="/Icons/Error.ico" />
|
IconSource="/Icons/Error.ico" />
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<Ellipse
|
<Ellipse
|
||||||
HorizontalAlignment="Left"
|
HorizontalAlignment="Left"
|
||||||
Margin="24,62,0,0"
|
Margin="24,62,0,0"
|
||||||
@@ -231,29 +229,37 @@
|
|||||||
Margin="63,62,91,0"
|
Margin="63,62,91,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
Height="19"
|
Height="19"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
|
<Run
|
||||||
Language="de-ch"
|
Language="de-ch"
|
||||||
Text="TrayMouseMove Event" /></TextBlock>
|
Text="TrayMouseMove Event" />
|
||||||
|
</TextBlock>
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Margin="63,106,91,0"
|
Margin="63,106,91,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
Height="19"
|
Height="19"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
|
<Run
|
||||||
Language="de-ch"
|
Language="de-ch"
|
||||||
Text="TrayLeftMouseUp Event" /></TextBlock>
|
Text="TrayLeftMouseUp Event" />
|
||||||
|
</TextBlock>
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Margin="63,0,91,94"
|
Margin="63,0,91,94"
|
||||||
TextWrapping="Wrap"
|
TextWrapping="Wrap"
|
||||||
VerticalAlignment="Bottom"
|
VerticalAlignment="Bottom"
|
||||||
Height="19"><Run
|
Height="19">
|
||||||
|
<Run
|
||||||
Language="de-ch"
|
Language="de-ch"
|
||||||
Text="TrayToolTipOpen Event" /></TextBlock>
|
Text="TrayToolTipOpen Event" />
|
||||||
|
</TextBlock>
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Margin="10,10,10,0"
|
Margin="10,10,10,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
Height="31"
|
Height="31"
|
||||||
TextWrapping="Wrap"
|
TextWrapping="Wrap"
|
||||||
FontWeight="Bold"><Run Language="de-ch" Text="The green ellipses are animated based on routed events of the NotifyIcon"/></TextBlock>
|
FontWeight="Bold">
|
||||||
|
<Run Language="de-ch" Text="The green ellipses are animated based on routed events of the NotifyIcon" />
|
||||||
|
</TextBlock>
|
||||||
|
|
||||||
</Grid>
|
</Grid>
|
||||||
</Window>
|
</Window>
|
||||||
@@ -72,14 +72,16 @@
|
|||||||
</tb:TaskbarIcon>
|
</tb:TaskbarIcon>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Margin="26,26,24,0"
|
Margin="26,26,24,0"
|
||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
TextWrapping="Wrap"
|
TextWrapping="Wrap"
|
||||||
FontWeight="Bold"><Run Text="This sample shows data bound ToolTips in two flavors"/><LineBreak/><Run Text=""/><LineBreak/><Run Text="- implicit binding via DataContext"/><LineBreak/><Run Text="- explicit binding via ParentTaskbarIcon (attached property)"/><LineBreak/><Run Text=""/><LineBreak/><Run Text="Move over NotifyIcons (grey / red) to show data bound ToolTip"/></TextBlock>
|
FontWeight="Bold">
|
||||||
|
<Run Text="This sample shows data bound ToolTips in two flavors" /><LineBreak /><Run Text="" />
|
||||||
|
<LineBreak /><Run Text="- implicit binding via DataContext" /><LineBreak />
|
||||||
|
<Run Text="- explicit binding via ParentTaskbarIcon (attached property)" /><LineBreak /><Run Text="" />
|
||||||
|
<LineBreak /><Run Text="Move over NotifyIcons (grey / red) to show data bound ToolTip" />
|
||||||
|
</TextBlock>
|
||||||
<TextBox
|
<TextBox
|
||||||
Margin="26,0,24,10"
|
Margin="26,0,24,10"
|
||||||
Text="hello world"
|
Text="hello world"
|
||||||
@@ -89,9 +91,11 @@
|
|||||||
Margin="26,0,125,45"
|
Margin="26,0,125,45"
|
||||||
VerticalAlignment="Bottom"
|
VerticalAlignment="Bottom"
|
||||||
Height="26"
|
Height="26"
|
||||||
TextWrapping="Wrap"><Run
|
TextWrapping="Wrap">
|
||||||
|
<Run
|
||||||
|
|
||||||
Text="ToolTipText:" /></TextBlock>
|
Text="ToolTipText:" />
|
||||||
|
</TextBlock>
|
||||||
|
|
||||||
</Grid>
|
</Grid>
|
||||||
</Window>
|
</Window>
|
||||||
@@ -7,7 +7,8 @@
|
|||||||
Width="300" x:Name="me">
|
Width="300" x:Name="me">
|
||||||
<UserControl.Resources>
|
<UserControl.Resources>
|
||||||
<Storyboard x:Key="RotateIcon">
|
<Storyboard x:Key="RotateIcon">
|
||||||
<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="image" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)">
|
<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="image"
|
||||||
|
Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)">
|
||||||
<SplineDoubleKeyFrame KeyTime="00:00:00" Value="0" />
|
<SplineDoubleKeyFrame KeyTime="00:00:00" Value="0" />
|
||||||
<SplineDoubleKeyFrame KeySpline="0,0.284,0.39,1" KeyTime="00:00:01.4000000" Value="360" />
|
<SplineDoubleKeyFrame KeySpline="0,0.284,0.39,1" KeyTime="00:00:01.4000000" Value="360" />
|
||||||
</DoubleAnimationUsingKeyFrames>
|
</DoubleAnimationUsingKeyFrames>
|
||||||
@@ -67,9 +68,11 @@
|
|||||||
VerticalAlignment="Top"
|
VerticalAlignment="Top"
|
||||||
FontSize="16"
|
FontSize="16"
|
||||||
FontWeight="Bold"
|
FontWeight="Bold"
|
||||||
Foreground="#FF575757" HorizontalAlignment="Right"><Run
|
Foreground="#FF575757" HorizontalAlignment="Right">
|
||||||
|
<Run
|
||||||
Text="This is a fancy Popup..."
|
Text="This is a fancy Popup..."
|
||||||
Language="de-ch" /></TextBlock>
|
Language="de-ch" />
|
||||||
|
</TextBlock>
|
||||||
<Button
|
<Button
|
||||||
Click="OnButtonClick"
|
Click="OnButtonClick"
|
||||||
ToolTip="{Binding Path=ToolTipText}"
|
ToolTip="{Binding Path=ToolTipText}"
|
||||||
@@ -104,11 +107,23 @@
|
|||||||
</Button>
|
</Button>
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Margin="19,92,10,49"
|
Margin="19,92,10,49"
|
||||||
TextWrapping="Wrap"><Run Text="This user control makes use of the " Language="de-ch"/><Run FontStyle="Italic" FontWeight="Bold" Text="PopupOpened " Language="de-ch"/><Run Text="attached routed event . Whenever the popup is opened, this attached event fires and triggers the rotation animation." Language="de-ch"/></TextBlock>
|
TextWrapping="Wrap">
|
||||||
<TextBlock Margin="0,52,20,0" VerticalAlignment="Top" Height="Auto" TextWrapping="Wrap" FontWeight="Bold" FontSize="14" HorizontalAlignment="Right" Foreground="#FF575757"><Run Text="Clicks: " Language="de-ch"/><InlineUIContainer>
|
<Run Text="This user control makes use of the " Language="de-ch" />
|
||||||
<TextBlock Width="Auto" Height="Auto" Text="{Binding Path=ClickCount, ElementName=me, Mode=Default}" TextWrapping="Wrap"/>
|
<Run FontStyle="Italic" FontWeight="Bold" Text="PopupOpened " Language="de-ch" />
|
||||||
</InlineUIContainer></TextBlock>
|
<Run
|
||||||
|
Text="attached routed event . Whenever the popup is opened, this attached event fires and triggers the rotation animation."
|
||||||
|
Language="de-ch" />
|
||||||
|
</TextBlock>
|
||||||
|
<TextBlock Margin="0,52,20,0" VerticalAlignment="Top" Height="Auto" TextWrapping="Wrap" FontWeight="Bold"
|
||||||
|
FontSize="14" HorizontalAlignment="Right" Foreground="#FF575757">
|
||||||
|
<Run Text="Clicks: " Language="de-ch" />
|
||||||
|
<InlineUIContainer>
|
||||||
|
<TextBlock Width="Auto" Height="Auto" Text="{Binding Path=ClickCount, ElementName=me, Mode=Default}"
|
||||||
|
TextWrapping="Wrap" />
|
||||||
|
</InlineUIContainer>
|
||||||
|
</TextBlock>
|
||||||
<Image
|
<Image
|
||||||
Source="{Binding Path=IconSource}" Width="16" HorizontalAlignment="Left" Margin="19,0,0,23" Height="16" VerticalAlignment="Bottom" />
|
Source="{Binding Path=IconSource}" Width="16" HorizontalAlignment="Left" Margin="19,0,0,23" Height="16"
|
||||||
|
VerticalAlignment="Bottom" />
|
||||||
</Grid>
|
</Grid>
|
||||||
</UserControl>
|
</UserControl>
|
||||||
@@ -4,13 +4,13 @@ using Samples;
|
|||||||
|
|
||||||
namespace WindowsFormsSample
|
namespace WindowsFormsSample
|
||||||
{
|
{
|
||||||
static class Program
|
internal static class Program
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The main entry point for the application.
|
/// The main entry point for the application.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[STAThread]
|
[STAThread]
|
||||||
static void Main()
|
private static void Main()
|
||||||
{
|
{
|
||||||
Application.EnableVisualStyles();
|
Application.EnableVisualStyles();
|
||||||
Application.SetCompatibleTextRenderingDefault(false);
|
Application.SetCompatibleTextRenderingDefault(false);
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ using System.Runtime.InteropServices;
|
|||||||
// General Information about an assembly is controlled through the following
|
// General Information about an assembly is controlled through the following
|
||||||
// set of attributes. Change these attribute values to modify the information
|
// set of attributes. Change these attribute values to modify the information
|
||||||
// associated with an assembly.
|
// associated with an assembly.
|
||||||
|
|
||||||
[assembly: AssemblyTitle("WindowsFormsSample")]
|
[assembly: AssemblyTitle("WindowsFormsSample")]
|
||||||
[assembly: AssemblyDescription("")]
|
[assembly: AssemblyDescription("")]
|
||||||
[assembly: AssemblyConfiguration("")]
|
[assembly: AssemblyConfiguration("")]
|
||||||
@@ -17,9 +18,11 @@ using System.Runtime.InteropServices;
|
|||||||
// Setting ComVisible to false makes the types in this assembly not visible
|
// 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
|
// to COM components. If you need to access a type in this assembly from
|
||||||
// COM, set the ComVisible attribute to true on that type.
|
// COM, set the ComVisible attribute to true on that type.
|
||||||
|
|
||||||
[assembly: ComVisible(false)]
|
[assembly: ComVisible(false)]
|
||||||
|
|
||||||
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
||||||
|
|
||||||
[assembly: Guid("072bbfa0-9b8b-48df-bf88-3e4806b3e3e8")]
|
[assembly: Guid("072bbfa0-9b8b-48df-bf88-3e4806b3e3e8")]
|
||||||
|
|
||||||
// Version information for an assembly consists of the following four values:
|
// Version information for an assembly consists of the following four values:
|
||||||
@@ -32,5 +35,6 @@ using System.Runtime.InteropServices;
|
|||||||
// You can specify all the values or you can default the Build and Revision Numbers
|
// You can specify all the values or you can default the Build and Revision Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
// [assembly: AssemblyVersion("1.0.*")]
|
// [assembly: AssemblyVersion("1.0.*")]
|
||||||
|
|
||||||
[assembly: AssemblyVersion("1.0.0.0")]
|
[assembly: AssemblyVersion("1.0.0.0")]
|
||||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
[assembly: AssemblyFileVersion("1.0.0.0")]
|
||||||
@@ -1,4 +1,5 @@
|
|||||||
<?xml version='1.0' encoding='utf-8'?>
|
<?xml version='1.0' encoding='utf-8'?>
|
||||||
|
|
||||||
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)">
|
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)">
|
||||||
<Profiles>
|
<Profiles>
|
||||||
<Profile Name="(Default)" />
|
<Profile Name="(Default)" />
|
||||||
|
|||||||
Reference in New Issue
Block a user