public static void Initialize(NotificatorInitializer initializer) { /*if ( * ( Environment.OSVersion.Version.Major >= 10 || ( Environment.OSVersion.Version.Major == 8 && Environment.OSVersion.Version.Minor == 1 ) ) && * !initializer.ForceLegacy * ) * Notificator = new Win8Notificator ( initializer ); * else*/ Notificator = new LegacyNotificator(initializer); }
public LegacyNotificator(NotificatorInitializer initializer) { this.initializer = initializer; notifyIcon = new NotifyIcon() { Text = initializer.Title, Visible = true, Icon = initializer.Icon, }; notifyIcon.BalloonTipClicked += (sender, e) => { Clicked?.Invoke(this, EventArgs.Empty); }; }