//used to pass controls between scenes public LoadControls GetLoadControls() { // UnityEngine.Debug.Log("get load controls!"); LoadControls controls = new LoadControls(); controls.firstPlayerControls = firstPlayerControls; controls.firstPlayerInputDevice = firstPlayerInputDevice; controls.secondPlayerControls = secondPlayerControls; controls.secondPlayerInputDevice = secondPlayerInputDevice; return(controls); }
internal static void Start() { IsRunning = true; if (UC.GetColorPicker == null || !ConfigureWindows.GetMainWindow.topLayer.Children.Contains(UC.GetColorPicker)) { LoadControls.LoadColorPicker(); } // Set cursor for coloc picking ConfigureWindows.GetMainWindow.Cursor = Cursors.Pen; }
//used to pass controls between scenes public void SetLoadControls(LoadControls cont) { if (cont.firstPlayerInputDevice == null || cont.firstPlayerControls == null) { return; } RegisterController(cont.firstPlayerInputDevice, cont.firstPlayerControls); //wierd repeating bug...this catches it but probably doesn't solve the actual problem if (cont.firstPlayerInputDevice == cont.secondPlayerInputDevice) { return; } if (cont.secondPlayerInputDevice == null || cont.secondPlayerControls == null) { return; } RegisterController(cont.secondPlayerInputDevice, cont.secondPlayerControls); }
internal static void StartCrop() { if (ConfigureWindows.GetMainWindow.MainImage.Source == null) { return; } if (GetCropppingTool == null) { LoadControls.LoadCroppingTool(); } GetCropppingTool.Width = Rotateint == 0 || Rotateint == 180 ? xWidth : xHeight; GetCropppingTool.Height = Rotateint == 0 || Rotateint == 180 ? xHeight : xWidth; ConfigureWindows.GetMainWindow.TitleText.Text = Application.Current.Resources["CropMessage"] as string; if (!ConfigureWindows.GetMainWindow.ParentContainer.Children.Contains(GetCropppingTool)) { ConfigureWindows.GetMainWindow.ParentContainer.Children.Add(GetCropppingTool); } CanNavigate = false; }