You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-06 12:20:30 +00:00
Added open_script_create_dialog func
This commit is contained in:
@@ -1845,6 +1845,11 @@ void ScriptEditor::apply_scripts() const {
|
||||
}
|
||||
}
|
||||
|
||||
void ScriptEditor::open_script_create_dialog(const String &p_base_name, const String &p_base_path) {
|
||||
_menu_option(FILE_NEW);
|
||||
script_create_dialog->config(p_base_name, p_base_path);
|
||||
}
|
||||
|
||||
void ScriptEditor::_editor_play() {
|
||||
|
||||
debugger->start();
|
||||
@@ -2548,6 +2553,7 @@ void ScriptEditor::_bind_methods() {
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_current_script"), &ScriptEditor::_get_current_script);
|
||||
ClassDB::bind_method(D_METHOD("get_open_scripts"), &ScriptEditor::_get_open_scripts);
|
||||
ClassDB::bind_method(D_METHOD("open_script_create_dialog", "base_name", "base_path"), &ScriptEditor::open_script_create_dialog);
|
||||
|
||||
ADD_SIGNAL(MethodInfo("editor_script_changed", PropertyInfo(Variant::OBJECT, "script", PROPERTY_HINT_RESOURCE_TYPE, "Script")));
|
||||
ADD_SIGNAL(MethodInfo("script_close", PropertyInfo(Variant::OBJECT, "script", PROPERTY_HINT_RESOURCE_TYPE, "Script")));
|
||||
|
||||
Reference in New Issue
Block a user