示例#1
0
        /// <summary>
        /// Click event changing the screen to the user control that was cliked on
        /// </summary>
        /// <param name="sender">needed for click event</param>
        /// <param name="e">needed for click event</param>
        void Soda(Object sender, RoutedEventArgs e)
        {
            var ss = new SailorSodaUC(b, ord, co, sb);

            ss.DataContext = new SailorSoda();
            b.Child        = ss;
            ord.order.Add((IOrderItem)ss.DataContext);
        }
        /// <summary>
        /// Click event changing the screen to the user control that was cliked on
        /// </summary>
        /// <param name="sender">needed for click event</param>
        /// <param name="e">needed for click event</param>
        void Soda(Object sender, RoutedEventArgs e)
        {
            var ss = new SailorSodaUC(b, o, co, sb);

            ss.DataContext = new SailorSoda();
            b.Child        = ss;
            com.Drink      = (Drink)(ss.DataContext);
            o.order.Add(com);
        }