Merge branch 'Better_Rounds_Handling' into develop
Conflicts: Vocaluxe/Screens/CScreenNames.cs
This commit is contained in:
commit
45bc144559
12 files changed
+238
-243
No files matched your search
@@ -47,6 +47,15 @@ namespace VocaluxeLib
|
||||
return (int)result;
|
||||
}
|
||||
|
||||
public static T Clamp<T>(this T val, T min, T max) where T : IComparable<T>
|
||||
{
|
||||
if (val.CompareTo(min) < 0)
|
||||
return min;
|
||||
if (val.CompareTo(max) > 0)
|
||||
return max;
|
||||
return val;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Concat strings into one string with ", " as separator.
|
||||
/// </summary>
|
||||
|
||||
Reference in new issue
Block a user