diff options
Diffstat (limited to '')
-rw-r--r-- | src/UpdateRemove.cxx (renamed from src/update_remove.c) | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/src/update_remove.c b/src/UpdateRemove.cxx index f443f5eb2..f7e6c80ec 100644 --- a/src/update_remove.c +++ b/src/UpdateRemove.cxx @@ -18,15 +18,17 @@ */ #include "config.h" /* must be first for large file support */ -#include "update_remove.h" -#include "event_pipe.h" +#include "UpdateRemove.hxx" +#include "Playlist.hxx" +#include "Partition.hxx" +#include "GlobalEvents.hxx" + #include "song.h" -#include "playlist.h" -#include "main.h" +#include "Main.hxx" #ifdef ENABLE_SQLITE -#include "sticker.h" -#include "song_sticker.h" +#include "StickerDatabase.hxx" +#include "SongSticker.hxx" #endif #include <glib.h> @@ -59,7 +61,7 @@ song_remove_event(void) sticker_song_delete(removed_song); #endif - playlist_delete_song(&g_playlist, global_player_control, removed_song); + global_partition->DeleteSong(*removed_song); /* clear "removed_song" and send signal to update thread */ g_mutex_lock(remove_mutex); @@ -74,7 +76,7 @@ update_remove_global_init(void) remove_mutex = g_mutex_new(); remove_cond = g_cond_new(); - event_pipe_register(PIPE_EVENT_DELETE, song_remove_event); + GlobalEvents::Register(GlobalEvents::DELETE, song_remove_event); } void @@ -91,7 +93,7 @@ update_remove_song(const struct song *song) removed_song = song; - event_pipe_emit(PIPE_EVENT_DELETE); + GlobalEvents::Emit(GlobalEvents::DELETE); g_mutex_lock(remove_mutex); |