[gnome-packagekit] Put the newline on the tooltip in the right place



commit 67f3185e89121c7e81b37d85376d31fb993c2918
Author: Richard Hughes <richard hughsie com>
Date:   Wed Jul 29 14:29:40 2009 +0100

    Put the newline on the tooltip in the right place

 src/gpk-watch.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/src/gpk-watch.c b/src/gpk-watch.c
index 05a929b..7b66165 100644
--- a/src/gpk-watch.c
+++ b/src/gpk-watch.c
@@ -200,13 +200,14 @@ gpk_watch_refresh_tooltip (GpkWatch *watch)
 		text = gpk_watch_get_restart_required_tooltip (watch);
 		if (text != NULL) {
 			g_string_append (status, text);
-			g_string_append_c (status, '\n');
 		}
 		g_free (text);
 
 		/* do we have any cached messages to show? */
 		len = watch->priv->cached_messages->len;
 		if (len > 0) {
+			if (status->len > 0)
+				g_string_append_c (status, '\n');
 			g_string_append_printf (status, ngettext ("%i message from the package manager",
 								  "%i messages from the package manager", len), len);
 			goto out;



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