internal void ApplyController(Controller c) { int cnt = _children.Count; for (int i = 0; i < cnt; ++i) { GObject child = _children[i]; child.HandleControllerChanged(c); } }
internal void ApplyController(Controller c) { _applyingController = c; int cnt = _children.Count; for (int i = 0; i < cnt; ++i) { GObject child = _children[i]; child.HandleControllerChanged(c); } _applyingController = null; c.RunActions(); }
/// <summary> /// Removes a controller from the container. /// </summary> /// <param name="c">Controller object.</param> public void RemoveController(Controller c) { int index = _controllers.IndexOf(c); if (index == -1) { throw new Exception("controller not exists: " + c.name); } c.parent = null; _controllers.RemoveAt(index); int cnt = _children.Count; for (int i = 0; i < cnt; ++i) { GObject child = _children[i]; child.HandleControllerChanged(c); } }