public MainWindow() { //InitializeComponent(); try { #if (DEBUG) ConsoleManager.Show(); #endif Rect rectangle = new Rect(0, 0, 450, 350); GoHInterface goHInterface = new GoHInterface(true); FailOverWindow failOverWindow = new FailOverWindow(this, goHInterface, rectangle); failOverWindow.Show(); } catch (Exception ex) { string err = ex.ToString(); Console.WriteLine(err); Console.WriteLine(ex.Message); throw; } }
//public KinectWindow() //{ // InitializeComponent(); //} /// <summary> /// Initializes a new instance of the MainWindow class. /// </summary> public KinectWindow(Window window) { #if (DEBUG) ConsoleManager.Show(); #endif // use the window object as the view model in this simple example this.DataContext = this; // initialize the components (controls) of the window this.InitializeComponent(); Rect rectangle = new Rect(0, 0, 450, 350); GoHInterface goHInterface = new GoHInterface(true); this.m_kinectTools = new KinectTools(goHInterface); this.m_kinectTools.PropertyChanged += KinectTools_PropertyChanged; this.m_kinectTools.Init_01(); this.m_kinectTools.Refresh += KinectTools_Refresh; this.m_failOverWindow = new FailOverWindow(this, goHInterface, rectangle); window.Hide(); }