Esempio n. 1
0
        /// <summary>
        /// initializes application view
        /// </summary>
        private void ApplicationInit()
        {
            TabItem item1, item2, item3;

            item1 = new TabItem();
            item2 = new TabItem();
            item3 = new TabItem();

            Frame f1, f2, f3;

            f1 = new Frame();
            f2 = new Frame();
            f3 = new Frame();

            f1.Background = Brushes.LightGray;
            f2.Background = Brushes.LightGray;
            f3.Background = Brushes.LightGray;

            item1.Header = "Slayer tasks";
            item2.Header = "Gold balances";
            item3.Header = "In-game time";

            this.slayerPage = new SlayerPage();
            f1.Content      = slayerPage;

            this.goldBalancePage = new GoldBalancePage();
            f2.Content           = goldBalancePage;

            this.inGameTimePage = new InGameTimePage();
            f3.Content          = inGameTimePage;

            item1.Content = f1;
            item2.Content = f2;
            item3.Content = f3;

            this.Tabs.Items.Add(item1);
            this.Tabs.Items.Add(item2);
            this.Tabs.Items.Add(item3);
        }
 public BalancePlotViewModel()
 {
     this.goldBalancePage = Application.Current.Windows.OfType <MainWindow>().ElementAt(0).GetGoldBalancePage();
     this.SetUpViewModel();
 }