Esempio n. 1
0
        private void CreateComponentsListBox()
        {
            var listView = CreateListView();

            ViewModels = new List <ComponentViewModel>();

            foreach (var component in ComponentStorage.GetInstallableComponents())
            {
                var viewModel = new ComponentViewModel();
                viewModel.IsSelected  = true;
                viewModel.BackingData = component;
                ViewModels.Add(viewModel);
            }

            listView.ItemsSource         = ViewModels;
            listView.HorizontalAlignment = HorizontalAlignment.Stretch;
            listView.VerticalAlignment   = VerticalAlignment.Stretch;
            base.RightPanel.Children.Add(listView);
        }
        private void CreateComponentsListBox()
        {
            var listView = CreateListView();

            ViewModels = new List<ComponentViewModel>();

            foreach (var component in ComponentStorage.GetInstallableComponents())
            {
                var viewModel = new ComponentViewModel();
                viewModel.IsSelected = true;
                viewModel.BackingData = component;
                ViewModels.Add(viewModel);
            }

            listView.ItemsSource = ViewModels;
            listView.HorizontalAlignment = HorizontalAlignment.Stretch;
            listView.VerticalAlignment = VerticalAlignment.Stretch;
            base.RightPanel.Children.Add(listView);

        }