public StandardModpackFilesReview(StandardModpackItemEntry entry)
        {
            _entry = entry;
            InitializeComponent();
            ConfirmButton.IsEnabled = false;

            ItemName.Content         = _entry.Item.Name + " - " + StandardModpackCreator.GetNiceLevelName(_entry.Level) + " Level";
            FilesReviewLabel.Content = "[Loading]";

            SharedInit();
            LoadFiles();
        }
Ejemplo n.º 2
0
        public StandardModpackSharedItems(IItem item, XivDependencyLevel level)
        {
            _item  = item;
            _level = level;

            InitializeComponent();

            ItemName.Content  = _item.Name + " - " + StandardModpackCreator.GetNiceLevelName(_level) + " Level";
            ItemLevel.Content = "Review Affected Items";

            NextButton.Click += NextButton_Click;
            BackButton.Click += BackButton_Click;

            LoadItems();
        }
        public StandardModpackCreatorItemSelect(StandardModpackCreator window, StandardModpackViewModel vm)
        {
            _vm         = vm;
            _window     = window;
            DataContext = _vm;

            InitializeComponent();
            //< controls:ItemSelectControl x:Name = "ItemSelect" Width = "Auto" MainMenuMode = "False" Margin = "0" Grid.RowSpan = "3" Height = "Auto" />
            if (ItemSelect == null)
            {
                ItemSelect = new ItemSelectControl();
                ItemSelect.DeferLoading        = false;
                ItemSelect.ExpandCharacterMenu = true;
                ItemSelect.MainMenuMode        = false;
                ItemSelect.SetValue(Grid.RowSpanProperty, 3);
                ItemSelect.Width  = Double.NaN;
                ItemSelect.Height = Double.NaN;
            }
            PrimaryGrid.Children.Add(ItemSelect);
            ItemSelect.ItemConfirmed   += ItemSelect_ItemConfirmed;
            CancelButton.Click         += CancelButton_Click;
            FinalReviewButton.Click    += FinalReviewButton_Click;
            ItemSelect.RawItemSelected += ItemSelect_RawItemSelected;

            ItemSelect.LockUiFunction      = _window.LockUi;
            ItemSelect.UnlockUiFunction    = _window.UnlockUi;
            ItemSelect.ExtraSearchFunction = Filter;

            ItemSelect_RawItemSelected(this, ItemSelect.SelectedItem);

            foreach (var entry in vm.Entries)
            {
                var control = new StandardModpackEntryControl(entry);
                control.RemoveEntry += Control_RemoveEntry;
                AddedItemsPanel.Children.Add(control);
            }

            this.Unloaded += StandardModpackCreatorItemSelect_Unloaded;
            UpdateTotalFiles();
        }
Ejemplo n.º 4
0
        private async Task LoadItems()
        {
            var im   = (IItemModel)_item;
            var root = _item.GetRoot();

            List <IItemModel> items;

            if (_level == XivDependencyLevel.Model || _level == XivDependencyLevel.Root)
            {
                items = await im.GetSharedModelItems();
            }
            else
            {
                items = await im.GetSharedMaterialItems();
            }

            foreach (var i in items)
            {
                SharedItemsListBox.Items.Add(i.Name);
            }
            SharedItemsLabel.Content = "Modifications at the " + StandardModpackCreator.GetNiceLevelName(_level) + " level will affect (at least) the following [" + items.Count + "] item(s):";
        }
        public StandardModpackFileSelect(IItem item, XivDependencyLevel level)
        {
            DataContext = this;
            InitializeComponent();
            _item  = item;
            _level = level;


            ItemName.Content  = _item.Name + " - " + StandardModpackCreator.GetNiceLevelName(_level) + " Level";
            ItemLevel.Content = "Select " + StandardModpackCreator.GetNiceLevelName(_level) + " Files";

            FilesListBox.ItemsSource       = Files;
            FilesListBox.DisplayMemberPath = "DisplayName";
            FilesListBox.SelectedValuePath = "File";
            FilesListBox.SelectionMode     = SelectionMode.Multiple;
            NextButton.IsEnabled           = false;

            FilesListBox.SelectionChanged += FilesListBox_SelectionChanged;

            NextButton.Click += NextButton_Click;
            BackButton.Click += BackButton_Click;

            LoadItems();
        }
Ejemplo n.º 6
0
        public StandardModpackEntryControl(StandardModpackItemEntry entry)
        {
            Entry = entry;
            InitializeComponent();

            ItemNameLabel.Content = entry.Item.Name;
            if (entry.Level == xivModdingFramework.Cache.XivDependencyLevel.Root)
            {
                ItemLevelLabel.Content = "Selected All Files - [" + Entry.AllFiles.Count + "] Total File(s)";
            }
            else
            {
                ItemLevelLabel.Content = "Selected [" + Entry.MainFiles.Count + "] " + StandardModpackCreator.GetNiceLevelName(entry.Level) + " File(s) - [" + Entry.AllFiles.Count + "] Total File(s)";
            }

            RemoveButton.Click += RemoveButton_Click;
        }