You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-06 12:20:30 +00:00
Optimise Object's get_argument_options
This commit is contained in:
@@ -492,9 +492,9 @@ bool EditorInterface::is_movie_maker_enabled() const {
|
||||
return EditorRunBar::get_singleton()->is_movie_maker_enabled();
|
||||
}
|
||||
|
||||
// Base.
|
||||
#ifdef TOOLS_ENABLED
|
||||
void EditorInterface::get_argument_options(const StringName &p_function, int p_idx, List<String> *r_options) const {
|
||||
String pf = p_function;
|
||||
const String pf = p_function;
|
||||
if (p_idx == 0) {
|
||||
if (pf == "set_main_screen_editor") {
|
||||
for (String E : { "\"2D\"", "\"3D\"", "\"Script\"", "\"AssetLib\"" }) {
|
||||
@@ -508,6 +508,9 @@ void EditorInterface::get_argument_options(const StringName &p_function, int p_i
|
||||
}
|
||||
Object::get_argument_options(p_function, p_idx, r_options);
|
||||
}
|
||||
#endif
|
||||
|
||||
// Base.
|
||||
|
||||
void EditorInterface::_bind_methods() {
|
||||
ClassDB::bind_method(D_METHOD("restart_editor", "save"), &EditorInterface::restart_editor, DEFVAL(true));
|
||||
|
||||
Reference in New Issue
Block a user