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
This commit is contained in:
Marco Trevisan (Treviño) 2019-05-03 15:30:42 -05:00
parent 3121c9aa29
commit 2e5295b3a9

View File

@ -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';