Esempio n. 1
0
        private void MainAnimationChanged(AssetPlayerItem oldAnimation, AssetPlayerItem mainAnimation)
        {
            if (oldAnimation != null)
            {
                oldAnimation.Asset.Player.OnFrameChanged -= Player_OnFrameChanged;
            }

            SelectedAnimationFrameCount = mainAnimation.MaxFrames;
            mainAnimation.Asset.Player.OnFrameChanged += Player_OnFrameChanged;
        }
Esempio n. 2
0
        public void RegisterAsset(AssetViewModel asset)
        {
            _assetList.Add(asset);
            PlayerItems.Add(new AssetPlayerItem(asset));

            asset.Player.LoopAnimation = false;
            if (SelectedMainAnimation == null)
            {
                SelectedMainAnimation = PlayerItems.First();
            }

            OnEnableChanged(IsEnabled);
        }