public MovementDialog(MusclePositionController musclePositionController, PoseController poseController, MedicalController medicalController) : base("Medical.Movement.GUI.MovementDialog.layout") { this.medicalController = medicalController; this.musclePositionController = musclePositionController; this.poseController = poseController; poseController.PoseModeActivated += poseController_PoseModeActivated; poseController.PoseModeDeactivated += poseController_PoseModeDeactivated; musclePositionController.OnUndoRedoChanged += musclePositionController_UndoRedoStateAltered; musclePositionController.OnRedo += musclePositionController_UndoRedoStateAltered; musclePositionController.OnUndo += musclePositionController_UndoRedoStateAltered; controlButtonPanel = window.findWidget("ControlButtonPanel"); foreach (Widget widget in controlButtonPanel.Children) { Button button = widget as Button; if (button != null) { button.MouseButtonClick += widget_MouseButtonClick; } } undoButton = window.findWidget("Undo") as Button; undoButton.MouseButtonClick += undoButton_MouseButtonClick; redoButton = window.findWidget("Redo") as Button; redoButton.MouseButtonClick += redoButton_MouseButtonClick; Button resetButton = (Button)window.findWidget("Reset"); resetButton.MouseButtonClick += resetButton_MouseButtonClick; musclePositionController_UndoRedoStateAltered(musclePositionController); }
public DebugVisualizer(StandaloneController standaloneController) : base("Developer.GUI.DebugVisualizer.DebugVisualizer.layout") { this.medicalController = standaloneController.MedicalController; this.pluginManager = medicalController.PluginManager; standaloneController.SceneLoaded += standaloneController_SceneLoaded; standaloneController.SceneUnloading += standaloneController_SceneUnloading; uiCallback = new GuiFrameworkUICallback(); tree = new Tree((ScrollView)window.findWidget("TreeScroller")); editTreeView = new EditInterfaceTreeView(tree, uiCallback); propertiesForm = new ScrollablePropertiesForm((ScrollView)window.findWidget("TableScroller"), uiCallback); objectEditor = new ObjectEditor(editTreeView, propertiesForm, uiCallback); this.Resized += DebugVisualizer_Resized; currentScene = standaloneController.MedicalController.CurrentScene; splitter = new Splitter(window.findWidget("Splitter")); splitter.Widget1Resized += a => tree.layout(); splitter.Widget2Resized += a => propertiesForm.layout(); }
public MovementSequenceRecorder(MedicalController medicalController, MovementSequenceController movementSequenceController) : base("KinectPlugin.GUI.MovementSequenceRecorder.layout") { this.medicalController = medicalController; this.movementSequenceController = movementSequenceController; record = new CheckButton((Button)window.findWidget("Record")); record.CheckedChanged += record_CheckedChanged; play = new CheckButton((Button)window.findWidget("Play")); play.CheckedChanged += play_CheckedChanged; play.Enabled = false; save = (Button)window.findWidget("Save"); save.MouseButtonClick += save_MouseButtonClick; save.Enabled = false; clear = (Button)window.findWidget("Clear"); clear.MouseButtonClick += clear_MouseButtonClick; clear.Enabled = false; captureRate = new SingleNumericEdit((EditBox)window.findWidget("CaptureRate")); captureRate.MinValue = 1.0f; captureRate.MaxValue = 60.0f; captureRate.Value = 15.0f; }
public void initialize(StandaloneController standaloneController) { GUIManager guiManager = standaloneController.GUIManager; editorTimelineController = new TimelineController(standaloneController); standaloneController.giveGUIsToTimelineController(editorTimelineController); editorController = new EditorController(standaloneController, editorTimelineController); editorController.ProjectTypes.addInfo(new ZipProjectType(".sl")); standaloneController.DocumentController.addDocumentHandler(new SlideshowDocumentHandler(editorController)); //Prop Mover MedicalController medicalController = standaloneController.MedicalController; propMover = new SimObjectMover("LectureProps", medicalController.PluginManager.RendererPlugin, medicalController.EventManager, standaloneController.SceneViewController); propEditController = new PropEditController(propMover); editorUICallback = new LectureUICallback(standaloneController, editorController, propEditController); slideshowEditController = new SlideshowEditController(standaloneController, editorUICallback, this.propEditController, editorController, editorTimelineController); slideshowExplorer = new SlideshowExplorer(slideshowEditController); guiManager.addManagedDialog(slideshowExplorer); TaskController taskController = standaloneController.TaskController; taskController.addTask(new MDIDialogOpenTask(slideshowExplorer, "Medical.SlideshowExplorer", "Authoring Tools", "Lecture.Icon.SmartLectureIcon", TaskMenuCategories.Create)); CommonEditorResources.initialize(standaloneController); standaloneController.ViewHostFactory.addFactory(new SlideTaskbarFactory()); standaloneController.MedicalStateController.StateAdded += MedicalStateController_StateAdded; standaloneController.MedicalStateController.BlendingStopped += MedicalStateController_BlendingStopped; }
public KinectIkController(StandaloneController controller) { this.medicalController = controller.MedicalController; dragSimObjectDefinition = new GenericSimObjectDefinition("TestArrow"); dragControl = new BEPUikDragControlDefinition("DragControl"); dragSimObjectDefinition.addElement(dragControl); //filter.Init(0.5f, 0.5f, 0.0f, 0.1f, 0.04f); //filter.Init(1.0f, 0.0f, 0.0f, 0.1f, 0.04f); }
public OffsetSequenceEditor(SaveableClipboard clipboard, MyGUIViewHost viewHost, OffsetSequenceEditorView view, MedicalController medicalController) : base("Medical.GUI.OffsetSequence.OffsetSequenceEditor.layout", viewHost) { this.clipboard = clipboard; this.medicalController = medicalController; this.simObjectMover = view.SimObjectMover; widget.KeyButtonReleased += new MyGUIEvent(window_KeyButtonReleased); widget.RootKeyChangeFocus += new MyGUIEvent(widget_RootKeyChangeFocus); //Remove button Button removeButton = widget.findWidget("RemoveAction") as Button; removeButton.MouseButtonClick += new MyGUIEvent(removeButton_MouseButtonClick); //Timeline view ScrollView timelineViewScrollView = widget.findWidget("ActionView") as ScrollView; timelineView = new TimelineView(timelineViewScrollView); timelineView.Duration = Duration; timelineView.KeyReleased += new EventHandler <KeyEventArgs>(timelineView_KeyReleased); timelineView.ActiveDataChanged += timelineView_ActiveDataChanged; //Properties ScrollView timelinePropertiesScrollView = widget.findWidget("ActionPropertiesScrollView") as ScrollView; actionProperties = new TimelineDataProperties(timelinePropertiesScrollView, timelineView); actionProperties.Visible = false; actionProperties.addPanel("Offset Position", new OffsetKeyframeProperties(timelinePropertiesScrollView, this, view.UICallback)); //Timeline filter ScrollView timelineFilterScrollView = widget.findWidget("ActionFilter") as ScrollView; trackFilter = new TrackFilter(timelineFilterScrollView, timelineView); trackFilter.AddTrackItem += new AddTrackItemCallback(trackFilter_AddTrackItem); numberLine = new NumberLine(widget.findWidget("NumberLine") as ScrollView, timelineView); //Add tracks to timeline. timelineView.addTrack("Offset Position"); ViewHost.Context.getModel <EditMenuManager>(EditMenuManager.DefaultName).setMenuProvider(this); Button chooseTargetButton = (Button)widget.findWidget("ChooseTargetButton"); chooseTargetButton.MouseButtonClick += chooseTargetButton_MouseButtonClick; targetLabel = (TextBox)widget.findWidget("TargetLabel"); targetLabel.Caption = DefaultTargetLabelText; CurrentSequence = view.Sequence; }
public static void ShowDialog(MedicalController medicalController, String soundFile, Func <String, Stream> streamProvider, Action <String> soundUpdatedCallback) { QuickSoundRecorder recorder = new QuickSoundRecorder(medicalController, soundFile, streamProvider); recorder.SoundUpdated += soundUpdatedCallback; recorder.Closed += (sender, e) => { recorder.Dispose(); }; recorder.center(); recorder.ensureVisible(); recorder.open(true); }
public MaxExport(StandaloneController standaloneController) : base("Developer.GUI.MaxExport.MaxExport.layout") { this.medicalController = standaloneController.MedicalController; Button saveAll = (Button)window.findWidget("SaveAll"); saveAll.MouseButtonClick += saveAll_MouseButtonClick; Button saveAllVisible = (Button)window.findWidget("SaveAllVisible"); saveAllVisible.MouseButtonClick += saveAllVisible_MouseButtonClick; Button saveLeftTeethAsRight = (Button)window.findWidget("SaveLeftTeethAsRight"); saveLeftTeethAsRight.MouseButtonClick += saveLeftTeethAsRight_MouseButtonClick; Button saveRightTeethAsLeft = (Button)window.findWidget("SaveRighteethAsLeft"); saveRightTeethAsLeft.MouseButtonClick += saveRightTeethAsLeft_MouseButtonClick; }
private QuickSoundRecorder(MedicalController medicalController, String file, Func <String, Stream> streamProvider) : base("Medical.GUI.Editor.QuickSoundRecorder.QuickSoundRecorder.layout") { this.OutputFile = file; this.streamProvider = streamProvider; this.medicalController = medicalController; record = new CheckButton((Button)window.findWidget("Record")); record.CheckedChanged += new MyGUIEvent(enabled_CheckedChanged); record.Checked = PerformanceMonitor.Enabled; save = (Button)window.findWidget("Save"); save.MouseButtonClick += new MyGUIEvent(save_MouseButtonClick); save.Enabled = false; Button cancel = (Button)window.findWidget("Cancel"); cancel.MouseButtonClick += cancel_MouseButtonClick; status = (TextBox)window.findWidget("StatusLabel"); etLabel = (TextBox)window.findWidget("EtLabel"); }
public MovementSequenceController(MedicalController medicalController) { this.medicalController = medicalController; }
public OffsetSequenceEditorFactory(MedicalController medicalController, SaveableClipboard clipboard) { this.clipboard = clipboard; this.medicalController = medicalController; }
public KinectDebugVisualizer(StandaloneController controller) { medicalController = controller.MedicalController; }