From 2e5295b3a9dbcdbfd4a67f787b059c4e11ac9a1c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marco=20Trevisan=20=28Trevi=C3=B1o=29?= Date: Fri, 3 May 2019 15:30:42 -0500 Subject: [PATCH] dialog: Use object's set to assign properties We can just assign a properties object to a GObject using the set() method instead of using Object.assign. https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/531 --- js/ui/dialog.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/js/ui/dialog.js b/js/ui/dialog.js index 41a076353..553b81c78 100644 --- a/js/ui/dialog.js +++ b/js/ui/dialog.js @@ -177,8 +177,8 @@ var MessageDialogContent = GObject.registerClass({ let textProps = { ellipsize: Pango.EllipsizeMode.NONE, line_wrap: true }; - Object.assign(this._subtitle.clutter_text, textProps); - Object.assign(this._body.clutter_text, textProps); + this._subtitle.clutter_text.set(textProps); + this._body.clutter_text.set(textProps); if (!params.hasOwnProperty('style_class')) params.style_class = 'message-dialog-main-layout';