changeset 32398:544e6ed9d850

The function gst_msg_db_to_percent already retyrns a number between 0.0 and 1.0, and a GtkProgressBar is between 0.0 and 1.0, so I don't know why the level is multiplied by 5. Maybe microphones aren't that loud? I expect the "volume" control to increase it, so I'm not so sure. I guess we'll see what people think. Fixes #14426.
author Elliott Sales de Andrade <qulogic@pidgin.im>
date Thu, 22 Dec 2011 04:27:59 +0000
parents 9e9eb3cd5677
children 0c23f5856806
files pidgin/gtkmedia.c pidgin/plugins/vvconfig.c
diffstat 2 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/pidgin/gtkmedia.c	Thu Dec 22 03:09:12 2011 +0000
+++ b/pidgin/gtkmedia.c	Thu Dec 22 04:27:59 2011 +0000
@@ -455,7 +455,7 @@
 		progress = pidgin_media_get_widget(gtkmedia, session_id, participant);
 
 	if (progress)
-		gtk_progress_bar_set_fraction(GTK_PROGRESS_BAR(progress), level * 5);
+		gtk_progress_bar_set_fraction(GTK_PROGRESS_BAR(progress), level);
 }
 
 
--- a/pidgin/plugins/vvconfig.c	Thu Dec 22 03:09:12 2011 +0000
+++ b/pidgin/plugins/vvconfig.c	Thu Dec 22 04:27:59 2011 +0000
@@ -612,7 +612,7 @@
 			GstElement *valve;
 
 			percent = gst_msg_db_to_percent(msg, "rms");
-			gtk_progress_bar_set_fraction(ctx->level, percent * 5);
+			gtk_progress_bar_set_fraction(ctx->level, percent);
 
 			percent = gst_msg_db_to_percent(msg, "decay");
 			threshold = gtk_range_get_value(ctx->threshold) / 100.0;