public void ShowWindow() { ParseWindow window = (ParseWindow)GetWindow(typeof(ParseWindow)); //Creates Window; GUIContent titleContent = new GUIContent(); titleContent.text = Path.GetFileName(xmlFilePath); window.titleContent = titleContent; window.Show(); }
private static void DisplayParseWindow() { if (ParseWindow == null) { ParseWindow = (ParseWindow)CreateInstance("ParseWindow"); } try { ParseWindow.setFilePath(currentXMLFilePath); ParseWindow.LoadFile(); ParseWindow.ParseFile(); ParseWindow.ShowWindow(); } catch (FileNotFoundException) { Debug.LogError("No XML file found at filepath " + currentXMLFilePath); } }
private static void DisplayParseWindow() { if (ParseWindow == null) { ParseWindow = (ParseWindow)CreateInstance("ParseWindow"); } try { ParseWindow.setFilePath(currentXMLFilePath); ParseWindow.LoadFile(); ParseWindow.ParseFile(); ParseWindow.ShowWindow(); } catch (FileNotFoundException) { Debug.LogError("No XML file found at filepath " + currentXMLFilePath); } }
public void setParseWindow(ParseWindow window) { //Preserve changes by setting all the global values of this ParseWindow //to the parameter ParseWindow's global values this.kinectsNames = window.kinectsNames; this.kinectsIP = window.kinectsIP; this.projectorsNames = window.projectorsNames; this.projectorsIP = window.projectorsIP; this.projectorsDisplay = window.projectorsDisplay; this.originalKinectsNames = window.originalKinectsNames; this.originalKinectsIP = window.originalKinectsIP; this.originalProjectorsNames = window.originalProjectorsIP; this.originalProjectorsIP = window.originalProjectorsIP; this.originalProjectorsDisplay = window.originalProjectorsDisplay; this.newKinectsName = window.newKinectsName; this.newKinectsIP = window.newKinectsIP; this.newProjectorsName = window.newProjectorsName; this.newProjectorsIP = window.newProjectorsIP; this.newProjectorsDisplay = window.newProjectorsDisplay; this.changes = window.changes; this.addingKinect = window.addingKinect; this.addingProjector = window.addingProjector; this.removingKinect = window.removingKinect; this.removingProjector = window.removingProjector; this.showCameras = window.showCameras; this.showEachCamera = window.showEachCamera; this.showProjectors = window.showProjectors; this.showEachProjector = window.showEachProjector; this.kinectNum = window.kinectNum; this.projectorNum = window.projectorNum; }
void OnDestroy() { //When the user tries to close the ParseWindow if (changes) { int popup = EditorUtility.DisplayDialogComplex("Save Changes?", "You have made unfinished changes to the XML file. Would you like to save your changes?", "Yes", "No", "Cancel"); if (popup == 0) //if the user selects "Yes" { SaveChanges(); } //if the user selects "No", proceed to close the window without any further action else if (popup == 2) //if the user selects "Cancel" { //Create an identical ParseWindow that will remain after this ParseWindow closes //allowing all changes to be preserved ParseWindow newWindow = (ParseWindow)ScriptableObject.CreateInstance("ParseWindow"); newWindow.setFilePath(xmlFilePath); newWindow.setCurrentDoc(doc); newWindow.setParseWindow(this); newWindow.ShowWindow(); } } }
public void setParseWindow(ParseWindow window) { //Preserve changes by setting all the global values of this ParseWindow //to the parameter ParseWindow's global values this.kinectsNames = window.kinectsNames; this.kinectsIP = window.kinectsIP; this.projectorsNames = window.projectorsNames; this.projectorsIP = window.projectorsIP; this.projectorsDisplay = window.projectorsDisplay; this.originalKinectsNames = window.originalKinectsNames; this.originalKinectsIP = window.originalKinectsIP; this.originalProjectorsNames = window.originalProjectorsIP; this.originalProjectorsIP = window.originalProjectorsIP; this.originalProjectorsDisplay = window.originalProjectorsDisplay; this.newKinectsName = window.newKinectsName; this.newKinectsIP = window.newKinectsIP; this.newProjectorsName = window.newProjectorsName; this.newProjectorsIP = window.newProjectorsIP; this.newProjectorsDisplay = window.newProjectorsDisplay; this.changes = window.changes; this.addingKinect = window.addingKinect; this.addingProjector = window.addingProjector; this.removingKinect = window.removingKinect; this.removingProjector = window.removingProjector; this.showCameras = window.showCameras; this.showEachCamera = window.showEachCamera; this.showProjectors = window.showProjectors; this.showEachProjector = window.showEachProjector; this.kinectNum = window.kinectNum; this.projectorNum = window.projectorNum; }