Exemplo n.º 1
0
        public StackViewLayout(Transform layout, IBackgroundView background)
        {
            _background = background;
            Layout      = layout;

            OnClosed.Where(x => x == _activeView)
            .Subscribe(HideView)
            .AddTo(LifeTime);

            OnBecameHidden.Where(x => x == _activeView)
            .Subscribe(HideView)
            .AddTo(LifeTime);

            OnBecameVisible.Where(x => x != _activeView)
            .Subscribe(ActivateView)
            .AddTo(LifeTime);
        }
        public DefaultViewLayout(Transform layout, IBackgroundView background)
        {
            _background = background;
            Layout      = layout;

            OnClosed.Where(x => x == _activeView).
            Subscribe(HideView).
            AddTo(LifeTime);

            OnHidden.Where(x => x == _activeView).
            Subscribe(HideView).
            AddTo(LifeTime);

            OnShown.Where(x => x != _activeView).
            Subscribe(ActivateView).
            AddTo(LifeTime);
        }