MCPcopy Create free account
hub / github.com/RomanKubiak/ctrlr / getDefaultMethodTree

Method getDefaultMethodTree

Source/Lua/Methods/CtrlrLuaMethodManager.cpp:495–509  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

493}
494
495ValueTree CtrlrLuaMethodManager::getDefaultMethodTree(const String &methodName, const String &methodCode, const String &methodProperty, const Uuid methodUuid)
496{
497 ValueTree methodTree (Ids::luaMethod);
498 methodTree.setProperty (Ids::luaMethodName, methodName, nullptr);
499
500 if (methodCode.isEmpty())
501 methodTree.setProperty (Ids::luaMethodCode, getDefaultMethodCode(methodName, methodProperty), nullptr);
502 else
503 methodTree.setProperty (Ids::luaMethodCode, methodCode, nullptr);
504
505 methodTree.setProperty (Ids::luaMethodLinkedProperty, methodProperty, nullptr);
506 methodTree.setProperty (Ids::luaMethodSource, (int)CtrlrLuaMethod::codeInProperty, nullptr);
507 methodTree.setProperty (Ids::uuid, methodUuid.isNull() ? Uuid().toString() : methodUuid.toString(), nullptr);
508 return (methodTree);
509}
510
511ValueTree CtrlrLuaMethodManager::getDefaultMethodTree(const File &methodFileSource, const Uuid methodUuid)
512{

Callers

nothing calls this directly

Calls 11

getPanelLuaDirMethod · 0.80
isAChildOfMethod · 0.80
getRelativePathFromMethod · 0.80
setPropertyMethod · 0.45
isEmptyMethod · 0.45
isNullMethod · 0.45
toStringMethod · 0.45
getOwnerMethod · 0.45
existsMethod · 0.45
isDirectoryMethod · 0.45

Tested by

no test coverage detected