示例#1
0
        private void ___CalculateStat_FilePath(ptkConfig stat, MovieProfile profile)
        {
            if (profile.FilePath.Length.Equals(0))
            {
                return;
            }

            string strPath = Path.GetDirectoryName(profile.FilePath);

            stat[strPath] = (stat.GetInt(strPath) + 1).ToString();
        }
示例#2
0
        private void ___CalculateStat_General(ptkConfig stat, MovieProfile profile)
        {
            stat[kwTotalMovieProfile] = (stat.GetInt(kwTotalMovieProfile) + 1).ToString();
            if (profile.FilePath.Length > 0)
            {
                stat[kwLocalProfile] = (stat.GetInt(kwLocalProfile) + 1).ToString();
                switch (profile.FileConnect)
                {
                case "Y":
                    stat[kwFileOnLine] = (stat.GetInt(kwFileOnLine) + 1).ToString();
                    break;

                case "N":
                    stat[kwFileOffLine] = (stat.GetInt(kwFileOffLine) + 1).ToString();
                    break;

                case "?":
                    stat[kwFileUnknow] = (stat.GetInt(kwFileUnknow) + 1).ToString();
                    break;
                }
            }
            else
            {
                stat[kwGlobalProfile] = (stat.GetInt(kwGlobalProfile) + 1).ToString();
            }
        }
示例#3
0
        private void ___CalculateStat_Tag(ptkConfig stat, MovieProfile profile)
        {
            if (profile.Tag.Length.Equals(0))
            {
                return;
            }

            string[] arrTag = profile.Tag.Split(new string[] { "," }, StringSplitOptions.RemoveEmptyEntries);
            for (int i = 0; i < arrTag.Length; i++)
            {
                stat[arrTag[i]] = (stat.GetInt(arrTag[i]) + 1).ToString();
            }
        }
示例#4
0
        private void ___CalculateStat_CountPlay(ptkConfig stat, MovieProfile profile)
        {
            string sCount = profile.CountPlay.ToString();

            stat[sCount] = (stat.GetInt(sCount) + 1).ToString();
        }
示例#5
0
        private void ___CalculateStat_Rating(ptkConfig stat, MovieProfile profile)
        {
            string cRating = "+" + profile.Rating.ToString();

            stat[cRating] = (stat.GetInt(cRating) + 1).ToString();
        }
示例#6
0
        private void ___CalculateStat_Type(ptkConfig stat, MovieProfile profile)
        {
            string cType = profile.Type;

            stat[cType] = (stat.GetInt(cType) + 1).ToString();
        }