mirror of
https://github.com/godotengine/godot.git
synced 2025-10-25 02:43:29 +00:00
Added "Show In FileSystem" right-click option to Scene hierarchy nodes.
-Implemented shared function for focusing FileSystem tab and highlighting the node path. -Created right-click option that shows up in the Scene-Hierarchy on Nodes that have a file-system source path. -Created custom icon for this right-click option -Implemented the shared function and icon for other places that already had this features (Open Node tab, Inspector Resource) Co-authored-by: MewPurPur <mew.pur.pur@gmail.com>
This commit is contained in:
parent
c455cb6555
commit
59787683a9
8 changed files with 34 additions and 18 deletions
|
|
@ -1427,11 +1427,7 @@ void ScriptEditor::_menu_option(int p_option) {
|
|||
path = path.get_slice("::", 0); // Show the scene instead.
|
||||
}
|
||||
|
||||
FileSystemDock *file_system_dock = FileSystemDock::get_singleton();
|
||||
file_system_dock->navigate_to_path(path);
|
||||
// Ensure that the FileSystem dock is visible.
|
||||
TabContainer *dock_tab_container = (TabContainer *)file_system_dock->get_parent_control();
|
||||
dock_tab_container->set_current_tab(dock_tab_container->get_tab_idx_from_control(file_system_dock));
|
||||
FileSystemDock::get_singleton()->navigate_to_path(path);
|
||||
}
|
||||
} break;
|
||||
case CLOSE_DOCS: {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue