Browse Source

Cleaned up a couple of minor analyser warnings.

tags/2021-05-28
jules 11 years ago
parent
commit
1e23cda2ff
2 changed files with 11 additions and 9 deletions
  1. +7
    -9
      extras/Introjucer/Source/ComponentEditor/jucer_PaintRoutine.cpp
  2. +4
    -0
      extras/Introjucer/Source/Utility/jucer_StoredSettings.cpp

+ 7
- 9
extras/Introjucer/Source/ComponentEditor/jucer_PaintRoutine.cpp 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))
{
if (PaintElement* const newElement = ObjectTypes::createElementForXml (&xml, this))
{
elements.insert (index, newElement);
changed();
elements.insert (index, newElement);
changed();
return newElement;
}
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);
}


+ 4
- 0
extras/Introjucer/Source/Utility/jucer_StoredSettings.cpp 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);


Loading…
Cancel
Save