Removed unnecessary static function _set_variant soc.2013.gobjectification

Sun, 17 Nov 2013 15:27:37 +0530

author
Ankit Vani <a@nevitus.org>
date
Sun, 17 Nov 2013 15:27:37 +0530
branch
soc.2013.gobjectification
changeset 35064
995be3523e7c
parent 35063
8ac1510a27ae
child 35065
2fe1b3f20c3c

Removed unnecessary static function _set_variant

pidgin/gtkconv-theme.c file | annotate | diff | comparison | revisions
--- a/pidgin/gtkconv-theme.c	Sun Nov 17 04:17:23 2013 +0530
+++ b/pidgin/gtkconv-theme.c	Sun Nov 17 15:27:37 2013 +0530
@@ -394,30 +394,6 @@
 	return priv->outgoing_next_context_html;
 }
 
-static void
-_set_variant(PidginConvTheme *theme, const char *variant)
-{
-	PidginConvThemePrivate *priv;
-	const GValue *val;
-	char *prefname;
-
-	g_return_if_fail(theme != NULL);
-	g_return_if_fail(variant != NULL);
-
-	priv = PIDGIN_CONV_THEME_GET_PRIVATE(theme);
-
-	g_free(priv->variant);
-	priv->variant = g_strdup(variant);
-
-	val = get_key(priv, "CFBundleIdentifier", FALSE);
-	prefname = g_strdup_printf(PIDGIN_PREFS_ROOT "/conversations/themes/%s/variant",
-	                           g_value_get_string(val));
-	purple_prefs_set_string(prefname, variant);
-	g_free(prefname);
-
-	g_object_notify(G_OBJECT(theme), "variant");
-}
-
 /******************************************************************************
  * GObject Stuff
  *****************************************************************************/
@@ -455,7 +431,7 @@
 			break;
 
 		case PROP_VARIANT:
-			_set_variant(theme, g_value_get_string(value));
+			pidgin_conversation_theme_set_variant(theme, g_value_get_string(value));
 			break;
 
 		default:
@@ -712,7 +688,24 @@
 void
 pidgin_conversation_theme_set_variant(PidginConvTheme *theme, const char *variant)
 {
-	_set_variant(theme, variant);
+	PidginConvThemePrivate *priv;
+	const GValue *val;
+	char *prefname;
+
+	g_return_if_fail(theme != NULL);
+	g_return_if_fail(variant != NULL);
+
+	priv = PIDGIN_CONV_THEME_GET_PRIVATE(theme);
+
+	g_free(priv->variant);
+	priv->variant = g_strdup(variant);
+
+	val = get_key(priv, "CFBundleIdentifier", FALSE);
+	prefname = g_strdup_printf(PIDGIN_PREFS_ROOT "/conversations/themes/%s/variant",
+	                           g_value_get_string(val));
+	purple_prefs_set_string(prefname, variant);
+	g_free(prefname);
+
 #if GLIB_CHECK_VERSION(2,26,0)
 	g_object_notify_by_pspec(G_OBJECT(theme), properties[PROP_VARIANT]);
 #else

mercurial