diff options
author | bruvzg <7645683+bruvzg@users.noreply.github.com> | 2021-11-01 11:12:52 +0200 |
---|---|---|
committer | bruvzg <7645683+bruvzg@users.noreply.github.com> | 2021-11-01 11:48:23 +0200 |
commit | 0b6b8427c81f60f6298491100ceaed3247649539 (patch) | |
tree | b3323b8d0551a90f1175956a9d566cd02840d875 /core/os | |
parent | efbbd14af3f3325c4201518528e7acb93d60098a (diff) |
[macOS] Add `create_instance` function to spawn editor copies.
[macOS] Modify `create_project` function to detect and run app bundles using NSWorkspace to ensure app window is registered and activated correctly.
Diffstat (limited to 'core/os')
-rw-r--r-- | core/os/os.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/core/os/os.h b/core/os/os.h index f02f600c58..52bf731501 100644 --- a/core/os/os.h +++ b/core/os/os.h @@ -151,6 +151,7 @@ public: virtual String get_executable_path() const; virtual Error execute(const String &p_path, const List<String> &p_arguments, String *r_pipe = nullptr, int *r_exitcode = nullptr, bool read_stderr = false, Mutex *p_pipe_mutex = nullptr) = 0; virtual Error create_process(const String &p_path, const List<String> &p_arguments, ProcessID *r_child_id = nullptr) = 0; + virtual Error create_instance(const List<String> &p_arguments, ProcessID *r_child_id = nullptr) { return create_process(get_executable_path(), p_arguments, r_child_id); }; virtual Error kill(const ProcessID &p_pid) = 0; virtual int get_process_id() const; virtual void vibrate_handheld(int p_duration_ms = 500); |