aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--shell/ChangeLog7
-rw-r--r--shell/e-shell-view.c18
2 files changed, 22 insertions, 3 deletions
diff --git a/shell/ChangeLog b/shell/ChangeLog
index 7e1d538d40..d77aef13ff 100644
--- a/shell/ChangeLog
+++ b/shell/ChangeLog
@@ -1,3 +1,10 @@
+2000-08-29 Ettore Perazzoli <ettore@helixcode.com>
+
+ * e-shell-view.c (shell_view_interface_set_message_cb): If the
+ message contains a newline, only display the part until the
+ newline, excluding the newline. Otherwise the status bar resizes
+ nastily.
+
2000-08-28 Ettore Perazzoli <ettore@helixcode.com>
* e-shell.c (setup_components): Removed the hardcoding of the
diff --git a/shell/e-shell-view.c b/shell/e-shell-view.c
index be0845da32..3a7f838d3b 100644
--- a/shell/e-shell-view.c
+++ b/shell/e-shell-view.c
@@ -694,10 +694,22 @@ shell_view_interface_set_message_cb (EvolutionShellView *shell_view,
gtk_progress_set_value (GTK_PROGRESS (app_bar->progress), 1.0);
- if (message != NULL)
- gnome_appbar_set_status (app_bar, message);
- else
+ if (message != NULL) {
+ const char *newline;
+
+ newline = strchr (message, '\n');
+ if (newline == NULL) {
+ gnome_appbar_set_status (app_bar, message);
+ } else {
+ char *message_until_newline;
+
+ message_until_newline = g_strndup (message, newline - message);
+ gnome_appbar_set_status (app_bar, message_until_newline);
+ g_free (message_until_newline);
+ }
+ } else {
gnome_appbar_set_status (app_bar, "");
+ }
if (busy)
start_progress_bar (E_SHELL_VIEW (data));