From ec725cc6d4d56868ad973580d60cfe501080826f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20M=C3=BCllner?= Date: Sat, 20 Feb 2010 22:08:54 +0100 Subject: [PATCH] [Notification] Replace all newlines in body with spaces Accidentally we only replaced the first newline of the body text with spaces - replace all occurrences instead. https://bugzilla.gnome.org/show_bug.cgi?id=610549 --- js/ui/messageTray.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/js/ui/messageTray.js b/js/ui/messageTray.js index 06dd250bb..188a55fb2 100644 --- a/js/ui/messageTray.js +++ b/js/ui/messageTray.js @@ -116,7 +116,7 @@ Notification.prototype = { y_fill: false }); this._titleLabel = new St.Label(); - title = title ? _cleanMarkup(title.replace('\n', ' ')) : ''; + title = title ? _cleanMarkup(title.replace(/\n/g, ' ')) : ''; this._titleLabel.clutter_text.set_markup('' + title + ''); this._bannerBox.add_actor(this._titleLabel); @@ -126,7 +126,7 @@ Notification.prototype = { this._bannerBodyText = null; this._bannerLabel = new St.Label(); - banner = banner ? _cleanMarkup(banner.replace('\n', ' ')) : ''; + banner = banner ? _cleanMarkup(banner.replace(/\n/g, ' ')) : ''; this._bannerLabel.clutter_text.set_markup(banner); this._bannerBox.add_actor(this._bannerLabel); },