# HG changeset patch # User nenolod # Date 1153066291 25200 # Node ID 01dcb223833acc3762bb38a76873dce9716cb8aa # Parent ff637a82e85f414e9265455927b36c91e7387e00 [svn] - sort by track number diff -r ff637a82e85f -r 01dcb223833a ChangeLog --- a/ChangeLog Sun Jul 16 08:50:00 2006 -0700 +++ b/ChangeLog Sun Jul 16 09:11:31 2006 -0700 @@ -1,3 +1,40 @@ +2006-07-16 15:50:00 +0000 William Pitcock + revision [1742] + - update PO files + + + Changes: Modified: + +2 -0 trunk/po/Makevars + +0 -1 trunk/po/POTFILES.in + +1398 -1714 trunk/po/audacious.pot + +1594 -1749 trunk/po/br.po + +1764 -1769 trunk/po/cs.po + +1525 -1754 trunk/po/cy.po + +1831 -1771 trunk/po/de.po + +1778 -1747 trunk/po/el.po + +1772 -1751 trunk/po/es.po + +1702 -1760 trunk/po/fi.po + +1701 -1763 trunk/po/fr.po + +1699 -1761 trunk/po/hi.po + +1770 -1745 trunk/po/hu.po + +1856 -1761 trunk/po/it.po + +1433 -1372 trunk/po/ja.po + +1555 -1753 trunk/po/ka.po + +1628 -1759 trunk/po/ko.po + +1699 -1761 trunk/po/lt.po + +1698 -1759 trunk/po/mk.po + +1832 -1770 trunk/po/nl.po + +1851 -1791 trunk/po/pl.po + +1649 -1762 trunk/po/pt_BR.po + +1516 -1753 trunk/po/ro.po + +1663 -1767 trunk/po/ru.po + +1678 -1761 trunk/po/sk.po + +1525 -1754 trunk/po/sv.po + +1660 -1757 trunk/po/uk.po + +1578 -1755 trunk/po/zh_CN.po + +1737 -1798 trunk/po/zh_TW.po + + 2006-07-16 15:14:08 +0000 William Pitcock revision [1740] - filepopup albumart stuff, via hansmi diff -r ff637a82e85f -r 01dcb223833a audacious/playlist.c --- a/audacious/playlist.c Sun Jul 16 08:50:00 2006 -0700 +++ b/audacious/playlist.c Sun Jul 16 09:11:31 2006 -0700 @@ -107,6 +107,7 @@ static gint playlist_compare_title(PlaylistEntry * a, PlaylistEntry * b); static gint playlist_compare_artist(PlaylistEntry * a, PlaylistEntry * b); static gint playlist_compare_date(PlaylistEntry * a, PlaylistEntry * b); +static gint playlist_compare_track(PlaylistEntry * a, PlaylistEntry * b); static gint playlist_dupscmp_path(PlaylistEntry * a, PlaylistEntry * b); static gint playlist_dupscmp_filename(PlaylistEntry * a, PlaylistEntry * b); @@ -117,7 +118,8 @@ playlist_compare_filename, playlist_compare_title, playlist_compare_artist, - playlist_compare_date + playlist_compare_date, + playlist_compare_track }; static void playlist_save_m3u(FILE * file); @@ -1759,6 +1761,19 @@ } static gint +playlist_compare_track(PlaylistEntry * a, + PlaylistEntry * b) +{ + g_return_val_if_fail(a != NULL, 0); + g_return_val_if_fail(b != NULL, 0); + + g_return_val_if_fail(a->tuple != NULL, 0); + g_return_val_if_fail(b->tuple != NULL, 0); + + return (a->tuple->track_number - b->tuple->track_number); +} + +static gint playlist_compare_title(PlaylistEntry * a, PlaylistEntry * b) { diff -r ff637a82e85f -r 01dcb223833a audacious/playlist.h --- a/audacious/playlist.h Sun Jul 16 08:50:00 2006 -0700 +++ b/audacious/playlist.h Sun Jul 16 09:11:31 2006 -0700 @@ -33,7 +33,8 @@ PLAYLIST_SORT_FILENAME, PLAYLIST_SORT_TITLE, PLAYLIST_SORT_ARTIST, - PLAYLIST_SORT_DATE + PLAYLIST_SORT_DATE, + PLAYLIST_SORT_TRACK } PlaylistSortType; typedef enum { diff -r ff637a82e85f -r 01dcb223833a audacious/ui_playlist.c --- a/audacious/ui_playlist.c Sun Jul 16 08:50:00 2006 -0700 +++ b/audacious/ui_playlist.c Sun Jul 16 09:11:31 2006 -0700 @@ -82,7 +82,8 @@ PLAYLISTWIN_SORT_BYARTIST, PLAYLISTWIN_SORT_SEL_BYARTIST, PLAYLISTWIN_SORT_SEL_BYTITLE, PLAYLISTWIN_SORT_SEL_BYFILENAME, PLAYLISTWIN_SORT_SEL_BYPATH, PLAYLISTWIN_SORT_SEL_BYDATE, - PLAYLISTWIN_SORT_RANDOMIZE, PLAYLISTWIN_SORT_REVERSE + PLAYLISTWIN_SORT_RANDOMIZE, PLAYLISTWIN_SORT_REVERSE, + PLAYLISTWIN_SORT_BYTRACK, PLAYLISTWIN_SORT_SEL_BYTRACK }; GtkWidget *playlistwin; @@ -262,6 +263,8 @@ PLAYLISTWIN_SORT_BYPATH, "", sortbypathfile_pixbuf}, {N_("/Sort List/By Date"), NULL, plsort_menu_callback, PLAYLISTWIN_SORT_BYDATE, "", sortbydate_pixbuf}, + {N_("/Sort List/By Track Number"), NULL, plsort_menu_callback, + PLAYLISTWIN_SORT_BYTRACK, "", sortbytitle_pixbuf}, {N_("/Sort Selection"), NULL, NULL, 0, "", NULL}, {N_("/Sort Selection/By Title"), NULL, plsort_menu_callback, PLAYLISTWIN_SORT_SEL_BYTITLE, "", sortbytitle_pixbuf}, @@ -272,7 +275,9 @@ {N_("/Sort Selection/By Path + Filename"), NULL, plsort_menu_callback, PLAYLISTWIN_SORT_SEL_BYPATH, "", sortbypathfile_pixbuf}, {N_("/Sort Selection/By Date"), NULL, plsort_menu_callback, - PLAYLISTWIN_SORT_SEL_BYDATE, "", sortbydate_pixbuf} + PLAYLISTWIN_SORT_SEL_BYDATE, "", sortbydate_pixbuf}, + {N_("/Sort Selection/By Track Number"), NULL, plsort_menu_callback, + PLAYLISTWIN_SORT_SEL_BYTRACK, "", sortbytitle_pixbuf} }; @@ -1850,6 +1855,10 @@ GtkWidget * widget) { switch (action) { + case PLAYLISTWIN_SORT_BYTRACK: + playlist_sort(PLAYLIST_SORT_TRACK); + playlistwin_update_list(); + break; case PLAYLISTWIN_SORT_BYTITLE: playlist_sort(PLAYLIST_SORT_TITLE); playlistwin_update_list(); @@ -1870,6 +1879,10 @@ playlist_sort(PLAYLIST_SORT_FILENAME); playlistwin_update_list(); break; + case PLAYLISTWIN_SORT_SEL_BYTRACK: + playlist_sort_selected(PLAYLIST_SORT_TRACK); + playlistwin_update_list(); + break; case PLAYLISTWIN_SORT_SEL_BYTITLE: playlist_sort_selected(PLAYLIST_SORT_TITLE); playlistwin_update_list();