Exemple #1
0
 public TrayApplication(TrayIcon trayIcon)
 {
     TrayIcon             = trayIcon ?? throw new ArgumentNullException(nameof(trayIcon));
     TrayIcon.Application = this;
     TrayIcon.Disposed   += (sender, args) => {
         this.Exit();
     };
 }
Exemple #2
0
 public static void Run(TrayIcon trayIcon)
 {
     new TrayApplication(trayIcon).Start();
 }