mirror of
https://github.com/2dust/v2rayN.git
synced 2025-04-19 21:52:25 +00:00
RefreshTaryIcon while DisplaySettingsChanged
This commit is contained in:
parent
0c26662602
commit
61a1624996
1 changed files with 12 additions and 1 deletions
|
@ -54,6 +54,8 @@ namespace v2rayN.Forms
|
|||
{
|
||||
statistics = new StatisticsHandler(config, UpdateStatisticsHandler);
|
||||
}
|
||||
|
||||
Microsoft.Win32.SystemEvents.DisplaySettingsChanged += new EventHandler(SystemEvents_DisplaySettingsChanged);
|
||||
}
|
||||
|
||||
private void MainForm_VisibleChanged(object sender, EventArgs e)
|
||||
|
@ -341,6 +343,10 @@ namespace v2rayN.Forms
|
|||
//qrCodeControl.showQRCode(index, config);
|
||||
}
|
||||
|
||||
private void RefreshTaryIcon()
|
||||
{
|
||||
notifyMain.Icon = MainFormHandler.Instance.GetNotifyIcon(config, this.Icon);
|
||||
}
|
||||
private void DisplayToolStatus()
|
||||
{
|
||||
toolSslSocksPort.Text =
|
||||
|
@ -367,7 +373,7 @@ namespace v2rayN.Forms
|
|||
}
|
||||
}
|
||||
|
||||
notifyMain.Icon = MainFormHandler.Instance.GetNotifyIcon(config, this.Icon);
|
||||
RefreshTaryIcon();
|
||||
}
|
||||
private void ssMain_ItemClicked(object sender, ToolStripItemClickedEventArgs e)
|
||||
{
|
||||
|
@ -1563,7 +1569,12 @@ namespace v2rayN.Forms
|
|||
}
|
||||
|
||||
|
||||
|
||||
#endregion
|
||||
private void SystemEvents_DisplaySettingsChanged(object sender, EventArgs e)
|
||||
{
|
||||
RefreshTaryIcon();
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue