mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Added some overloads to OwnedArray to let items be added from std::unique_ptrs. Also removed OwnedArray::addIfNotAlreadyThere because it's ambiguous about whether the object should be deleted if it fails to be added!
This commit is contained in:
parent
332a9edb57
commit
62ead7dc7d
12 changed files with 94 additions and 56 deletions
|
|
@ -2385,15 +2385,11 @@ private:
|
|||
|
||||
void getIconImages (OwnedArray<Drawable>& images) const
|
||||
{
|
||||
std::unique_ptr<Drawable> bigIcon (getBigIcon());
|
||||
if (auto icon = getBigIcon())
|
||||
images.add (std::move (icon));
|
||||
|
||||
if (bigIcon != nullptr)
|
||||
images.add (bigIcon.release());
|
||||
|
||||
std::unique_ptr<Drawable> smallIcon (getSmallIcon());
|
||||
|
||||
if (smallIcon != nullptr)
|
||||
images.add (smallIcon.release());
|
||||
if (auto icon = getSmallIcon())
|
||||
images.add (std::move (icon));
|
||||
}
|
||||
|
||||
void createiOSIconFiles (File appIconSet) const
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue