summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSeemant Kulleen <seemant@gentoo.org>2003-09-15 11:26:16 +0000
committerSeemant Kulleen <seemant@gentoo.org>2003-09-15 11:26:16 +0000
commit7b88d1f1a83ca0fa5bad66a0f526a7ac39ff51b6 (patch)
tree99dccabf65066f0c8f5ac5b3abb67d3463fd6ec6
parentsongpos patch for sid (diff)
downloadhistorical-7b88d1f1a83ca0fa5bad66a0f526a7ac39ff51b6.tar.gz
historical-7b88d1f1a83ca0fa5bad66a0f526a7ac39ff51b6.tar.bz2
historical-7b88d1f1a83ca0fa5bad66a0f526a7ac39ff51b6.zip
songpos patch for sid
-rw-r--r--media-sound/xmms/Manifest4
-rw-r--r--media-sound/xmms/files/digest-xmms-1.2.8-r22
-rw-r--r--media-sound/xmms/files/xmms-1.2.8-sid-songpos.patch267
-rw-r--r--media-sound/xmms/xmms-1.2.8-r2.ebuild26
4 files changed, 291 insertions, 8 deletions
diff --git a/media-sound/xmms/Manifest b/media-sound/xmms/Manifest
index 3f0efc3739e1..122c87491a67 100644
--- a/media-sound/xmms/Manifest
+++ b/media-sound/xmms/Manifest
@@ -1,10 +1,10 @@
MD5 67719e9afde51fc778b8882f48bebfc2 xmms-1.2.7-r23.ebuild 5233
-MD5 ded3faed072266be9d77b0748586c9dd xmms-1.2.8-r2.ebuild 4562
+MD5 6f4853e90e0793f41491fbd7b918d03f xmms-1.2.8-r2.ebuild 4554
MD5 1f4fb5fbbf7591ead0b68071825b2de3 xmms-1.2.7-r25.ebuild 5652
MD5 5013cb7f0010b3daa8efd1548cbe83b4 xmms-1.2.7-r20.ebuild 4923
MD5 0ee64fc05669ecd516d7239e2a575e8d xmms-1.2.8.ebuild 4350
MD5 092d1ae9348717c6e29072cbc747275e xmms-1.2.8-r1.ebuild 3813
-MD5 38ca2ceb36200852f771cbce7268d40f ChangeLog 12795
+MD5 ed84808c74e1eaee0d3538fdd0caf353 ChangeLog 13090
MD5 a1eaeb2ae801daeb712c90c060e922dc metadata.xml 158
MD5 e7e0c91780b115aaad1a1ed534bf7ae8 files/xmms-ipv6-20020408-mmx.patch 9210
MD5 2ef620caed6093dff90ace3118832937 files/xmms-1.2.8-sid-songpos.patch 8959
diff --git a/media-sound/xmms/files/digest-xmms-1.2.8-r2 b/media-sound/xmms/files/digest-xmms-1.2.8-r2
index 737c2f506433..2255674abb75 100644
--- a/media-sound/xmms/files/digest-xmms-1.2.8-r2
+++ b/media-sound/xmms/files/digest-xmms-1.2.8-r2
@@ -1,2 +1,2 @@
MD5 d523735b59232f0eedd45dc2b7a4f5ad xmms-1.2.8.tar.bz2 2322808
-MD5 a68edd5b03d650c366f09852a8414ee2 gentoo_ice.zip 68458
+MD5 41eababfa8bad11e9e34e467cdfb86be gentoo_ice-xmms-0.2.tar.bz2 51839
diff --git a/media-sound/xmms/files/xmms-1.2.8-sid-songpos.patch b/media-sound/xmms/files/xmms-1.2.8-sid-songpos.patch
new file mode 100644
index 000000000000..c3050cec89da
--- /dev/null
+++ b/media-sound/xmms/files/xmms-1.2.8-sid-songpos.patch
@@ -0,0 +1,267 @@
+
+Only in xmms-1.2.8-patched/Input/mpg123: mpg123.c~
+diff -r -u xmms-1.2.8/libxmms/xmmsctrl.c xmms-1.2.8-patched/libxmms/xmmsctrl.c
+--- xmms-1.2.8/libxmms/xmmsctrl.c Sun Mar 3 21:24:27 2002
++++ xmms-1.2.8-patched/libxmms/xmmsctrl.c Sat Jun 1 17:27:31 2002
+@@ -421,6 +421,11 @@
+ remote_send_guint32(session, CMD_JUMP_TO_TIME, pos);
+ }
+
++void xmms_remote_seek(gint session, gint off)
++{
++ remote_send_guint32(session, CMD_SEEK, off);
++}
++
+ void xmms_remote_get_volume(gint session, gint * vl, gint * vr)
+ {
+ ServerPktHeader pkt_hdr;
+Only in xmms-1.2.8-patched/libxmms: xmmsctrl.c~
+diff -r -u xmms-1.2.8/libxmms/xmmsctrl.h xmms-1.2.8-patched/libxmms/xmmsctrl.h
+--- xmms-1.2.8/libxmms/xmmsctrl.h Sun Mar 3 21:24:27 2002
++++ xmms-1.2.8-patched/libxmms/xmmsctrl.h Sat Jun 1 17:27:31 2002
+@@ -42,6 +42,7 @@
+ void xmms_remote_playlist_clear(gint session);
+ gint xmms_remote_get_output_time(gint session);
+ void xmms_remote_jump_to_time(gint session, gint pos);
++void xmms_remote_seek(gint session, gint off);
+ void xmms_remote_get_volume(gint session, gint * vl, gint * vr);
+ gint xmms_remote_get_main_volume(gint session);
+ gint xmms_remote_get_balance(gint session);
+Only in xmms-1.2.8-patched/libxmms: xmmsctrl.h~
+diff -r -u xmms-1.2.8/xmms/controlsocket.c xmms-1.2.8-patched/xmms/controlsocket.c
+--- xmms-1.2.8/xmms/controlsocket.c Sun Mar 3 21:24:33 2002
++++ xmms-1.2.8-patched/xmms/controlsocket.c Sat Jun 1 17:28:51 2002
+@@ -493,6 +493,10 @@
+ num < playlist_get_current_length())
+ input_seek(num / 1000);
+ break;
++ case CMD_SEEK:
++ num = *((guint32 *) data);
++ song_seek(num);
++ break;
+ case CMD_SET_VOLUME:
+ v[0] = ((guint32 *) data)[0];
+ v[1] = ((guint32 *) data)[1];
+diff -r -u xmms-1.2.8/xmms/controlsocket.h xmms-1.2.8-patched/xmms/controlsocket.h
+--- xmms-1.2.8/xmms/controlsocket.h Sun Mar 3 21:24:33 2002
++++ xmms-1.2.8-patched/xmms/controlsocket.h Sat Jun 1 17:27:31 2002
+@@ -33,7 +33,7 @@
+ CMD_GET_VERSION, CMD_PLAYLIST_ADD, CMD_PLAY, CMD_PAUSE, CMD_STOP,
+ CMD_IS_PLAYING, CMD_IS_PAUSED, CMD_GET_PLAYLIST_POS,
+ CMD_SET_PLAYLIST_POS, CMD_GET_PLAYLIST_LENGTH, CMD_PLAYLIST_CLEAR,
+- CMD_GET_OUTPUT_TIME, CMD_JUMP_TO_TIME, CMD_GET_VOLUME,
++ CMD_GET_OUTPUT_TIME, CMD_JUMP_TO_TIME, CMD_SEEK, CMD_GET_VOLUME,
+ CMD_SET_VOLUME, CMD_GET_SKIN, CMD_SET_SKIN, CMD_GET_PLAYLIST_FILE,
+ CMD_GET_PLAYLIST_TITLE, CMD_GET_PLAYLIST_TIME, CMD_GET_INFO,
+ CMD_GET_EQ_DATA, CMD_SET_EQ_DATA, CMD_PL_WIN_TOGGLE,
+diff -r -u xmms-1.2.8/xmms/input.c xmms-1.2.8-patched/xmms/input.c
+--- xmms-1.2.8/xmms/input.c Wed Jul 11 14:19:23 2001
++++ xmms-1.2.8-patched/xmms/input.c Sat Jun 1 17:27:31 2002
+@@ -306,6 +306,7 @@
+ }
+ }
+ ip_data->playing = FALSE;
++ set_song_position(0, 0, 0);
+ }
+
+ void input_pause(void)
+diff -r -u xmms-1.2.8/xmms/main.c xmms-1.2.8-patched/xmms/main.c
+--- xmms-1.2.8/xmms/main.c Wed Feb 27 15:30:28 2002
++++ xmms-1.2.8-patched/xmms/main.c Sat Jun 1 17:28:05 2002
+@@ -680,6 +680,55 @@
+ g_free(filename);
+ }
+
++/*\
++|*| Separate song position stuff, for songs without a time length,
++|*| but that want to be able to seek anyway.
++|*|
++|*| Have the input plugin's get_time() function call
++|*| set_song_position(int pos, int first, int last)
++|*| to set the slider. If the slider is dragged,
++|*| the plugin's seek() is called with the position.
++|*| (If last <= first the feature is turned off)
++\*/
++
++static int song_pos_cur, song_pos_first, song_pos_num = 0;
++
++void set_song_position(int pos, int first, int last)
++{
++ last -= first;
++ song_pos_cur = pos;
++ song_pos_first = first;
++ song_pos_num = last;
++ if (last <= 0) return;
++ pos -= first;
++ if (pos > last) pos = last;
++ if (cfg.player_shaded)
++ show_widget(mainwin_sposition);
++ show_widget(mainwin_position);
++ hslider_set_position(mainwin_position, (pos * 219) / last);
++ hslider_set_position(mainwin_sposition, ((pos * 12) / last) + 1);
++}
++
++void song_seek(gint off)
++{
++ if (!get_input_playing()) return;
++ if (song_pos_num > 0) {
++ gint newpos = 0;
++ if (off < 0) newpos = song_pos_cur - 1;
++ else if (off > 0) newpos = song_pos_cur + 1;
++ if (newpos < song_pos_first) newpos = song_pos_first;
++ if (newpos > song_pos_first + song_pos_num)
++ newpos = song_pos_first + song_pos_num;
++ input_seek(newpos);
++ } else {
++ gint newpos = (input_get_time() / 1000) + (off / 1000);
++ gint pcl = playlist_get_current_length() / 1000;
++ if (newpos >= pcl) newpos = pcl - 1;
++ if (newpos < 0) newpos = 0;
++ input_seek(newpos);
++ }
++}
++
+ gchar *xmms_get_gentitle_format(void)
+ {
+ return cfg.gentitle_format;
+@@ -760,7 +808,9 @@
+ show_widget(mainwin_stime_min);
+ show_widget(mainwin_stime_sec);
+
+- if (get_input_playing() && playlist_get_current_length() != -1)
++ if (get_input_playing() &&
++ ((playlist_get_current_length() != -1) ||
++ (song_pos_num > 0)))
+ show_widget(mainwin_sposition);
+
+ mainwin_shade->pb_ny = mainwin_shade->pb_py = 27;
+@@ -1056,7 +1106,7 @@
+ show_widget(mainwin_sec_num);
+ if (!get_input_paused())
+ playstatus_set_status(mainwin_playstatus, STATUS_PLAY);
+- if (playlist_get_current_length() != -1)
++ if ((playlist_get_current_length() != -1) || (song_pos_num > 0))
+ {
+ if (cfg.player_shaded)
+ show_widget(mainwin_sposition);
+@@ -1352,13 +1416,19 @@
+ break;
+ case GDK_Left:
+ case GDK_KP_Left:
++/*
+ if(playlist_get_current_length() != -1)
+ input_seek(CLAMP(input_get_time() - 5000, 0, playlist_get_current_length()) / 1000);
++*/
++ song_seek(-5000);
+ break;
+ case GDK_Right:
+ case GDK_KP_Right:
++/*
+ if(playlist_get_current_length() != -1)
+ input_seek(CLAMP(input_get_time() + 5000, 0, playlist_get_current_length()) / 1000);
++*/
++ song_seek(+5000);
+ break;
+ default:
+ break;
+@@ -1988,6 +2099,16 @@
+
+ pos--;
+
++ if (song_pos_num > 0) {
++ time = ((song_pos_num * pos + 6) / 12) + song_pos_first;
++ tmp = g_strdup_printf("%d", time);
++ textbox_set_text(mainwin_stime_min, tmp);
++ g_free(tmp);
++ tmp = g_strdup_printf("%d", song_pos_first + song_pos_num);
++ textbox_set_text(mainwin_stime_sec, tmp);
++ g_free(tmp);
++ return;
++ }
+ time = ((playlist_get_current_length() / 1000) * pos) / 12;
+ if (cfg.timer_mode == TIMER_REMAINING)
+ {
+@@ -2009,6 +2130,10 @@
+
+ void mainwin_spos_release_cb(gint pos)
+ {
++ if (song_pos_num > 0) {
++ input_seek(((song_pos_num * (pos - 1) + 6) / 12) + song_pos_first);
++ return;
++ }
+ input_seek(((playlist_get_current_length() / 1000) * (pos - 1)) / 12);
+ }
+
+@@ -2017,6 +2142,14 @@
+ gint length, time;
+ gchar *buf;
+
++ if (song_pos_num > 0) {
++ time = ((song_pos_num * pos + 110) / 219) + song_pos_first;
++ buf = g_strdup_printf("JUMP TO: %d/%d", time,
++ song_pos_num + song_pos_first);
++ mainwin_lock_info_text(buf);
++ g_free(buf);
++ return;
++ }
+ length = playlist_get_current_length() / 1000;
+ time = (length * pos) / 219;
+ buf = g_strdup_printf(_("SEEK TO: %d:%-2.2d/%d:%-2.2d (%d%%)"), time / 60, time % 60, length / 60, length % 60, (length != 0) ? (time * 100) / length : 0);
+@@ -2028,6 +2161,12 @@
+ {
+ int length, time;
+
++ if (song_pos_num > 0) {
++ time = ((song_pos_num * pos + 110) / 219) + song_pos_first;
++ input_seek(time);
++ mainwin_release_info_text();
++ return;
++ }
+ length = playlist_get_current_length() / 1000;
+ time = (length * pos) / 219;
+ input_seek(time);
+@@ -2423,12 +2573,10 @@
+ case MAINWIN_GENERAL_STOPFADE:
+ break;
+ case MAINWIN_GENERAL_BACK5SEC:
+- if (get_input_playing() && playlist_get_current_length() != -1)
+- input_seek((((input_get_time() / 1000) - 5 >= 0) ? (input_get_time() / 1000) - 5 : 0));
++ song_seek(-5000);
+ break;
+ case MAINWIN_GENERAL_FWD5SEC:
+- if (get_input_playing() && playlist_get_current_length() != -1)
+- input_seek(((((input_get_time() / 1000) + 5) < (playlist_get_current_length() / 1000)) ? ((input_get_time() / 1000) + 5) : ((playlist_get_current_length() / 1000) - 1)));
++ song_seek(+5000);
+ break;
+ case MAINWIN_GENERAL_START:
+ playlist_set_position(0);
+@@ -3032,7 +3186,7 @@
+ hslider_set_position(mainwin_sposition, ((time * 12) / length) + 1);
+ }
+ }
+- else
++ else if (song_pos_num <= 0)
+ {
+ hslider_set_position(mainwin_position, 0);
+ hslider_set_position(mainwin_sposition, 1);
+diff -r -u xmms-1.2.8/xmms/main.h xmms-1.2.8-patched/xmms/main.h
+--- xmms-1.2.8/xmms/main.h Mon Jan 21 15:22:38 2002
++++ xmms-1.2.8-patched/xmms/main.h Sat Jun 1 17:27:31 2002
+@@ -87,6 +85,7 @@
+ void mainwin_play_pushed(void);
+ void mainwin_stop_pushed(void);
+ void mainwin_eject_pushed(void);
++void song_seek(gint off);
+
+ void mainwin_set_back_pixmap(void);
+
+diff -r -u xmms-1.2.8/xmms/plugin.h xmms-1.2.8-patched/xmms/plugin.h
+--- xmms-1.2.8/xmms/plugin.h Fri Jul 6 21:15:34 2001
++++ xmms-1.2.8-patched/xmms/plugin.h Sat Jun 1 17:27:31 2002
+@@ -154,4 +154,6 @@
+ void (*render_freq)(gint16 freq_data[2][256]); /* Render the freq data, don't do anything time consuming in here */
+ } VisPlugin;
+
++void set_song_position(int pos, int first, int last);
++
+ #endif
diff --git a/media-sound/xmms/xmms-1.2.8-r2.ebuild b/media-sound/xmms/xmms-1.2.8-r2.ebuild
index df2b32241e57..67985e143f95 100644
--- a/media-sound/xmms/xmms-1.2.8-r2.ebuild
+++ b/media-sound/xmms/xmms-1.2.8-r2.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2003 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/media-sound/xmms/xmms-1.2.8-r2.ebuild,v 1.1 2003/09/14 23:05:00 seemant Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-sound/xmms/xmms-1.2.8-r2.ebuild,v 1.2 2003/09/15 11:26:14 seemant Exp $
IUSE="xml nls esd gnome opengl mmx oggvorbis 3dnow mikmod directfb ipv6 cjk"
@@ -10,7 +10,7 @@ filter-flags -fforce-addr -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE
DESCRIPTION="X MultiMedia System"
HOMEPAGE="http://www.xmms.org/"
SRC_URI="http://www.xmms.org/files/1.2.x/${P}.tar.bz2
- mirror://gentoo/gentoo_ice.zip"
+ mirror://gentoo/gentoo_ice-xmms-0.2.tar.bz2"
SLOT="0"
LICENSE="GPL-2"
@@ -30,7 +30,7 @@ RDEPEND="${DEPEND}
nls? ( dev-util/intltool )"
src_unpack() {
- unpack ${P}.tar.bz2
+ unpack ${A}
cd ${S}
# Patch to allow external programmes to have the "jump to" dialog box
@@ -67,6 +67,11 @@ src_unpack() {
# Patch to enable superior randomised playlists:
epatch ${FILESDIR}/${P}-random.patch
+ # This patch changes the search-bar's behaviour when playing
+ # sid tunes using xmms-sid plugin. It enables you to select the
+ # different tunes that are sometimes included in a single .sid file
+ epatch ${FILESDIR}/${P}-sid-songpos.patch
+
export WANT_AUTOCONF_2_5=1
for x in . libxmms ; do
cd ${S}/${x}
@@ -139,6 +144,17 @@ src_install() {
fi
# Add the sexy Gentoo Ice skin
- insinto /usr/share/xmms/Skins
- doins ${DISTDIR}/gentoo_ice.zip
+ insinto /usr/share/xmms/Skins/gentoo_ice
+ doins ${WORKDIR}/gentoo_ice/*
+ docinto gentoo_ice
+ dodoc ${WORKDIR}/README
+}
+
+pkg_postinst() {
+ echo
+ einfo "If you have been using the xmms-sid plugin before,"
+ einfo "it would be a good idea to re-emerge it now, to have"
+ einfo "the additional features introduced by the xmms-songpos patch"
+ einfo "which let's you select one of several tunes sometimes included"
+ einfo "in a single .sid file using the song-position slider."
}