Exemplo n.º 1
0
        private void TapProcessor_Tap(object sender, RoutedEventArgs e)
        {

            if (((GestureEventArgs)e).Data is DemoInfo)
            {
                var demo = (DemoInfo)((GestureEventArgs)e).Data;

                Demo = demo;

                e.Handled = true;
            }

            if(((GestureEventArgs)e).Data.Equals("collapse list") )
            {
                if (DemoList.Visibility.Equals(System.Windows.Visibility.Visible))
                    DemoList.Visibility = System.Windows.Visibility.Collapsed;
                else
                    DemoList.Visibility = System.Windows.Visibility.Visible;

                e.Handled = true;
            }
           
        }
Exemplo n.º 2
0
        private void ShowDemo(DemoInfo demo)
        {
            var type = Type.GetType(demo.ClassName);
            if (type != null)
            {
                CurrentDemoName = demo.Name;
                var myObject = ReflectionHelper.InstanciateType<UIElement>(type);
                DemoContainer.Content = (UIElement)myObject;

                currentDemoUI = (UIElement) DemoContainer.Content;
            }
        }