Esempio n. 1
0
        /// <summary>
        /// 刷新列表
        /// </summary>
        private void RefreshList()
        {
            MoviesList.Nodes.Clear();//清空防止重复添加
            MovieList list = new MovieList();

            list.GetList();
            for (int i = 0; i < list.List.Count; i++)
            {
                MoviesList.Nodes.Add(list.List[i].Moviename);
                for (int j = 0; j < list.List[i].ActionTime.Count; j++)
                {
                    MoviesList.Nodes[i].Nodes.Add(list.List[i].ActionTime[j]);
                }
            }
        }
Esempio n. 2
0
        private bool GetMovieInfo(string MovieName)
        {
            MovieList list = new MovieList();

            list.GetList();
            bool Found = false;

            for (int i = 0; i < list.List.Count; i++)
            {
                if (list.List[i].Moviename == MovieName)
                {
                    movienode = list.List[i];
                    Found     = true;
                    break;
                }
            }

            if (Found == false)
            {
                return(Found);
            }

            SelectMovieName.Text = movienode.Moviename;
            SelectActor.Text     = movienode.MainActor;
            SelectDirector.Text  = movienode.Director;
            SelectType.Text      = movienode.MovieType;
            SelectPrice.Text     = Convert.ToString(movienode.Price);
            if (movienode.ImagePath != "NULL")
            {
                MoviePic.ImageLocation = movienode.ImagePath;
            }
            else
            {
                MoviePic.Image = null;
            }

            return(Found);
        }