void IUIElementDataWatch.UnregisterWatch(IUIElementDataWatchRequest requested) { DataWatchRequest r = requested as DataWatchRequest; if (r != null) { r.Stop(); } }
protected void OnEnable() { this.presenter = this.BuildPresenters(); this.graphView = this.BuildView(); this.graphView.name = "theView"; this.graphView.persistenceKey = "theView"; this.graphView.presenter = this.presenter; this.graphView.StretchToParentSize(); this.graphView.RegisterCallback <AttachToPanelEvent>(new EventCallback <AttachToPanelEvent>(this.OnEnterPanel), Capture.NoCapture); if (this.dataWatchHandle == null) { this.dataWatchHandle = this.graphView.dataWatch.RegisterWatch(this.m_Presenter, new Action <UnityEngine.Object>(this.OnChanged)); } this.GetRootVisualContainer().Add(this.graphView); }
protected void RemoveWatch() { if (this.handles != null) { IUIElementDataWatchRequest[] array = this.handles; for (int i = 0; i < array.Length; i++) { IUIElementDataWatchRequest iUIElementDataWatchRequest = array[i]; if (iUIElementDataWatchRequest != null) { iUIElementDataWatchRequest.Dispose(); } } this.handles = null; } }
protected void OnEnable() { presenter = BuildPresenters(); graphView = BuildView(); graphView.name = "theView"; graphView.persistenceKey = "theView"; graphView.presenter = presenter; graphView.StretchToParentSize(); graphView.RegisterCallback <AttachToPanelEvent>(OnEnterPanel); if (dataWatchHandle == null) { dataWatchHandle = graphView.dataWatch.RegisterWatch(m_Presenter, OnChanged); } this.GetRootVisualContainer().Add(graphView); }