Matt Griffith's .NET Utilities
Distributed under The MIT License
Download code, documentation, and compiled assembly here.
NotifyIcon
NotifyIcon is a component that creates an icon in the System Tray. It also displays balloon ToolTips and provides a way for applications to minimize themselves to the System Tray.
Features:
- Create an icon in the System Tray. Works the same as the System.Windows.Forms.NotifyIcon class in the base class library.
- Show balloon ToolTips. Influenced by Hans Blommes NotifyIconXP VB.NET code and the CSystemTray class at The Code Project . Allows you to create a Windows 2000-style balloon ToolTip for your System Tray icon.
- MinimizeToTray and RestoreFromTray. Based on the CSystemTray class at The Code Project. Allows you to minimize and restore your application to and from the System Tray. It animates the minimize and restore if the user has Animate Windows turned on. Otherwise it minimizes and restores normally.
I plan to add an Animated Icon feature similar to the one found in the CSystemTray class.
PerfTimer
PerfTimer is a class that wraps the Win32 QueryPerformanceCounter and QueryPerformanceFrequency API calls. It is a lightweight C# port of Dean Wyants CPerfTimer class. It is not thread safe though. And it does not overload any operators. But it does make it simple to add high resolution code timing to your .NET application.
Features:
- Allows you to start, stop, pause, and restart a high performance counter.
- The Resolution, ResolutionMilliseconds, and ResolutionMicroseconds methods return the resolution of the high performance timer on the current system.
- The Elapsed, ElapsedMilliseconds, and ElapsedMicroseconds methods return the total time the timer has run. They can be called while the timer is running or after it is stopped.