Fixed the removal of appended files if there is no track from another file between two tracks from the file that is to be removed.

This commit is contained in:
Moritz Bunkus 2005-02-27 21:54:26 +00:00
parent 5afb199e66
commit c220f55792
2 changed files with 6 additions and 1 deletions

View File

@ -1,5 +1,9 @@
2005-02-27 Moritz Bunkus <moritz@bunkus.org>
* mmg: bug fix: An "appended" file could not be removed if there
were two tracks that we not separated by a track from another file
in the track list box.
* mmg: bug fix: The check whether or not a file might be
overwritten while splitting is active has been fixed.

View File

@ -983,7 +983,8 @@ tab_input::on_remove_file(wxCommandEvent &evt) {
// Files may not be removed if something else is still being appended to
// them.
for (i = 0; i < (tracks.size() - 1); i++)
if ((tracks[i]->source == selected_file) && tracks[i + 1]->appending) {
if ((tracks[i]->source == selected_file) && tracks[i + 1]->appending &&
(tracks[i]->source != tracks[i + 1]->source)) {
wxString err;
err.Printf(wxT("The current file (number %d) cannot be removed. There "