Stop on movie end: Stop at correct frame, not one frame too late

This commit is contained in:
Ilari Liusvaara 2012-11-11 18:33:38 +02:00
parent 9a608775ee
commit 9e08783959

View file

@ -142,7 +142,7 @@ controller_frame movie_logic::update_controls(bool subframe) throw(std::bad_allo
}
platform::set_paused(amode == ADVANCE_PAUSE);
} else if(amode == ADVANCE_AUTO && movb.get_movie().readonly_mode() && pause_on_end) {
if(movb.get_movie().get_current_frame() == movb.get_movie().get_frame_count() + 1) {
if(movb.get_movie().get_current_frame() == movb.get_movie().get_frame_count()) {
amode = ADVANCE_PAUSE;
platform::set_paused(true);
}