From d34b5030b9b318fcffe38dfc0278d24f0969087b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20M=C3=BCllner?= Date: Thu, 28 Feb 2019 18:38:10 +0100 Subject: [PATCH] style: Use a consistent style for array literals Most array literals already use a four-space indent, except the ones in GObject metainfo and function parameters. Reindent those as well to make the style consistent and bring it closer to gjs' coding style. https://gitlab.gnome.org/GNOME/gnome-shell-extensions/merge_requests/57 --- extensions/auto-move-windows/prefs.js | 9 +++++++-- extensions/places-menu/placeDisplay.js | 14 +++++++++++--- lint/eslintrc-legacy.json | 1 - 3 files changed, 18 insertions(+), 6 deletions(-) diff --git a/extensions/auto-move-windows/prefs.js b/extensions/auto-move-windows/prefs.js index fd448f0b..92c3b053 100644 --- a/extensions/auto-move-windows/prefs.js +++ b/extensions/auto-move-windows/prefs.js @@ -34,8 +34,13 @@ const Widget = GObject.registerClass({ this._changedPermitted = false; this._store = new Gtk.ListStore(); - this._store.set_column_types([Gio.AppInfo, GObject.TYPE_STRING, Gio.Icon, GObject.TYPE_INT, - Gtk.Adjustment]); + this._store.set_column_types([ + Gio.AppInfo, + GObject.TYPE_STRING, + Gio.Icon, + GObject.TYPE_INT, + Gtk.Adjustment + ]); let scrolled = new Gtk.ScrolledWindow({ shadow_type: Gtk.ShadowType.IN }); scrolled.set_policy(Gtk.PolicyType.NEVER, Gtk.PolicyType.AUTOMATIC); diff --git a/extensions/places-menu/placeDisplay.js b/extensions/places-menu/placeDisplay.js index c1302118..79d401de 100644 --- a/extensions/places-menu/placeDisplay.js +++ b/extensions/places-menu/placeDisplay.js @@ -298,9 +298,17 @@ var PlacesManager = class { } _connectVolumeMonitorSignals() { - const signals = ['volume-added', 'volume-removed', 'volume-changed', - 'mount-added', 'mount-removed', 'mount-changed', - 'drive-connected', 'drive-disconnected', 'drive-changed']; + const signals = [ + 'volume-added', + 'volume-removed', + 'volume-changed', + 'mount-added', + 'mount-removed', + 'mount-changed', + 'drive-connected', + 'drive-disconnected', + 'drive-changed' + ]; this._volumeMonitorSignals = []; let func = this._updateMounts.bind(this); diff --git a/lint/eslintrc-legacy.json b/lint/eslintrc-legacy.json index e4b2fb0e..8b716511 100644 --- a/lint/eslintrc-legacy.json +++ b/lint/eslintrc-legacy.json @@ -9,7 +9,6 @@ "CallExpression[callee.object.name=GObject][callee.property.name=registerClass] > ClassExpression:first-child" ], "CallExpression": { "arguments": "first" }, - "ArrayExpression": "first", "ObjectExpression": "first", "MemberExpression": "off" }