Skip to content

Commit d983937

Browse files
committed
Make phpactor-action-open-file expect target
This argument is added in phpactor/rpc-extension phpactor/rpc-extension#1
1 parent 5dc3316 commit d983937

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

phpactor.el

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -385,11 +385,16 @@ of GitHub.")
385385
(apply #'phpactor-action-dispatch (list :action (plist-get action :name) :parameters (plist-get action :parameters))))
386386
actions))
387387

388-
(cl-defun phpactor-action-open-file (&key path offset force_reload)
388+
(cl-defun phpactor-action-open-file (&key path offset force_reload target)
389389
"Open file from Phpactor."
390390
(unless (and path offset)
391391
(user-error "Definition not found"))
392392

393+
;; TODO: Implement other target: Phpactor\Extension\Rpc\Response\OpenFileResponse
394+
;; `target' expects "focused_window", "vsplit", "hsplit" and "new_tab"
395+
(unless target
396+
(setq target "focused_window"))
397+
393398
(if (fboundp 'xref-push-marker-stack)
394399
(xref-push-marker-stack)
395400
(with-no-warnings

0 commit comments

Comments
 (0)