MCPcopy Create free account
hub / github.com/Redot-Engine/redot-engine / callp

Method callp

platform/web/javascript_bridge_singleton.cpp:242–253  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

240}
241
242Variant JavaScriptObjectImpl::callp(const StringName &p_method, const Variant **p_args, int p_argc, Callable::CallError &r_error) {
243 godot_js_wrapper_ex exchange;
244 const String method = p_method;
245 void *lock = nullptr;
246 const int type = godot_js_wrapper_object_call(_js_id, method.utf8().get_data(), (void **)p_args, p_argc, &_variant2js, &exchange, &lock, &_free_lock);
247 r_error.error = Callable::CallError::CALL_OK;
248 if (type < 0) {
249 r_error.error = Callable::CallError::CALL_ERROR_INSTANCE_IS_NULL;
250 return Variant();
251 }
252 return _js2variant(type, &exchange);
253}
254
255void JavaScriptObjectImpl::callback(void *p_ref, int p_args_id, int p_argc) {
256 const JavaScriptObjectImpl *obj = (JavaScriptObjectImpl *)p_ref;

Callers 8

dialog_showMethod · 0.45
WndProcMethod · 0.45
DropMethod · 0.45
_menu_activateMethod · 0.45
popupMethod · 0.45

Calls 3

VariantClass · 0.50
get_dataMethod · 0.45
utf8Method · 0.45

Tested by

no test coverage detected