Mercurial > hg > xmms-sid
diff src/xs_fileinfo.c @ 234:6f9764fbd693
Make the slider in fileinfo window's subtune selector work as expected.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Tue, 21 Dec 2004 13:34:00 +0000 |
parents | e613873c3379 |
children | 7833df935239 |
line wrap: on
line diff
--- a/src/xs_fileinfo.c Tue Dec 21 13:32:04 2004 +0000 +++ b/src/xs_fileinfo.c Tue Dec 21 13:34:00 2004 +0000 @@ -76,6 +76,20 @@ void xs_fileinfo_setsong(void) { + gint n; + + XS_MUTEX_LOCK(xs_status); + XS_MUTEX_LOCK(xs_fileinfowin); + + if (xs_status.tuneInfo && xs_status.isPlaying) + { + n = gtk_range_get_adjustment(GTK_RANGE(LUW("fileinfo_subctrl_adj")))->value; + if ((n >= 1) && (n <= xs_status.tuneInfo->nsubTunes)) + xs_status.currSong = n; + } + + XS_MUTEX_UNLOCK(xs_fileinfowin); + XS_MUTEX_UNLOCK(xs_status); }