mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-26 02:14:22 +00:00
Added a template to allow the HeapBlock class to be given signed ints or other types that are not size_t for its size parameters
This commit is contained in:
parent
13ccdf9411
commit
369d59f656
32 changed files with 189 additions and 199 deletions
|
|
@ -632,11 +632,11 @@ public:
|
|||
void sortChildElements (ElementComparator& comparator,
|
||||
bool retainOrderOfEquivalentItems = false)
|
||||
{
|
||||
const int num = getNumChildElements();
|
||||
auto num = getNumChildElements();
|
||||
|
||||
if (num > 1)
|
||||
{
|
||||
HeapBlock<XmlElement*> elems ((size_t) num);
|
||||
HeapBlock<XmlElement*> elems (num);
|
||||
getChildElementsAsArray (elems);
|
||||
sortArray (comparator, (XmlElement**) elems, 0, num - 1, retainOrderOfEquivalentItems);
|
||||
reorderChildElements (elems, num);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue