Ejemplo n.º 1
0
        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);
                }
            }
        }
Ejemplo n.º 2
0
        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);
                }
            }
        }
Ejemplo n.º 3
0
        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);
            }
        }