[Rhythmbox-devel] [patch] Remove unused mute codepath



I need to look into that tla thing, but I can't be bothered.
Patch against CVS HEAD.

---
Bastien Nocera <hadess@hadess.net> 
It was a working class tradition, like fathers chasing kids around with
their power tools. 
? Makefile
? Makefile.in
Index: rb-player-gst.c
===================================================================
RCS file: /cvs/gnome/rhythmbox/player/rb-player-gst.c,v
retrieving revision 1.22
diff -u -r1.22 rb-player-gst.c
--- rb-player-gst.c	22 Mar 2004 22:49:51 -0000	1.22
+++ rb-player-gst.c	24 Mar 2004 17:19:08 -0000
@@ -74,7 +74,6 @@
 
 	GstDParam *volume_dparam;
 	float cur_volume;
-	gboolean mute;
 
 	GTimer *timer;
 	long timer_add;
@@ -549,9 +548,6 @@
 	g_object_set (G_OBJECT (mp->priv->volume_dparam),
 		      "value_double", mp->priv->cur_volume,
 		      NULL);
-	g_object_set (G_OBJECT (mp->priv->volume),
-		      "mute", mp->priv->mute,
-		      NULL);
 
 	if (mp->priv->timer)
 		g_timer_destroy (mp->priv->timer);
@@ -881,30 +877,6 @@
 	return mp->priv->cur_volume;
 }
 
-void
-rb_player_set_mute (RBPlayer *mp,
-			      gboolean mute)
-{
-	g_return_if_fail (RB_IS_PLAYER (mp));
-
-	if (mp->priv->pipeline != NULL)
-		g_object_set (G_OBJECT (mp->priv->volume),
-			      "mute",
-			      mute,
-			      NULL);
-	else
-
-	mp->priv->mute = mute;
-}
-
-gboolean
-rb_player_get_mute (RBPlayer *mp)
-{
-	g_return_val_if_fail (RB_IS_PLAYER (mp), FALSE);
-
-	return mp->priv->mute;
-}
-
 gboolean
 rb_player_seekable (RBPlayer *mp)
 {
Index: rb-player-xine.c
===================================================================
RCS file: /cvs/gnome/rhythmbox/player/rb-player-xine.c,v
retrieving revision 1.8
diff -u -r1.8 rb-player-xine.c
--- rb-player-xine.c	22 Mar 2004 22:49:51 -0000	1.8
+++ rb-player-xine.c	24 Mar 2004 17:19:08 -0000
@@ -51,7 +51,6 @@
 	char *configfile;
 
 	float volume;
-	gboolean mute;
 
 	GTimer *timer;
 	long timer_add;
@@ -601,10 +600,8 @@
 		if (can_set_volume (mp) == FALSE)
 			return;
 
-		if (!mp->priv->mute) {
-			xine_set_param (mp->priv->stream, XINE_PARAM_AUDIO_AMP_LEVEL,
-					CLAMP (volume * 100, 0, 100));
-		}
+		xine_set_param (mp->priv->stream, XINE_PARAM_AUDIO_AMP_LEVEL,
+				CLAMP (volume * 100, 0, 100));
 	}
 
 	mp->priv->volume = volume;
@@ -618,34 +615,6 @@
 	return mp->priv->volume;
 }
 
-void
-rb_player_set_mute (RBPlayer *mp,
-			      gboolean mute)
-{
-	g_return_if_fail (RB_IS_PLAYER (mp));
-
-	if (mp->priv->stream != NULL) {
-		if (can_set_volume (mp) == FALSE)
-			return;
-
-		if (mute)
-			xine_set_param (mp->priv->stream, XINE_PARAM_AUDIO_VOLUME, 0);
-		else
-			xine_set_param (mp->priv->stream, XINE_PARAM_AUDIO_VOLUME,
-					CLAMP (mp->priv->volume * 100, 0, 100));
-	}
-
-	mp->priv->mute = mute;
-}
-
-gboolean
-rb_player_get_mute (RBPlayer *mp)
-{
-	g_return_val_if_fail (RB_IS_PLAYER (mp), FALSE);
-
-	return mp->priv->mute;
-}
-
 gboolean
 rb_player_seekable (RBPlayer *mp)
 {
Index: rb-player.h
===================================================================
RCS file: /cvs/gnome/rhythmbox/player/rb-player.h,v
retrieving revision 1.7
diff -u -r1.7 rb-player.h
--- rb-player.h	22 Mar 2004 22:49:51 -0000	1.7
+++ rb-player.h	24 Mar 2004 17:19:09 -0000
@@ -101,11 +101,6 @@
 void		rb_player_set_replaygain (RBPlayer *mp,
 					  double track_gain, double track_peak, double album_gain, double album_peak);
 
-void		rb_player_set_mute   (RBPlayer *mp,
-				      gboolean mute);
-
-gboolean	rb_player_get_mute   (RBPlayer *mp);
-
 gboolean	rb_player_seekable   (RBPlayer *mp);
 
 void		rb_player_set_time   (RBPlayer *mp,


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]