This repository has been archived by the owner on May 3, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
fbac62d
commit 0211a81
Showing
7 changed files
with
51 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
using System; | ||
|
||
namespace TeamCord.Core | ||
{ | ||
public class UpdateNotification : NotificationBase | ||
{ | ||
/// <summary> | ||
/// Create a update notification. Only pass the version as message. | ||
/// </summary> | ||
/// <param name="message"></param> | ||
/// <param name="title"></param> | ||
public UpdateNotification(string message, string title = "Update") : base(message, title) | ||
{ | ||
Message = $"There is a new version of TeamCord available: {message}"; | ||
Title = title; | ||
} | ||
|
||
/// <summary> | ||
/// Display a notification on the tray icon with a given callback which should be called when balloon tip is clicked | ||
/// </summary> | ||
/// <param name="balloonClickAction"></param> | ||
public void Notify(Action balloonClickAction) | ||
{ | ||
BalloonClick = balloonClickAction; | ||
base.Notify(); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters