Skip to content
This repository has been archived by the owner on Apr 28, 2024. It is now read-only.

柔軟な型対応を行いたい #21

Open
Asteriskx opened this issue Dec 6, 2018 · 0 comments
Open

柔軟な型対応を行いたい #21

Asteriskx opened this issue Dec 6, 2018 · 0 comments
Labels
enhancement New feature or request

Comments

@Asteriskx
Copy link
Owner

一部採用中...

		/// <summary>
		/// 
		/// </summary>
		/// <param name="track"></param>
		private void _NotifyTrackInfo<T>(T track) where T : SCFavoriteObjects
		{
			var os = Environment.OSVersion;
			this.notifyIcon.Icon = Properties.Resources.icon;

			if (os.Version.Major >= 6 && os.Version.Minor >= 2)
			{
				this.notifyIcon.BalloonTipTitle = $"Claudia NowPlaying\r\n";
				this.notifyIcon.BalloonTipText = $"{track.Title}\r\n{track.User.UserName}";
				Debug.WriteLine("トースト通知が表示されました。");
			}
			else
			{
				this.notifyIcon.BalloonTipTitle = $"Claudia NowPlaying";
				this.notifyIcon.BalloonTipText = $"{track.Title} - {track.User.UserName}\r\n";
				Debug.WriteLine("バルーン通知が表示されました。");
			}

			this.notifyIcon.ShowBalloonTip(3000);
		}
@Asteriskx Asteriskx added the enhancement New feature or request label Dec 6, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant