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

Cleaned up a couple of minor analyser warnings.

This commit is contained in:
jules 2014-07-18 12:56:10 +01:00
parent 7b8ab7b503
commit 1e23cda2ff
2 changed files with 12 additions and 10 deletions

View file

@ -134,15 +134,13 @@ PaintElement* PaintRoutine::addElementFromXml (const XmlElement& xml, const int
return elements [action->indexAdded];
}
else
{
if (PaintElement* const newElement = ObjectTypes::createElementForXml (&xml, this))
{
elements.insert (index, newElement);
changed();
return newElement;
}
if (PaintElement* const newElement = ObjectTypes::createElementForXml (&xml, this))
{
elements.insert (index, newElement);
changed();
return newElement;
}
return nullptr;
@ -390,10 +388,10 @@ void PaintRoutine::groupSelected()
void PaintRoutine::ungroupSelected()
{
const SelectedItemSet <PaintElement*> temp (selectedElements);
const SelectedItemSet<PaintElement*> temp (selectedElements);
for (int i = 0; i < temp.getNumSelected(); ++i)
if (PaintElementGroup* const pg = dynamic_cast <PaintElementGroup*> (temp.getSelectedItem (i)))
if (PaintElementGroup* const pg = dynamic_cast<PaintElementGroup*> (temp.getSelectedItem (i)))
pg->ungroup (true);
}

View file

@ -117,8 +117,12 @@ void StoredSettings::reload()
recentFiles.removeNonExistentFiles();
ScopedPointer<XmlElement> xml (getGlobalProperties().getXmlValue ("editorColours"));
if (xml == nullptr)
{
xml = XmlDocument::parse (BinaryData::colourscheme_dark_xml);
jassert (xml != nullptr);
}
appearance.readFromXML (*xml);