mirror of
https://github.com/kangyu-california/PersistentWindows.git
synced 2025-05-11 04:55:39 +02:00
support customized pw update icon with file named as pwIconUpdate(.ico, .png)
This commit is contained in:
parent
5ecc8bdf1b
commit
ff53cc352d
1 changed files with 12 additions and 0 deletions
|
@ -317,6 +317,18 @@ namespace PersistentWindows.SystrayShell
|
|||
{
|
||||
BusyIcon = new System.Drawing.Icon(icon_path);
|
||||
}
|
||||
|
||||
icon_path = Path.Combine(iconFolder, "pwIconUpdate.ico");
|
||||
icon_png_path = Path.Combine(iconFolder, "pwIconUpdate.png");
|
||||
if (File.Exists(icon_png_path))
|
||||
{
|
||||
var bitmap = new System.Drawing.Bitmap(icon_png_path);
|
||||
UpdateIcon = System.Drawing.Icon.FromHandle(bitmap.GetHicon());
|
||||
}
|
||||
else if (File.Exists(icon_path))
|
||||
{
|
||||
UpdateIcon = new System.Drawing.Icon(icon_path);
|
||||
}
|
||||
}
|
||||
|
||||
systrayForm = new SystrayForm(check_upgrade);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue