swaroop: unload film when playlist ends.
authorCarl Hetherington <cth@carlh.net>
Tue, 18 Dec 2018 22:36:19 +0000 (22:36 +0000)
committerCarl Hetherington <cth@carlh.net>
Tue, 18 Dec 2018 22:36:19 +0000 (22:36 +0000)
src/wx/swaroop_controls.cc

index 176efc4..292898b 100644 (file)
@@ -405,5 +405,10 @@ SwaroopControls::viewer_finished ()
                return;
        }
 
-       next_clicked ();
+       _selected_playlist_position++;
+       if (_selected_playlist_position < int(_playlists[*_selected_playlist].get().size())) {
+               update_current_content ();
+       } else {
+               ResetFilm (shared_ptr<Film>(new Film(optional<boost::filesystem::path>())));
+       }
 }