public void Remove(IPageContainerClient clientPage) { if (DeVesValidator.IsNullState(clientPage)) { return; } lock (this.m_pages) { if (!this.m_pages.ContainsValue(clientPage)) { return; } var _pairs = this.m_pages.Where(p => Equals(p.Value, clientPage)).ToArray(); if (!_pairs.Any()) { return; } foreach (var _pair in _pairs) { this.m_pages.Remove(_pair.Key); } } }
public void Remove(string key) { if (DeVesValidator.IsNullState(key)) { return; } lock (this.m_pages) { if (this.m_pages.ContainsKey(key)) { this.m_pages.Remove(key); } } }
public void SetVisible(string key, object parameter = null) { if (DeVesValidator.IsNullState(key)) { return; } lock (this.m_pages) { if (!this.m_pages.ContainsKey(key)) { return; } if (Equals(this.ViewFrame.Content, this.m_pages[key])) { return; } this.ViewFrame.Content = this.m_pages[key]; this.m_pages[key].PostConstruct(parameter); } }