Exemplo n.º 1
0
 public void SetModelComposition(ModelComposition composition)
 {
     CurrentModelComposition?.DestroyAdditionalInstances();
     CurrentModelComposition = composition;
     _saberSet.SetModelComposition(CurrentModelComposition);
     OnModelCompositionSet?.Invoke(CurrentModelComposition);
 }
Exemplo n.º 2
0
 public void SetModelComposition(ModelComposition composition)
 {
     CurrentModelComposition?.DestroyAdditionalInstances();
     CurrentModelComposition = composition;
     _saberSet.SetModelComposition(CurrentModelComposition);
     OnModelCompositionSet?.Invoke(CurrentModelComposition);
     _logger.Info($"Selected Saber: {composition.ListName}");
 }
Exemplo n.º 3
0
        public void SetModelComposition(ModelComposition composition, bool lazyInit = true)
        {
            if (CurrentModelComposition != null)
            {
                CurrentModelComposition.SaveAdditionalData();
                CurrentModelComposition.DestroyAdditionalInstances();
            }

            if (lazyInit && CurrentModelComposition != composition)
            {
                composition?.LazyInit();
            }

            CurrentModelComposition = composition;
            _saberSet.SetModelComposition(CurrentModelComposition);
            OnModelCompositionSet?.Invoke(CurrentModelComposition);
            _logger.Info($"Selected Saber: {composition?.ListName}");
        }