예제 #1
0
        private void Initialize(List <ConditionAffix> conditions, List <Affix> affixes, AffixType affixType, PoeCrafting.Entities.ItemBase itemBase, StatValueType valueType)
        {
            var firstCondition  = conditions.Count >= 1 ? conditions[0] : new ConditionAffix();
            var secondCondition = conditions.Count >= 2 ? conditions[1] : new ConditionAffix();
            var thirdCondition  = conditions.Count >= 3 ? conditions[2] : new ConditionAffix();

            FirstAffixModel  = new SubconditionAffixControlViewModel(firstCondition, affixes, valueType, affixType, itemBase);
            SecondAffixModel = new SubconditionAffixControlViewModel(secondCondition, affixes, valueType, affixType, itemBase);
            ThirdAffixModel  = new SubconditionAffixControlViewModel(thirdCondition, affixes, valueType, affixType, itemBase);

            FirstAffix  = new SubconditionAffixControlView(FirstAffixModel);
            SecondAffix = new SubconditionAffixControlView(SecondAffixModel);
            ThirdAffix  = new SubconditionAffixControlView(ThirdAffixModel);
        }
예제 #2
0
 public SubconditionAffixControlView(SubconditionAffixControlViewModel viewModel)
 {
     ViewModel = viewModel;
     InitializeComponent();
 }