# HG changeset patch # User Calin Crisan ccrisan@gmail.com # Date 1187036690 -10800 # Node ID 7a4fcf84a34f4f7d6d2d4311977abf6568bdfcbd # Parent 1292e4ca0f087310824d1471c5defa700b7efc30 Removed the hardcoded Add/Play CD menu entry diff -r 1292e4ca0f08 -r 7a4fcf84a34f config.guess diff -r 1292e4ca0f08 -r 7a4fcf84a34f config.rpath diff -r 1292e4ca0f08 -r 7a4fcf84a34f config.sub diff -r 1292e4ca0f08 -r 7a4fcf84a34f contrib/g15_audacious.py diff -r 1292e4ca0f08 -r 7a4fcf84a34f contrib/lap.py diff -r 1292e4ca0f08 -r 7a4fcf84a34f install-sh diff -r 1292e4ca0f08 -r 7a4fcf84a34f mkinstalldirs diff -r 1292e4ca0f08 -r 7a4fcf84a34f src/audacious/actions-mainwin.h --- a/src/audacious/actions-mainwin.h Mon Aug 13 18:49:34 2007 +0200 +++ b/src/audacious/actions-mainwin.h Mon Aug 13 23:24:50 2007 +0300 @@ -68,7 +68,6 @@ void action_playback_next(void); void action_playback_pause(void); void action_playback_play(void); -void action_playback_playcd(void); void action_playback_previous(void); void action_playback_stop(void); void action_preferences(void); diff -r 1292e4ca0f08 -r 7a4fcf84a34f src/audacious/actions-playlist.h --- a/src/audacious/actions-playlist.h Mon Aug 13 18:49:34 2007 +0200 +++ b/src/audacious/actions-playlist.h Mon Aug 13 23:24:50 2007 +0300 @@ -45,7 +45,7 @@ void action_playlist_remove_selected(void); void action_playlist_remove_unselected(void); -void action_playlist_add_cd(void); +/* void action_playlist_add_cd(void); - this is no longer needed, as the respective menu entry is added from within the cdaudio plugin */ void action_playlist_add_url(void); void action_playlist_add_files(void); diff -r 1292e4ca0f08 -r 7a4fcf84a34f src/audacious/intl/config.charset diff -r 1292e4ca0f08 -r 7a4fcf84a34f src/audacious/main.c --- a/src/audacious/main.c Mon Aug 13 18:49:34 2007 +0200 +++ b/src/audacious/main.c Mon Aug 13 23:24:50 2007 +0300 @@ -95,7 +95,7 @@ struct _BmpCmdLineOpt { gchar **filenames; gint session; - gboolean play, stop, pause, fwd, rew, play_pause, playcd, show_jump_box; + gboolean play, stop, pause, fwd, rew, play_pause, show_jump_box; gboolean enqueue, mainwin, remote, activate; gboolean load_skins; gboolean headless; @@ -1004,9 +1004,6 @@ if (options->activate) audacious_remote_activate(session); - - if (options->playcd) - play_medium(); } else { if (options->rew) audacious_drct_playlist_prev(); @@ -1038,9 +1035,6 @@ if (options->activate) audacious_drct_activate(); - - if (options->playcd) - play_medium(); } if(remote) { diff -r 1292e4ca0f08 -r 7a4fcf84a34f src/audacious/ui/mainwin.ui --- a/src/audacious/ui/mainwin.ui Mon Aug 13 18:49:34 2007 +0200 +++ b/src/audacious/ui/mainwin.ui Mon Aug 13 23:24:50 2007 +0300 @@ -14,7 +14,6 @@ - diff -r 1292e4ca0f08 -r 7a4fcf84a34f src/audacious/ui/playlist.ui --- a/src/audacious/ui/playlist.ui Mon Aug 13 18:49:34 2007 +0200 +++ b/src/audacious/ui/playlist.ui Mon Aug 13 23:24:50 2007 +0300 @@ -17,7 +17,6 @@ - diff -r 1292e4ca0f08 -r 7a4fcf84a34f src/audacious/ui_main.c --- a/src/audacious/ui_main.c Mon Aug 13 18:49:34 2007 +0200 +++ b/src/audacious/ui_main.c Mon Aug 13 23:24:50 2007 +0300 @@ -1778,12 +1778,6 @@ case MAINWIN_GENERAL_PLAYFILE: run_filebrowser(NO_PLAY_BUTTON); break; - case MAINWIN_GENERAL_PLAYCD: - play_medium(); - break; - case MAINWIN_GENERAL_ADDCD: - add_medium(); - break; case MAINWIN_GENERAL_PLAYLOCATION: mainwin_show_add_url_window(); break; @@ -1955,23 +1949,6 @@ mainwin_release_info_text(); } -static void -run_no_audiocd_dialog(void) -{ - const gchar *markup = - N_("No playable CD found.\n\n" - "No CD inserted, or inserted CD is not an audio CD.\n"); - - GtkWidget *dialog = - gtk_message_dialog_new_with_markup(GTK_WINDOW(mainwin), - GTK_DIALOG_DESTROY_WITH_PARENT, - GTK_MESSAGE_ERROR, - GTK_BUTTONS_OK, - _(markup)); - gtk_dialog_run(GTK_DIALOG(dialog)); - gtk_widget_destroy(dialog); -} - void run_no_output_device_dialog(gpointer hook_data, gpointer user_data) { @@ -1994,84 +1971,6 @@ GDK_THREADS_LEAVE(); } - -void -add_medium(void) -{ - GList *list, *node; - gchar *filename; - - /* - gchar *path; - ConfigDb *db; - - db = bmp_cfg_db_open(); - - if ( bmp_cfg_db_get_string(db, "CDDA", "directory", &path) != TRUE ) - { - bmp_cfg_db_close(db); - run_no_audiocd_dialog(); - return; - } - else - bmp_cfg_db_close(db); - */ - - if (!(list = input_scan_dir(CDDA_DUMMY_PATH))) { - run_no_audiocd_dialog(); - return; - } - - for (node = list; node; node = g_list_next(node)) { - filename = g_build_filename(CDDA_DUMMY_PATH, node->data, NULL); - playlist_add(playlist_get_active(), filename); - g_free(filename); - g_free(node->data); - } - - /*g_free(path);*/ - g_list_free(list); - -} - -void -play_medium(void) -{ - GList *list, *node; - gchar *filename; - /* - gchar *path; - ConfigDb *db; - */ - Playlist *playlist = playlist_get_active(); - - /* - db = bmp_cfg_db_open(); - bmp_cfg_db_get_string(db, "CDDA", "directory", &path); - bmp_cfg_db_close(db); - */ - - if (!(list = input_scan_dir(CDDA_DUMMY_PATH))) { - run_no_audiocd_dialog(); - return; - } - - playlist_clear(playlist); - - for (node = list; node; node = g_list_next(node)) { - filename = g_build_filename(CDDA_DUMMY_PATH, node->data, NULL); - playlist_add(playlist, filename); - g_free(filename); - g_free(node->data); - } - - /*g_free(path);*/ - g_list_free(list); - - playlist_set_position(playlist, 0); - playback_initiate(); -} - void read_volume(gint when) { @@ -3103,12 +3002,6 @@ } void -action_playback_playcd( void ) -{ - play_medium(); -} - -void action_playback_pause( void ) { playback_pause(); diff -r 1292e4ca0f08 -r 7a4fcf84a34f src/audacious/ui_main.h --- a/src/audacious/ui_main.h Mon Aug 13 18:49:34 2007 +0200 +++ b/src/audacious/ui_main.h Mon Aug 13 23:24:50 2007 +0300 @@ -42,8 +42,6 @@ #define MAINWIN_DEFAULT_FONT "Sans Bold 9" -#define CDDA_DUMMY_PATH "cdda://default" - typedef enum { TIMER_ELAPSED, @@ -67,11 +65,8 @@ MAINWIN_GENERAL_FOCUSPLWIN, MAINWIN_GENERAL_SHOWEQWIN, - MAINWIN_GENERAL_PLAYCD, MAINWIN_GENERAL_EXIT, - MAINWIN_GENERAL_ADDCD, - MAINWIN_GENERAL_PREV, MAINWIN_GENERAL_PLAY, MAINWIN_GENERAL_PAUSE, @@ -121,10 +116,6 @@ void mainwin_create(void); void read_volume(gint when); -void play_medium(void); -void add_medium(void); - -void draw_main_window(gboolean); void mainwin_quit_cb(void); void mainwin_lock_info_text(const gchar * text); diff -r 1292e4ca0f08 -r 7a4fcf84a34f src/audacious/ui_manager.c --- a/src/audacious/ui_manager.c Mon Aug 13 18:49:34 2007 +0200 +++ b/src/audacious/ui_manager.c Mon Aug 13 23:24:50 2007 +0300 @@ -238,10 +238,6 @@ }; static GtkActionEntry action_entries_playlist_add[] = { - { "playlist add cd", GTK_STOCK_CDROM, N_("Add CD..."), "C", - N_("Adds a CD to the playlist."), - G_CALLBACK(action_playlist_add_cd) }, - { "playlist add url", GTK_STOCK_NETWORK, N_("Add Internet Address..."), "H", N_("Adds a remote track to the playlist."), G_CALLBACK(action_playlist_add_url) }, @@ -394,13 +390,10 @@ { "play location", GTK_STOCK_NETWORK , N_("Play Location"), "L", N_("Play media from the selected location"), G_CALLBACK(action_play_location) }, - { "playback play cd", GTK_STOCK_CDROM , N_("Play CD"), "C", - N_("Play CD"), G_CALLBACK(action_playback_playcd) }, - { "lastfm", NULL, N_("Last.fm radio"), "L", N_("Play Last.fm radio"), G_CALLBACK(action_lastfm) }, - { "plugins", NULL , N_("Plugins") }, + { "plugins", NULL , N_("Plugins") }, { "preferences", GTK_STOCK_PREFERENCES , N_("Preferences"), "P", N_("Open preferences window"), G_CALLBACK(action_preferences) }, diff -r 1292e4ca0f08 -r 7a4fcf84a34f src/audacious/ui_playlist.c --- a/src/audacious/ui_playlist.c Mon Aug 13 18:49:34 2007 +0200 +++ b/src/audacious/ui_playlist.c Mon Aug 13 23:24:50 2007 +0300 @@ -1831,12 +1831,6 @@ } void -action_playlist_add_cd(void) -{ - add_medium(); -} - -void action_playlist_add_url(void) { mainwin_show_add_url_window();