refactor: added class restriction to generic type for event senders
This commit is contained in:
parent
0e5cc8f898
commit
41245c0c1c
@ -206,7 +206,7 @@ public class Event
|
||||
///
|
||||
/// </summary>
|
||||
/// <typeparam name="TSender">Sender type</typeparam>
|
||||
public class Event<TSender>
|
||||
public class Event<TSender> where TSender : class
|
||||
{
|
||||
// We use Ascending order because draw calls are running from last to first
|
||||
private static readonly Comparer<ListenerData> SortByAscendingPriority = Comparer<ListenerData>.Create((x, y) => x.Priority.CompareTo(y.Priority));
|
||||
@ -375,7 +375,7 @@ public class Event<TSender>
|
||||
///
|
||||
/// </summary>
|
||||
/// <typeparam name="TSender">Sender type</typeparam>
|
||||
public class Event<TSender, TArguments>
|
||||
public class Event<TSender, TArguments> where TSender : class
|
||||
{
|
||||
// We use Ascending order because draw calls are running from last to first
|
||||
private static readonly Comparer<ListenerData> SortByAscendingPriority = Comparer<ListenerData>.Create((x, y) => x.Priority.CompareTo(y.Priority));
|
||||
|
Loading…
x
Reference in New Issue
Block a user