コード例 #1
0
        public Control CreateTour(object item)
        {
            TourControl client = new TourControl((Entities.Tour)item);

            client.Dock = DockStyle.Top;

            return(client);
        }
コード例 #2
0
        private TourControl FindInClients(Entities.Tour tour)
        {
            foreach (UserControl ctrl in this.flpTours.Controls)
            {
                TourControl grpCtrl = ctrl as TourControl;
                if (grpCtrl != null)
                {
                    if (grpCtrl.Tour == tour)
                    {
                        return(grpCtrl);
                    }
                }
            }

            return(null);
        }
コード例 #3
0
        public bool ListContainsTour(UserControl ctrl)
        {
            TourControl tourCtrl = (TourControl)ctrl;

            return(this.Tours.Contains(tourCtrl.Tour));
        }