Esempio n. 1
0
        public static void SkinVideoResume(string VideoName)
        {
            int SkinIndex = GetSkinIndex();

            if (SkinIndex != -1)
            {
                for (int i = 0; i < _Skins[SkinIndex].VideoList.Count; i++)
                {
                    SkinElement sk = _Skins[SkinIndex].VideoList[i];
                    if (sk.Name == VideoName)
                    {
                        if (sk.VideoIndex == -1)
                        {
                            sk.VideoIndex = CVideo.VdLoad(GetVideoFilePath(sk.Name));
                            CVideo.VdSetLoop(sk.VideoIndex, true);
                        }
                        CVideo.VdResume(sk.VideoIndex);
                        _Skins[SkinIndex].VideoList[i] = sk;
                        return;
                    }
                }
            }
        }
Esempio n. 2
0
        public static void Play()
        {
            if (_Playing)
            {
                return;
            }

            if (CConfig.BackgroundMusic == EOffOn.TR_CONFIG_ON)
            {
                if (_AllFileNames.Count > 0)
                {
                    if (_CurrentMusicStream != -1)
                    {
                        CSound.Fade(_CurrentMusicStream, 100f, CSettings.BackgroundMusicFadeTime);
                        CSound.Play(_CurrentMusicStream);
                        if (_VideoEnabled && _Video != -1)
                        {
                            CVideo.VdResume(_Video);
                        }
                        _Playing = true;
                    }
                    else
                    {
                        Next();
                    }

                    if (!IsBackgroundFile(_CurrentPlaylistElement))
                    {
                        _CanSing = true;
                    }
                    else
                    {
                        _CanSing = false;
                    }
                }
            }
        }