1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-27 02:20:05 +00:00

Added some methods to allow ReferenceCountedObjectPtrs to be constructed or copied from references as well as pointers - as well as increasing safety, this actually makes things a bit more efficient as it skips a nullptr check. Updated lots of places in the code that could take advantage of this

This commit is contained in:
jules 2018-07-03 11:51:13 +01:00
parent 3c124095dd
commit 1e6bbb8da9
34 changed files with 309 additions and 251 deletions

View file

@ -625,7 +625,7 @@ protected:
BuildConfiguration::Ptr createBuildConfig (const ValueTree& v) const override
{
return new XcodeBuildConfiguration (project, v, iOS, *this);
return *new XcodeBuildConfiguration (project, v, iOS, *this);
}
public:
@ -3078,7 +3078,7 @@ private:
for (auto& type : getiOSAppIconTypes())
{
DynamicObject::Ptr d = new DynamicObject();
DynamicObject::Ptr d (new DynamicObject());
d->setProperty ("idiom", type.idiom);
d->setProperty ("size", type.sizeString);
d->setProperty ("filename", type.filename);
@ -3146,7 +3146,7 @@ private:
for (auto& type : getiOSLaunchImageTypes())
{
DynamicObject::Ptr d = new DynamicObject();
DynamicObject::Ptr d (new DynamicObject());
d->setProperty ("orientation", type.orientation);
d->setProperty ("idiom", type.idiom);
d->setProperty ("extent", type.extent);