Commit 14d7897a authored by Florian Müllner's avatar Florian Müllner Committed by Georges Basile Stavracas Neto

style: Stop using braces for single-line arrow functions

Braces are optional for single-line arrow functions, but there's a
subtle difference:
Without braces, the expression is implicitly used as return value; with
braces, the function returns nothing unless there's an explicit return.

We currently reflect that in our style by only omitting braces when the
function is expected to have a return value, but that's not very obvious,
not an important differentiation to make, and not easy to express in an
automatic rule.

So just omit braces consistently as mandated by gjs' coding style.

GNOME/gnome-shell!608
parent 1398aa65
Pipeline #92304 passed with stages
in 5 minutes and 22 seconds
......@@ -138,7 +138,7 @@ var AuthPrompt = class {
reactive: true,
can_focus: true,
label: _("Cancel") });
this.cancelButton.connect('clicked', () => { this.cancel(); });
this.cancelButton.connect('clicked', () => this.cancel());
this._buttonBox.add(this.cancelButton,
{ expand: false,
x_fill: false,
......@@ -157,7 +157,7 @@ var AuthPrompt = class {
reactive: true,
can_focus: true,
label: _("Next") });
this.nextButton.connect('clicked', () => { this.emit('next'); });
this.nextButton.connect('clicked', () => this.emit('next'));
this.nextButton.add_style_pseudo_class('default');
this._buttonBox.add(this.nextButton,
{ expand: false,
......
......@@ -259,7 +259,7 @@ var UserList = class {
item.connect('activate', this._onItemActivated.bind(this));
// Try to keep the focused item front-and-center
item.actor.connect('key-focus-in', () => { this.scrollToItem(item); });
item.actor.connect('key-focus-in', () => this.scrollToItem(item));
this._moveFocusToItems();
......@@ -327,7 +327,7 @@ var SessionMenuButton = class {
{ actionMode: Shell.ActionMode.NONE });
this._manager.addMenu(this._menu);
this._button.connect('clicked', () => { this._menu.toggle(); });
this._button.connect('clicked', () => this._menu.toggle());
this._items = {};
this._activeSessionId = null;
......@@ -955,7 +955,7 @@ var LoginDialog = GObject.registerClass({
}
_onSessionOpened(client, serviceName) {
this._authPrompt.finish(() => { this._startSession(serviceName); });
this._authPrompt.finish(() => this._startSession(serviceName));
}
_waitForItemForUser(userName) {
......@@ -973,7 +973,7 @@ var LoginDialog = GObject.registerClass({
hold.release();
});
hold.connect('release', () => { this._userList.disconnect(signalId); });
hold.connect('release', () => this._userList.disconnect(signalId));
return hold;
}
......
......@@ -98,7 +98,7 @@ var Manager = class {
Service(Gio.DBus.system,
'org.freedesktop.realmd',
'/org/freedesktop/realmd',
service => { service.ReleaseRemote(); });
service => service.ReleaseRemote());
this._aggregateProvider.disconnect(this._signalId);
this._realms = { };
this._updateLoginFormat();
......
......@@ -119,7 +119,7 @@ var IBusManager = class {
if (!GLib.str_has_suffix(path, '/InputContext_1'))
this.emit ('focus-in');
});
this._panelService.connect('focus-out', () => { this.emit('focus-out'); });
this._panelService.connect('focus-out', () => this.emit('focus-out'));
try {
// IBus versions older than 1.5.10 have a bug which
......
......@@ -143,26 +143,26 @@ const SystemActions = GObject.registerClass({
this._userManager = AccountsService.UserManager.get_default();
this._userManager.connect('notify::is-loaded',
() => { this._updateMultiUser(); });
() => this._updateMultiUser());
this._userManager.connect('notify::has-multiple-users',
() => { this._updateMultiUser(); });
() => this._updateMultiUser());
this._userManager.connect('user-added',
() => { this._updateMultiUser(); });
() => this._updateMultiUser());
this._userManager.connect('user-removed',
() => { this._updateMultiUser(); });
() => this._updateMultiUser());
this._lockdownSettings.connect('changed::' + DISABLE_USER_SWITCH_KEY,
() => { this._updateSwitchUser(); });
() => this._updateSwitchUser());
this._lockdownSettings.connect('changed::' + DISABLE_LOG_OUT_KEY,
() => { this._updateLogout(); });
() => this._updateLogout());
global.settings.connect('changed::' + ALWAYS_SHOW_LOG_OUT_KEY,
() => { this._updateLogout(); });
() => this._updateLogout());
this._lockdownSettings.connect('changed::' + DISABLE_LOCK_SCREEN_KEY,
() => { this._updateLockScreen(); });
() => this._updateLockScreen());
this._lockdownSettings.connect('changed::' + DISABLE_LOG_OUT_KEY,
() => { this._updateHaveShutdown(); });
() => this._updateHaveShutdown());
this.forceUpdate();
......@@ -172,10 +172,10 @@ const SystemActions = GObject.registerClass({
this._updateOrientationLockIcon();
});
Main.layoutManager.connect('monitors-changed',
() => { this._updateOrientationLock(); });
() => this._updateOrientationLock());
Gio.DBus.system.watch_name(SENSOR_BUS_NAME,
Gio.BusNameWatcherFlags.NONE,
() => { this._sensorProxyAppeared(); },
() => this._sensorProxyAppeared(),
() => {
this._sensorProxy = null;
this._updateOrientationLock();
......@@ -183,7 +183,7 @@ const SystemActions = GObject.registerClass({
this._updateOrientationLock();
this._updateOrientationLockIcon();
Main.sessionMode.connect('updated', () => { this._sessionUpdated(); });
Main.sessionMode.connect('updated', () => this._sessionUpdated());
this._sessionUpdated();
}
......@@ -223,7 +223,7 @@ const SystemActions = GObject.registerClass({
return;
}
this._sensorProxy.connect('g-properties-changed',
() => { this._updateOrientationLock(); });
() => this._updateOrientationLock());
this._updateOrientationLock();
});
}
......@@ -265,7 +265,7 @@ const SystemActions = GObject.registerClass({
getMatchingActions(terms) {
// terms is a list of strings
terms = terms.map((term) => { return term.toLowerCase(); });
terms = terms.map((term) => term.toLowerCase());
let results = [];
......
......@@ -288,7 +288,7 @@ function createTimeLabel(date, params) {
let id = _desktopSettings.connect('changed::clock-format', () => {
label.text = formatTime(date, params);
});
label.connect('destroy', () => { _desktopSettings.disconnect(id); });
label.connect('destroy', () => _desktopSettings.disconnect(id));
return label;
}
......@@ -492,13 +492,13 @@ var AppSettingsMonitor = class {
}
_setSettings(settings) {
this._handlers.forEach((handler) => { this._disconnectHandler(handler); });
this._handlers.forEach((handler) => this._disconnectHandler(handler));
let hadSettings = (this._settings != null);
this._settings = settings;
let haveSettings = (this._settings != null);
this._handlers.forEach((handler) => { this._connectHandler(handler); });
this._handlers.forEach((handler) => this._connectHandler(handler));
if (hadSettings != haveSettings)
this.emit('available-changed');
......
......@@ -68,7 +68,7 @@ var WeatherClient = class {
this._weatherAppMon = new Util.AppSettingsMonitor('org.gnome.Weather.desktop',
'org.gnome.Weather');
this._weatherAppMon.connect('available-changed', () => { this.emit('changed'); });
this._weatherAppMon.connect('available-changed', () => this.emit('changed'));
this._weatherAppMon.watchSetting('automatic-location',
this._onAutomaticLocationChanged.bind(this));
this._weatherAppMon.watchSetting('locations',
......
......@@ -48,7 +48,7 @@ function waitAndDraw(milliseconds) {
cb();
});
return callback => { cb = callback; };
return callback => cb = callback;
}
function waitSignal(object, signal) {
......@@ -60,7 +60,7 @@ function waitSignal(object, signal) {
cb();
});
return callback => { cb = callback; };
return callback => cb = callback;
}
function extractBootTimestamp() {
......
......@@ -264,7 +264,7 @@ class WebPortalHelper extends Gtk.Application {
this._queue = [];
let action = new Gio.SimpleAction({ name: 'quit' });
action.connect('activate', () => { this.active_window.destroyWindow(); });
action.connect('activate', () => this.active_window.destroyWindow());
this.add_action(action);
}
......
......@@ -146,7 +146,7 @@ var AccessDialogDBus = class {
subtitle, body, options);
dialog.open();
dialog.connect('closed', () => { this._accessDialog = null; });
dialog.connect('closed', () => this._accessDialog = null);
this._accessDialog = dialog;
}
......
......@@ -395,7 +395,7 @@ class AppSwitcherPopup extends SwitcherPopup.SwitcherPopup {
{ opacity: 255,
time: THUMBNAIL_FADE_TIME,
transition: 'easeOutQuad',
onComplete: () => { this.thumbnailsVisible = true; }
onComplete: () => this.thumbnailsVisible = true
});
this._switcherList._items[this._selectedIndex].add_accessible_state (Atk.StateType.EXPANDED);
......@@ -843,7 +843,7 @@ class AppSwitcher extends SwitcherPopup.SwitcherList {
});
let arrow = new St.DrawingArea({ style_class: 'switcher-arrow' });
arrow.connect('repaint', () => { SwitcherPopup.drawArrow(arrow, St.Side.BOTTOM); });
arrow.connect('repaint', () => SwitcherPopup.drawArrow(arrow, St.Side.BOTTOM));
this.add_actor(arrow);
this._arrows.push(arrow);
......
......@@ -143,7 +143,7 @@ class BaseAppView {
loadGrid() {
this._allItems.sort(this._compareItems);
this._allItems.forEach(item => { this._grid.addItem(item); });
this._allItems.forEach(item => this._grid.addItem(item));
this.emit('view-loaded');
}
......@@ -212,7 +212,7 @@ class BaseAppView {
} else {
params.opacity = 0;
params.delay = 0;
params.onComplete = () => { this.actor.hide(); };
params.onComplete = () => this.actor.hide();
}
Tweener.addTween(this._grid, params);
......@@ -285,7 +285,7 @@ var AllView = class AllView extends BaseAppView {
this._availWidth = 0;
this._availHeight = 0;
Main.overview.connect('hidden', () => { this.goToPage(0); });
Main.overview.connect('hidden', () => this.goToPage(0));
this._grid.connect('space-opened', () => {
let fadeEffect = this._scrollView.get_effect('fade');
if (fadeEffect)
......@@ -1299,7 +1299,7 @@ var AppFolderPopup = class AppFolderPopup {
global.focus_manager.add_group(this.actor);
source.actor.connect('destroy', () => { this.actor.destroy(); });
source.actor.connect('destroy', () => this.actor.destroy());
this._grabHelper = new GrabHelper.GrabHelper(this.actor, {
actionMode: Shell.ActionMode.POPUP
});
......
......@@ -159,7 +159,7 @@ var AudioDeviceSelectionDBus = class AudioDeviceSelectionDBus {
let [deviceNames] = params;
let devices = 0;
deviceNames.forEach(n => { devices |= AudioDevice[n.toUpperCase()]; });
deviceNames.forEach(n => devices |= AudioDevice[n.toUpperCase()]);
let dialog;
try {
......
......@@ -1072,7 +1072,7 @@ var CalendarMessageList = class CalendarMessageList {
this._clearButton.set_x_align(Clutter.ActorAlign.END);
this._clearButton.connect('clicked', () => {
let sections = [...this._sections.keys()];
sections.forEach((s) => { s.clear(); });
sections.forEach((s) => s.clear());
});
box.add_actor(this._clearButton);
......
......@@ -620,7 +620,7 @@ var NetworkAgent = class {
this._pluginDir = Gio.file_new_for_path(Config.VPNDIR);
try {
let monitor = this._pluginDir.monitor(Gio.FileMonitorFlags.NONE, null);
monitor.connect('changed', () => { this._vpnCacheBuilt = false; });
monitor.connect('changed', () => this._vpnCacheBuilt = false);
} catch (e) {
log('Failed to create monitor for VPN plugin dir: ' + e.message);
}
......
......@@ -32,7 +32,7 @@ var CtrlAltTabManager = class CtrlAltTabManager {
item.iconName = icon;
this._items.push(item);
root.connect('destroy', () => { this.removeGroup(root); });
root.connect('destroy', () => this.removeGroup(root));
if (root instanceof St.Widget)
global.focus_manager.add_group(root);
}
......
......@@ -357,7 +357,7 @@ var MessagesIndicator = class MessagesIndicator {
Main.messageTray.connect('queue-changed', this._updateCount.bind(this));
let sources = Main.messageTray.getSources();
sources.forEach(source => { this._onSourceAdded(null, source); });
sources.forEach(source => this._onSourceAdded(null, source));
}
_onSourceAdded(tray, source) {
......@@ -373,7 +373,7 @@ var MessagesIndicator = class MessagesIndicator {
_updateCount() {
let count = 0;
this._sources.forEach(source => { count += source.unseenCount; });
this._sources.forEach(source => count += source.unseenCount);
count -= Main.messageTray.queueCount;
this.actor.visible = (count > 0);
......@@ -384,8 +384,8 @@ var IndicatorPad = GObject.registerClass(
class IndicatorPad extends St.Widget {
_init(actor) {
this._source = actor;
this._source.connect('notify::visible', () => { this.queue_relayout(); });
this._source.connect('notify::size', () => { this.queue_relayout(); });
this._source.connect('notify::visible', () => this.queue_relayout());
this._source.connect('notify::size', () => this.queue_relayout());
super._init();
}
......
......@@ -16,7 +16,7 @@ var EdgeDragAction = GObject.registerClass({
this._allowedModes = allowedModes;
this.set_n_touch_points(1);
global.display.connect('grab-op-begin', () => { this.cancel(); });
global.display.connect('grab-op-begin', () => this.cancel());
}
_getMonitorRect(x, y) {
......
......@@ -402,7 +402,7 @@ var IconGrid = GObject.registerClass({
}
_cancelAnimation() {
this._clonesAnimating.forEach(clone => { clone.destroy(); });
this._clonesAnimating.forEach(clone => clone.destroy());
this._clonesAnimating = [];
}
......@@ -967,7 +967,7 @@ var PaginatedIconGrid = GObject.registerClass({
transition: 'easeInOutQuad'
};
if (i == (children.length - 1))
params.onComplete = () => { this.emit('space-opened'); };
params.onComplete = () => this.emit('space-opened');
Tweener.addTween(children[i], params);
}
}
......@@ -985,7 +985,7 @@ var PaginatedIconGrid = GObject.registerClass({
{ translation_y: 0,
time: EXTRA_SPACE_ANIMATION_TIME,
transition: 'easeInOutQuad',
onComplete: () => { this.emit('space-closed'); }
onComplete: () => this.emit('space-closed')
});
}
}
......
......@@ -862,7 +862,7 @@ var EmojiSelection = class EmojiSelection {
x_expand: true,
y_expand: true,
vertical: true });
this.actor.connect('notify::mapped', () => { this._emojiPager.setCurrentPage(0); });
this.actor.connect('notify::mapped', () => this._emojiPager.setCurrentPage(0));
this._emojiPager = new EmojiPager(this._sections, 11, 3);
this._emojiPager.connect('page-changed', (pager, section, page, nPages) => {
......@@ -944,14 +944,14 @@ var EmojiSelection = class EmojiSelection {
key = new Key('ABC', []);
key.keyButton.add_style_class_name('default-key');
key.connect('released', () => { this.emit('toggle'); });
key.connect('released', () => this.emit('toggle'));
row.appendKey(key.actor, 1.5);
for (let i = 0; i < this._sections.length; i++) {
let section = this._sections[i];
key = new Key(section.label, []);
key.connect('released', () => { this._emojiPager.setCurrentSection(section, 0); });
key.connect('released', () => this._emojiPager.setCurrentSection(section, 0));
row.appendKey(key.actor);
section.button = key;
......@@ -1171,7 +1171,7 @@ var Keyboard = class Keyboard {
this._emojiSelection = new EmojiSelection();
this._emojiSelection.connect('toggle', this._toggleEmoji.bind(this));
this._emojiSelection.connect('hide', (selection) => { this.hide(); });
this._emojiSelection.connect('hide', (selection) => this.hide());
this._emojiSelection.connect('emoji-selected', (selection, emoji) => {
this._keyboardController.commitString(emoji);
});
......
......@@ -146,8 +146,8 @@ var Notebook = class Notebook {
this.actor.add(scrollview, { expand: true });
let vAdjust = scrollview.vscroll.adjustment;
vAdjust.connect('changed', () => { this._onAdjustScopeChanged(tabData); });
vAdjust.connect('notify::value', () => { this._onAdjustValueChanged(tabData); });
vAdjust.connect('changed', () => this._onAdjustScopeChanged(tabData));
vAdjust.connect('notify::value', () => this._onAdjustValueChanged(tabData));
if (this._selectedIndex == -1)
this.selectIndex(0);
......@@ -1007,7 +1007,7 @@ var LookingGlass = class LookingGlass {
}
_queueResize() {
Meta.later_add(Meta.LaterType.BEFORE_REDRAW, () => { this._resize(); });
Meta.later_add(Meta.LaterType.BEFORE_REDRAW, () => this._resize());
}
_resize() {
......
......@@ -21,7 +21,7 @@ var LevelBar = class extends BarLevel.BarLevel {
this.actor.accessible_name = _("Volume");
this.actor.connect('notify::width', () => { this.level = this.level; });
this.actor.connect('notify::width', () => this.level = this.level);
}
get level() {
......
......@@ -186,7 +186,7 @@ var ActionComboBox = class {
}
setButtonActionsActive(active) {
this._buttonItems.forEach(item => { item.setSensitive(active); });
this._buttonItems.forEach(item => item.setSensitive(active));
}
};
Signals.addSignalMethods(ActionComboBox.prototype);
......
......@@ -862,7 +862,7 @@ class Panel extends St.Widget {
Main.sessionMode.connect('updated', this._updatePanel.bind(this));
global.display.connect('workareas-changed', () => { this.queue_relayout(); });
global.display.connect('workareas-changed', () => this.queue_relayout());
this._updatePanel();
}
......
......@@ -1134,7 +1134,7 @@ class PopupSubMenuMenuItem extends PopupBaseMenuItem {
this.menu = new PopupSubMenu(this, this._triangle);
this.menu.connect('open-state-changed', this._subMenuOpenStateChanged.bind(this));
this.connect('destroy', () => { this.menu.destroy(); });
this.connect('destroy', () => this.menu.destroy());
}
_setParent(parent) {
......
......@@ -34,14 +34,14 @@ class RunDialog extends ModalDialog.ModalDialog {
this._enableInternalCommands = global.settings.get_boolean('development-tools');
this._internalCommands = {
'lg': () => { Main.createLookingGlass().open(); },
'lg': () => Main.createLookingGlass().open(),
'r': this._restart.bind(this),
// Developer brain backwards compatibility
'restart': this._restart.bind(this),
'debugexit': () => { Meta.quit(Meta.ExitCode.ERROR); },
'debugexit': () => Meta.quit(Meta.ExitCode.ERROR),
// rt is short for "reload theme"
'rt': () => {
......
......@@ -529,9 +529,9 @@ var ScreenShield = class {
this._loginManager.getCurrentSessionProxy(sessionProxy => {
this._loginSession = sessionProxy;
this._loginSession.connectSignal('Lock',
() => { this.lock(false); });
() => this.lock(false));
this._loginSession.connectSignal('Unlock',
() => { this.deactivate(false); });
() => this.deactivate(false));
this._loginSession.connect('g-properties-changed', this._syncInhibitor.bind(this));
this._syncInhibitor();
});
......@@ -1177,7 +1177,7 @@ var ScreenShield = class {
deactivate(animate) {
if (this._dialog)
this._dialog.finish(() => { this._continueDeactivate(animate); });
this._dialog.finish(() => this._continueDeactivate(animate));
else
this._continueDeactivate(animate);
}
......
......@@ -162,7 +162,7 @@ function addContextMenu(entry, params) {
_onButtonPressEvent(actor, event, entry);
});
entry.connect('popup-menu', actor => { _onPopup(actor, entry); });
entry.connect('popup-menu', actor => _onPopup(actor, entry));
entry.connect('destroy', () => {
entry.menu.destroy();
......
......@@ -26,7 +26,7 @@ function _setButtonsForChoices(dialog, choices) {
for (let idx = 0; idx < choices.length; idx++) {
let button = idx;
buttons.unshift({ label: choices[idx],
action: () => { dialog.emit('response', button); }
action: () => dialog.emit('response', button)
});
}
......
......@@ -875,7 +875,7 @@ class InputSourceIndicator extends PanelMenu.Button {
let is = this._inputSourceManager.inputSources[i];
let menuItem = new LayoutMenuItem(is.displayName, is.shortName);
menuItem.connect('activate', () => { is.activate(true); });
menuItem.connect('activate', () => is.activate(true));
let indicatorLabel = new St.Label({ text: is.shortName,
visible: false });
......
......@@ -270,7 +270,7 @@ var NMConnectionSection = class NMConnectionSection {
if (!item)
return;
item.connect('icon-changed', () => { this._iconChanged(); });
item.connect('icon-changed', () => this._iconChanged());
item.connect('activation-failed', (item, reason) => {
this.emit('activation-failed', reason);
});
......@@ -630,9 +630,9 @@ var NMWirelessDialogItem = GObject.registerClass({
can_focus: true,
reactive: true });
this.connect('key-focus-in', () => { this.emit('selected'); });
this.connect('key-focus-in', () => this.emit('selected'));
let action = new Clutter.ClickAction();
action.connect('clicked', () => { this.grab_key_focus(); });
action.connect('clicked', () => this.grab_key_focus());
this.add_action(action);
let title = ssidToLabel(this._ap.get_ssid());
......@@ -1675,7 +1675,7 @@ var NMApplet = class extends PanelMenu.SystemIndicator {
'network-transmit-receive');
this._source.policy = new MessageTray.NotificationApplicationPolicy('gnome-network-panel');
this._source.connect('destroy', () => { this._source = null; });
this._source.connect('destroy', () => this._source = null);
Main.messageTray.add(this._source);
}
}
......
......@@ -15,13 +15,13 @@ var AltSwitcher = class {
this._standard.connect('notify::visible', this._sync.bind(this));
if (this._standard instanceof St.Button)
this._standard.connect('clicked',
() => { this._clickAction.release(); });
() => this._clickAction.release());
this._alternate = alternate;
this._alternate.connect('notify::visible', this._sync.bind(this));
if (this._alternate instanceof St.Button)
this._alternate.connect('clicked',
() => { this._clickAction.release(); });
() => this._clickAction.release());
this._capturedEventId = global.stage.connect('captured-event', this._onCapturedEvent.bind(this));
......@@ -32,7 +32,7 @@ var AltSwitcher = class {
this.actor = new St.Bin();
this.actor.connect('destroy', this._onDestroy.bind(this));
this.actor.connect('notify::mapped', () => { this._flipped = false; });
this.actor.connect('notify::mapped', () => this._flipped = false);
}
_sync() {
......@@ -117,9 +117,9 @@ var Indicator = class extends PanelMenu.SystemIndicator {
this._createSubMenu();
this._loginScreenItem.connect('notify::visible',
() => { this._updateMultiUser(); });
() => this._updateMultiUser());
this._logoutItem.connect('notify::visible',
() => { this._updateMultiUser(); });
() => this._updateMultiUser());
// Whether shutdown is available or not depends on both lockdown
// settings (disable-log-out) and Polkit policy - the latter doesn't
// notify, so we update the menu item each time the menu opens or
......@@ -303,13 +303,13 @@ var Indicator = class extends PanelMenu.SystemIndicator {
this._settingsAction.connect('notify::visible',
() => { this._updateActionsVisibility(); });
() => this._updateActionsVisibility());
this._orientationLockAction.connect('notify::visible',
() => { this._updateActionsVisibility(); });
() => this._updateActionsVisibility());
this._lockScreenAction.connect('notify::visible',
() => { this._updateActionsVisibility(); });
() => this._updateActionsVisibility());
this._altSwitcher.actor.connect('notify::visible',
() => { this._updateActionsVisibility(); });
() => this._updateActionsVisibility());
}
_onSettingsClicked() {
......
......@@ -259,7 +259,7 @@ var Indicator = class extends PanelMenu.SystemIndicator {
if (!this._source) {
this._source = new MessageTray.Source(_("Thunderbolt"),
'thunderbolt-symbolic');
this._source.connect('destroy', () => { this._source = null; });
this._source.connect('destroy', () => this._source = null);
Main.messageTray.add(this._source);
}
......
......@@ -392,7 +392,7 @@ var SwitcherList = GObject.registerClass({
this._list.add_actor(bbox);
let n = this._items.length;
bbox.connect('clicked', () => { this._onItemClicked(n); });
bbox.connect('clicked', () => this._onItemClicked(n));
bbox.connect('motion-event', () => this._onItemEnter(n));
bbox.label_actor = label;
......
......@@ -43,7 +43,7 @@ function _wrapTweening(target, tweeningParameters) {
state.destroyedId = target.connect('destroy', _actorDestroyed);
} else if (target.actor && target.actor instanceof Clutter.Actor) {
state.actor = target.actor;
state.destroyedId = target.actor.connect('destroy', () => { _actorDestroyed(target); });
state.destroyedId = target.actor.connect('destroy', () => _actorDestroyed(target));
}
}
......@@ -86,7 +86,7 @@ function _addHandler(target, params, name, handler) {
handler(target);
};
} else {
params[name] = () => { handler(target); };
params[name] = () => handler(target);
}
}
......