本文整理汇总了C#中MediaPortal.Music.Database.Song.ToShortString方法的典型用法代码示例。如果您正苦于以下问题:C# Song.ToShortString方法的具体用法?C# Song.ToShortString怎么用?C# Song.ToShortString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类MediaPortal.Music.Database.Song
的用法示例。
在下文中一共展示了Song.ToShortString方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: AddItemToFacadeControl
private void AddItemToFacadeControl(Song aSong)
{
GUIListItem item = new GUIListItem(aSong.ToShortString());
item.Label = aSong.Artist + " - " + aSong.Title;
string iconThumb = InfoScrobbler.GetSongAlbumImage(aSong);
item.ThumbnailImage = item.IconImage = item.IconImageBig = iconThumb;
item.MusicTag = aSong.ToMusicTag();
facadeRadioPlaylist.Add(item);
}
示例2: pushQueue
/// <summary>
/// Push the given song on the queue.
/// </summary>
/// <param name="song_">The song to be enqueued.</param>
public static void pushQueue(Song song_)
{
string logmessage = "Adding to queue: " + song_.ToShortString();
if (_useDebugLog)
{
Log.Debug("AudioscrobblerBase: {0}", logmessage);
}
// Enqueue the song
lock (queueLock)
{
queue.Add(song_);
}
if (submitThread != null)
{
if (submitThread.IsAlive)
{
try
{
Log.Debug("AudioscrobblerBase: trying to kill submit thread (no longer needed)");
StopSubmitQueueThread();
}
catch (Exception ex)
{
Log.Warn("AudioscrobblerBase: Result of pre-submit thread abort - {0}", ex.Message);
}
}
}
// Try to submit immediately.
StartSubmitQueueThread();
}
示例3: IsSongBelowMinPercentage
private static bool IsSongBelowMinPercentage(Song aSong)
{
try
{
if ((Convert.ToDouble(aSong.LastFMMatch, NumberFormatInfo.InvariantInfo) * 100) < _minimumArtistMatchPercent)
{
return true;
}
else
{
return false;
}
}
catch (Exception ex)
{
Log.Warn("AudioscrobblerUtils: Could not check percentage match for Song: {0} - {1}", aSong.ToShortString(),
ex.Message);
return false;
}
}