mirror of
https://github.com/godotengine/godot.git
synced 2025-10-20 00:13:30 +00:00
Optimize StringName usage
* Added a new macro SNAME() that constructs and caches a local stringname. * Subsequent usages use the cached version. * Since these use a global static variable, a second refcounter of static usages need to be kept for cleanup time. * Replaced all theme usages by this new macro. * Replace all signal emission usages by this new macro. * Replace all call_deferred usages by this new macro. This is part of ongoing work to optimize GUI and the editor.
This commit is contained in:
parent
b76dfde329
commit
6631f66c2a
236 changed files with 3694 additions and 3670 deletions
|
@ -97,7 +97,7 @@ extern EMSCRIPTEN_KEEPALIVE int godot_js_main(int argc, char *argv[]) {
|
|||
if (Main::is_project_manager() && FileAccess::exists("/tmp/preload.zip")) {
|
||||
PackedStringArray ps;
|
||||
ps.push_back("/tmp/preload.zip");
|
||||
os->get_main_loop()->emit_signal("files_dropped", ps, -1);
|
||||
os->get_main_loop()->emit_signal(SNAME("files_dropped"), ps, -1);
|
||||
}
|
||||
#endif
|
||||
emscripten_set_main_loop(main_loop_callback, -1, false);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue