From 4b00c2ec57317d71c8e1b217952715c1b6006648 Mon Sep 17 00:00:00 2001 From: cespeute Date: Tue, 10 May 2022 22:25:36 +0200 Subject: Add EditorInterface.get_selected_paths() Exposes the selected paths in the editor filesystem dock. Implements this proposal : https://github.com/godotengine/godot-proposals/issues/2424 Also renamed the old `get_selected_path` to `get_selected_directory` to better match the already existing get_current_path function. --- doc/classes/EditorInterface.xml | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'doc') diff --git a/doc/classes/EditorInterface.xml b/doc/classes/EditorInterface.xml index bb319cb5a3..5d4b83bc27 100644 --- a/doc/classes/EditorInterface.xml +++ b/doc/classes/EditorInterface.xml @@ -48,6 +48,12 @@ [b]Warning:[/b] Removing and freeing this node will render a part of the editor useless and may cause a crash. + + + + Returns the current directory being viewed in the [FileSystemDock]. If a file is selected, its base directory will be returned using [method String.get_base_dir] instead. + + @@ -131,10 +137,10 @@ [b]Warning:[/b] Removing and freeing this node will render a part of the editor useless and may cause a crash. - - + + - Returns the path of the directory currently selected in the [FileSystemDock]. If a file is selected, its base directory will be returned using [method String.get_base_dir] instead. + Returns an array containing the paths of the currently selected files (and directories) in the [FileSystemDock]. -- cgit v1.2.3