mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 04:44:11 +02:00
Fixed Overlays::isLoaded which did not to find my just created overlay.
This commit is contained in:
parent
388332966d
commit
cbb3d463b6
1 changed files with 7 additions and 7 deletions
|
@ -359,14 +359,14 @@ void RayToOverlayIntersectionResultFromScriptValue(const QScriptValue& object, R
|
|||
|
||||
bool Overlays::isLoaded(unsigned int id) {
|
||||
QReadLocker lock(&_lock);
|
||||
Overlay* overlay = _overlays2D.value(id);
|
||||
if (!overlay) {
|
||||
_overlays3D.value(id);
|
||||
}
|
||||
if (!overlay) {
|
||||
Overlay* thisOverlay = NULL;
|
||||
if (_overlays2D.contains(id)) {
|
||||
thisOverlay = _overlays2D[id];
|
||||
} else if (_overlays3D.contains(id)) {
|
||||
thisOverlay = _overlays3D[id];
|
||||
} else {
|
||||
return false; // not found
|
||||
}
|
||||
|
||||
return overlay->isLoaded();
|
||||
return thisOverlay->isLoaded();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue