private void ViewPerformance_MouseDoubleClick(object sender, MouseButtonEventArgs e)
        {
            ListViewItem item        = sender as ListViewItem;
            object       obj         = item.Content;
            Performance  performance = ((Tour)obj).Performance;

            UserControl usc = new UserControlPerformances(performance);

            this.Content = usc;
        }
        private static UserControl GetUserControlByName(string name)
        {
            UserControl resControl;

            switch (name)
            {
            case "ItemFirstPage":
                resControl = new UserControlFirstPage();
                break;

            case "ItemPerformances":
                resControl = new UserControlPerformances();
                break;

            case "ItemPrices":
                resControl = new UserControlPrices();
                break;

            case "ItemTour":
                resControl = new UserControlTour();
                break;

            case "ItemBasket":
                resControl = new UserControlBasket();
                break;

            case "ItemSubscribers":
                resControl = new UserControlSubscribers();
                break;

            case "ItemAboutUs":
                resControl = new UserControlAboutUs();
                break;

            case "ItemContact":
                resControl = new UserControlContact();
                break;

            case "ItemStars":
                resControl = new UserControlStars();
                break;

            default:
                resControl = new UserControlFirstPage();
                break;
            }
            return(resControl);
        }
Beispiel #3
0
        private void PerformancesGrid_Click(object sender, MouseButtonEventArgs e)
        {
            UserControl usc = new UserControlPerformances();

            this.Content = usc;
        }