History

Merge master' into 'workload'

Andrew Meadows committed 8 years ago

Commit 4329ea52 parents 8eedf83 38e7b3166 files · +807 −575Browse files

Showing the changes to libraries/entities/src/EntityScriptingInterface.cpp (1 of 66 files). Show all

Unified · Split

libraries/entities/src/EntityScriptingInterface.cpp+14−8
@@ -1688,15 +1688,21 @@ QVector<QUuid> EntityScriptingInterface::getChildrenIDs(const QUuid& parentID) { · 1687 unmodified lines
1688 if (!_entityTree) {1688 if (!_entityTree) {
1689 return result;1689 return result;
1690 }1690 }
1691
1692 EntityItemPointer entity = _entityTree->findEntityByEntityItemID(parentID);
1693 if (!entity) {
1694 qCDebug(entities) << "EntityScriptingInterface::getChildrenIDs - no entity with ID" << parentID;
1695 return result;
1696 }
1697
1698 _entityTree->withReadLock([&] {1691 _entityTree->withReadLock([&] {
1699 entity->forEachChild([&](SpatiallyNestablePointer child) {1692 QSharedPointer<SpatialParentFinder> parentFinder = DependencyManager::get<SpatialParentFinder>();
1693 if (!parentFinder) {
1694 return;
1695 }
1696 bool success;
1697 SpatiallyNestableWeakPointer parentWP = parentFinder->find(parentID, success);
1698 if (!success) {
1699 return;
1700 }
1701 SpatiallyNestablePointer parent = parentWP.lock();
1702 if (!parent) {
1703 return;
1704 }
1705 parent->forEachChild([&](SpatiallyNestablePointer child) {
1700 result.push_back(child->getID());1706 result.push_back(child->getID());
1701 });1707 });
1702 });1708 });

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t