コード例 #1
0
    public bool RemoveChangeListener(ChangeCallback callback, object userData)
    {
        ChangeListener item = new ChangeListener();

        item.SetCallback(callback);
        item.SetUserData(userData);
        return(this.m_changeListeners.Remove(item));
    }
コード例 #2
0
    public bool AddChangeListener(ChangeCallback callback, object userData)
    {
        ChangeListener item = new ChangeListener();

        item.SetCallback(callback);
        item.SetUserData(userData);
        if (this.m_changeListeners.Contains(item))
        {
            return(false);
        }
        this.m_changeListeners.Add(item);
        return(true);
    }