diff options
author | Colin Snover | 2016-03-06 21:30:03 -0600 |
---|---|---|
committer | Colin Snover | 2016-03-06 21:34:44 -0600 |
commit | 56806161a747b1e806fa75acb56bafe7897dbea0 (patch) | |
tree | 1142dfa8b72bd83eba0fec061a61fdb1ab63b437 /engines/sci | |
parent | 36800b701764222ec0c527f68504d1d3dc2e1fcc (diff) | |
download | scummvm-rg350-56806161a747b1e806fa75acb56bafe7897dbea0.tar.gz scummvm-rg350-56806161a747b1e806fa75acb56bafe7897dbea0.tar.bz2 scummvm-rg350-56806161a747b1e806fa75acb56bafe7897dbea0.zip |
SCI32: Make PlaneList definition order match declaration order
Diffstat (limited to 'engines/sci')
-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); -} - } |