diff options
author | Uwe Klotz <uklotz@mixxx.org> | 2020-08-22 15:47:46 +0200 |
---|---|---|
committer | Uwe Klotz <uklotz@mixxx.org> | 2020-08-23 12:09:06 +0200 |
commit | 6078973e169b8cb515104a61b1e1be681b2fe6d0 (patch) | |
tree | 7a70b6b6514447b0bccf90803be0161827d7187b /src/library/library.cpp | |
parent | a1ee9b6084ce59f691b3c5a0a99e8d03d9433f64 (diff) |
Use type-safe enum class Library::RemovalType
Diffstat (limited to 'src/library/library.cpp')
-rw-r--r-- | src/library/library.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/src/library/library.cpp b/src/library/library.cpp index 136c92c4cb..e82533df1a 100644 --- a/src/library/library.cpp +++ b/src/library/library.cpp @@ -477,19 +477,19 @@ void Library::slotRequestAddDir(QString dir) { void Library::slotRequestRemoveDir(QString dir, RemovalType removalType) { switch (removalType) { - case Library::HideTracks: - // Mark all tracks in this directory as deleted but DON'T purge them - // in case the user re-adds them manually. - m_pTrackCollectionManager->hideAllTracks(dir); - break; - case Library::PurgeTracks: - // The user requested that we purge all metadata. - m_pTrackCollectionManager->purgeAllTracks(dir); - break; - case Library::LeaveTracksUnchanged: - default: - break; - + case RemovalType::KeepTracks: + break; + case RemovalType::HideTracks: + // Mark all tracks in this directory as deleted but DON'T purge them + // in case the user re-adds them manually. + m_pTrackCollectionManager->hideAllTracks(dir); + break; + case RemovalType::PurgeTracks: + // The user requested that we purge all metadata. + m_pTrackCollectionManager->purgeAllTracks(dir); + break; + default: + DEBUG_ASSERT(!"unreachable"); } // Remove the directory from the directory list. |