Exemplo n.º 1
0
 public void TryLaunch()
 {
     if (LaunchServerOnStart && !string.IsNullOrEmpty(OSVRServerPaths.Path))
     {
         OSVRServerPaths.Launch();
     }
 }
Exemplo n.º 2
0
    /// <summary>
    /// Drawing of the frame
    /// </summary>
    void OnGUI()
    {
        GUILayout.Label("Settings", EditorStyles.boldLabel);

        OSVRServerPaths.UsingWindows = EditorGUILayout.ToggleLeft("Using Windows?", OSVRServerPaths.UsingWindows);

        OSVRServerPaths.Path = EditorGUILayout.TextField("Path", OSVRServerPaths.Path);
        EditorGUILayout.TextArea("    Example:  C:\\dev\\osvr-latest\\");

        OSVRServerPaths.Executable = EditorGUILayout.TextField("Executable", OSVRServerPaths.Executable);
        EditorGUILayout.TextArea("    Example:  osvr_server.exe");

        OSVRServerPaths.Arguments = EditorGUILayout.TextField("Arguments", OSVRServerPaths.Arguments);
        EditorGUILayout.TextArea("    Example:  osvr_server_config-oculusrift.json");

        if (GUILayout.Button("Save & Launch"))
        {
            OSVRServerPaths.CheckPath();
            OSVRServerPaths.Save();
            OSVRServerPaths.Launch();
        }
        if (GUILayout.Button("Save"))
        {
            OSVRServerPaths.CheckPath();
            OSVRServerPaths.Save();
        }
        if (GUILayout.Button("Close"))
        {
            Quit();
        }
    }
Exemplo n.º 3
0
 /// <summary>
 /// Actual logic for saving
 /// </summary>
 public void Save()
 {
     PreSavePost();
     OSVRServerPaths.CheckPath();
     OSVRServerPaths.Save();
     // Executed in case the paths changed in the CheckPath method
     PostLoadUpdate();
 }
Exemplo n.º 4
0
 /// <summary>
 /// Launches the application
 /// </summary>
 public void Launch()
 {
     OSVRServerPaths.Launch();
 }
Exemplo n.º 5
0
 /// <summary>
 /// Actual logic for loading
 /// </summary>
 public void Load()
 {
     OSVRServerPaths.Load();
     PostLoadUpdate();
 }
Exemplo n.º 6
0
 public static void ShowWindow()
 {
     OSVRServerPaths.Load();
     GetWindow(typeof(OSVRWindowPaths));
 }