Exemple #1
0
        public TriPage(Facts.Page p, Facts.Section s) : base(p)
        {
            articlesGrid = new ArticlesGrid()
            {
                //Margin = new System.Windows.Thickness(5)
            };
            articlesGrid.CreateRow();
            articlesGrid.CreateRow();
            articlesGrid.CreateRow();
            articlesCount = 0;

            base.Embedded = articlesGrid;


            // Note: the follwing is for debugging purpose only,
            // as no content from a disabled page should
            // ever be displayed !
            if (!p.Enabled)
            {
                Background = Brushes.Gray;
            }
        }
Exemple #2
0
        public SpacerPage(Facts.Page p, Facts.Section s) : base(new GetFactsHeader())
        {
            articlesGrid = new Grid()
            {
                Margin = new System.Windows.Thickness(5)
            };

            articlesGrid.RowDefinitions.Add(new RowDefinition()
            {
                Height = new System.Windows.GridLength(1, System.Windows.GridUnitType.Star)
            });

            articlesGrid.RowDefinitions.Add(new RowDefinition()
            {
                Height = new System.Windows.GridLength(2, System.Windows.GridUnitType.Star)
            });

            _pageDisplay = new ArticleDisplay(false, 0);
            _pageDisplay.Update(p);
            articlesGrid.Children.Add(_pageDisplay);
            Grid.SetRow(_pageDisplay, 0);

            _sectionDisplay = new ArticleDisplay(false, 0);
            _sectionDisplay.Update(s);
            articlesGrid.Children.Add(_sectionDisplay);
            Grid.SetRow(_sectionDisplay, 1);

            base.Embedded = articlesGrid;
            Initialized  += SpacerPage_Initialized;
            Loaded       += SpacerPage_Loaded;

            // Note: the follwing is for debugging purpose only,
            // as no content from a disabled page should
            // ever be displayed !
            if (!p.Enabled)
            {
                Background = Brushes.Gray;
            }
        }