[gnome-shell] calendar: Filter out newlines when unexpanded
- From: Florian Müllner <fmuellner src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] calendar: Filter out newlines when unexpanded
- Date: Tue, 10 Mar 2015 22:48:54 +0000 (UTC)
commit b18240370d3ed7159e217197f01b0e06b8030946
Author: Florian Müllner <fmuellner gnome org>
Date: Tue Mar 10 23:36:09 2015 +0100
calendar: Filter out newlines when unexpanded
Enabling line-wrapping of the unexpanded body is not enough to enforce
a single line when the text has embedded newlines, so replace these with
spaces (this is similar to setting ClutterText:single-line-mode, however
that would use a paragraph separator glyph instead).
js/ui/calendar.js | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/js/ui/calendar.js b/js/ui/calendar.js
index 22c0c2c..19d154a 100644
--- a/js/ui/calendar.js
+++ b/js/ui/calendar.js
@@ -1044,7 +1044,7 @@ const Message = new Lang.Class({
setBody: function(text) {
this._bodyText = text;
- this.bodyLabel.setMarkup(text, this._useBodyMarkup);
+ this.bodyLabel.setMarkup(text.replace(/\n/g, ' '), this._useBodyMarkup);
},
setUseBodyMarkup: function(enable) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]