Code style.

--HG--
branch : feature
This commit is contained in:
Roman Telezhynskyi 2017-01-17 13:49:21 +02:00
parent 7aebc22d88
commit bfd76b4e60

View File

@ -256,9 +256,9 @@ template <typename T>
const QSharedPointer<T> VContainer::GeometricObject(const quint32 &id) const const QSharedPointer<T> VContainer::GeometricObject(const quint32 &id) const
{ {
QSharedPointer<VGObject> gObj = QSharedPointer<VGObject>(); QSharedPointer<VGObject> gObj = QSharedPointer<VGObject>();
if (d->gObjects.contains(id)) if (d->gObjects.contains(id))
{ {
gObj = d->gObjects.value(id); gObj = d->gObjects.value(id);
} }
else else
{ {
@ -269,11 +269,11 @@ const QSharedPointer<T> VContainer::GeometricObject(const quint32 &id) const
QSharedPointer<T> obj = qSharedPointerDynamicCast<T>(gObj); QSharedPointer<T> obj = qSharedPointerDynamicCast<T>(gObj);
SCASSERT(obj.isNull() == false) SCASSERT(obj.isNull() == false)
return obj; return obj;
} }
catch (const std::bad_alloc &) catch (const std::bad_alloc &)
{ {
throw VExceptionBadId(tr("Can't cast object"), id); throw VExceptionBadId(tr("Can't cast object"), id);
} }
} }