blob: 8313f7b9d2b3451d11eb00ea2d8714ad958b5769 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
using System;
namespace WK
{
public interface INotification
{
}
public static class NotificationExtensions
{
public static void AddObserver(this INotification _this, string msg, NotificationCenter.NotificatonHandler handler) { NotificationCenter.Instance.AddObserver(_this, msg, handler); }
public static void RemoveObserver(this INotification _this, string msg, NotificationCenter.NotificatonHandler handler) { NotificationCenter.Instance.RemoveObserver(_this, msg, handler); }
public static void PostNotification(this INotification _this, string msg, params object[] p) { NotificationCenter.Instance.PostNotification(_this, msg, p); }
}
}
|