diff options
-rw-r--r-- | engines/sci/graphics/plane32.cpp | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/engines/sci/graphics/plane32.cpp b/engines/sci/graphics/plane32.cpp index de82a40f9e..6961a9ac1a 100644 --- a/engines/sci/graphics/plane32.cpp +++ b/engines/sci/graphics/plane32.cpp @@ -792,6 +792,17 @@ void Plane::update(const reg_t object) { #pragma mark - #pragma mark PlaneList +void PlaneList::add(Plane *plane) { + for (iterator it = begin(); it != end(); ++it) { + if ((*it)->_priority > plane->_priority) { + insert(it, plane); + return; + } + } + + push_back(plane); +} + void PlaneList::clear() { for (iterator it = begin(); it != end(); ++it) { delete *it; @@ -860,15 +871,4 @@ void PlaneList::remove_at(size_type index) { delete PlaneListBase::remove_at(index); } -void PlaneList::add(Plane *plane) { - for (iterator it = begin(); it != end(); ++it) { - if ((*it)->_priority > plane->_priority) { - insert(it, plane); - return; - } - } - - push_back(plane); -} - } |