cleanup: Remove empty leading/trailing lines in blocks
gjs added a new rule to its eslint ruleset that forbids "block padding", so make sure we conform to that rule before syncing up the configuration. https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1498
This commit is contained in:
parent
7521b9c4b2
commit
8a47f1c667
@ -383,7 +383,6 @@ var ScreencastService = class extends ServiceImplementation {
|
|||||||
this._removeRecorder(sender);
|
this._removeRecorder(sender);
|
||||||
invocation.return_value(GLib.Variant.new('(bs)', returnValue));
|
invocation.return_value(GLib.Variant.new('(bs)', returnValue));
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
log(`Failed to start recorder: ${error.message}`);
|
log(`Failed to start recorder: ${error.message}`);
|
||||||
@ -441,7 +440,6 @@ var ScreencastService = class extends ServiceImplementation {
|
|||||||
this._removeRecorder(sender);
|
this._removeRecorder(sender);
|
||||||
invocation.return_value(GLib.Variant.new('(bs)', returnValue));
|
invocation.return_value(GLib.Variant.new('(bs)', returnValue));
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
log(`Failed to start recorder: ${error.message}`);
|
log(`Failed to start recorder: ${error.message}`);
|
||||||
|
@ -20,7 +20,6 @@ var HistoryManager = class {
|
|||||||
this._history = global.settings.get_strv(this._key);
|
this._history = global.settings.get_strv(this._key);
|
||||||
global.settings.connect(`changed::${this._key}`,
|
global.settings.connect(`changed::${this._key}`,
|
||||||
this._historyChanged.bind(this));
|
this._historyChanged.bind(this));
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
this._history = [];
|
this._history = [];
|
||||||
}
|
}
|
||||||
@ -72,7 +71,6 @@ var HistoryManager = class {
|
|||||||
addItem(input) {
|
addItem(input) {
|
||||||
if (this._history.length == 0 ||
|
if (this._history.length == 0 ||
|
||||||
this._history[this._history.length - 1] != input) {
|
this._history[this._history.length - 1] != input) {
|
||||||
|
|
||||||
this._history = this._history.filter(entry => entry != input);
|
this._history = this._history.filter(entry => entry != input);
|
||||||
this._history.push(input);
|
this._history.push(input);
|
||||||
this._save();
|
this._save();
|
||||||
|
@ -170,7 +170,6 @@ var IntrospectService = class {
|
|||||||
for (let app of apps) {
|
for (let app of apps) {
|
||||||
let windows = app.get_windows();
|
let windows = app.get_windows();
|
||||||
for (let window of windows) {
|
for (let window of windows) {
|
||||||
|
|
||||||
if (!this._isEligibleWindow(window))
|
if (!this._isEligibleWindow(window))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
@ -201,7 +201,6 @@ function removeLiterals(str) {
|
|||||||
// Returns true if there is reason to think that eval(str)
|
// Returns true if there is reason to think that eval(str)
|
||||||
// will modify the global scope
|
// will modify the global scope
|
||||||
function isUnsafeExpression(str) {
|
function isUnsafeExpression(str) {
|
||||||
|
|
||||||
// Check for any sort of assignment
|
// Check for any sort of assignment
|
||||||
// The strategy used is dumb: remove any quotes
|
// The strategy used is dumb: remove any quotes
|
||||||
// or regexs and comparison operators and see if there is an '=' character.
|
// or regexs and comparison operators and see if there is an '=' character.
|
||||||
|
@ -111,6 +111,5 @@ var SmartcardManager = class {
|
|||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
};
|
};
|
||||||
Signals.addSignalMethods(SmartcardManager.prototype);
|
Signals.addSignalMethods(SmartcardManager.prototype);
|
||||||
|
@ -907,7 +907,6 @@ class ThumbnailSwitcher extends SwitcherPopup.SwitcherList {
|
|||||||
} else {
|
} else {
|
||||||
this.addItem(box, null);
|
this.addItem(box, null);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
this.connect('destroy', this._onDestroy.bind(this));
|
this.connect('destroy', this._onDestroy.bind(this));
|
||||||
|
@ -867,7 +867,6 @@ var PageManager = GObject.registerClass({
|
|||||||
|
|
||||||
global.settings.connect('changed::app-picker-layout',
|
global.settings.connect('changed::app-picker-layout',
|
||||||
this._loadPages.bind(this));
|
this._loadPages.bind(this));
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
_loadPages() {
|
_loadPages() {
|
||||||
|
@ -201,7 +201,6 @@ var AutomountManager = class {
|
|||||||
e.message.includes('Failed to activate device: Incorrect passphrase') ||
|
e.message.includes('Failed to activate device: Incorrect passphrase') ||
|
||||||
// cryptsetup returns EINVAL in many cases, including wrong TCRYPT password/parameters
|
// cryptsetup returns EINVAL in many cases, including wrong TCRYPT password/parameters
|
||||||
e.message.includes('Failed to load device\'s parameters: Invalid argument')) {
|
e.message.includes('Failed to load device\'s parameters: Invalid argument')) {
|
||||||
|
|
||||||
this._reaskPassword(volume);
|
this._reaskPassword(volume);
|
||||||
} else {
|
} else {
|
||||||
if (e.message.includes('Compiled against a version of libcryptsetup that does not support the VeraCrypt PIM setting')) {
|
if (e.message.includes('Compiled against a version of libcryptsetup that does not support the VeraCrypt PIM setting')) {
|
||||||
|
@ -238,7 +238,6 @@ var AuthenticationDialog = GObject.registerClass({
|
|||||||
/* Yay, all done */
|
/* Yay, all done */
|
||||||
if (gainedAuthorization) {
|
if (gainedAuthorization) {
|
||||||
this._emitDone(false);
|
this._emitDone(false);
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
/* Unless we are showing an existing error message from the PAM
|
/* Unless we are showing an existing error message from the PAM
|
||||||
* module (the PAM module could be reporting the authentication
|
* module (the PAM module could be reporting the authentication
|
||||||
|
@ -224,7 +224,6 @@ var MessageDialogContent = GObject.registerClass({
|
|||||||
return GLib.SOURCE_REMOVE;
|
return GLib.SOURCE_REMOVE;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
set title(title) {
|
set title(title) {
|
||||||
|
@ -33,8 +33,7 @@ class KbdA11yDialog extends GObject.Object {
|
|||||||
: _("Slow Keys Turned Off");
|
: _("Slow Keys Turned Off");
|
||||||
description = _('You just held down the Shift key for 8 seconds. This is the shortcut ' +
|
description = _('You just held down the Shift key for 8 seconds. This is the shortcut ' +
|
||||||
'for the Slow Keys feature, which affects the way your keyboard works.');
|
'for the Slow Keys feature, which affects the way your keyboard works.');
|
||||||
|
} else if (whatChanged & Clutter.KeyboardA11yFlags.STICKY_KEYS_ENABLED) {
|
||||||
} else if (whatChanged & Clutter.KeyboardA11yFlags.STICKY_KEYS_ENABLED) {
|
|
||||||
key = KEY_STICKY_KEYS_ENABLED;
|
key = KEY_STICKY_KEYS_ENABLED;
|
||||||
enabled = (newFlags & Clutter.KeyboardA11yFlags.STICKY_KEYS_ENABLED) > 0;
|
enabled = (newFlags & Clutter.KeyboardA11yFlags.STICKY_KEYS_ENABLED) > 0;
|
||||||
title = enabled
|
title = enabled
|
||||||
|
@ -205,7 +205,6 @@ var Notebook = GObject.registerClass({
|
|||||||
scrollToBottom(index) {
|
scrollToBottom(index) {
|
||||||
let tabData = this._tabs[index];
|
let tabData = this._tabs[index];
|
||||||
tabData._scrollToBottom = true;
|
tabData._scrollToBottom = true;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
_onAdjustValueChanged(tabData) {
|
_onAdjustValueChanged(tabData) {
|
||||||
|
@ -1656,7 +1656,6 @@ var ZoomRegion = class ZoomRegion {
|
|||||||
var Crosshairs = GObject.registerClass(
|
var Crosshairs = GObject.registerClass(
|
||||||
class Crosshairs extends Clutter.Actor {
|
class Crosshairs extends Clutter.Actor {
|
||||||
_init() {
|
_init() {
|
||||||
|
|
||||||
// Set the group containing the crosshairs to three times the desktop
|
// Set the group containing the crosshairs to three times the desktop
|
||||||
// size in case the crosshairs need to appear to be infinite in
|
// size in case the crosshairs need to appear to be infinite in
|
||||||
// length (i.e., extend beyond the edges of the view they appear in).
|
// length (i.e., extend beyond the edges of the view they appear in).
|
||||||
|
@ -291,7 +291,6 @@ var LabelExpanderLayout = GObject.registerClass({
|
|||||||
if (child.visible)
|
if (child.visible)
|
||||||
child.allocate(box);
|
child.allocate(box);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -673,7 +673,6 @@ var PadOsd = GObject.registerClass({
|
|||||||
// the same group.
|
// the same group.
|
||||||
this._groupPads.splice(this._groupPads.indexOf(device), 1);
|
this._groupPads.splice(this._groupPads.indexOf(device), 1);
|
||||||
this._updatePadChooser();
|
this._updatePadChooser();
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -785,7 +785,6 @@ function getInputSourceManager() {
|
|||||||
|
|
||||||
var InputSourceIndicatorContainer = GObject.registerClass(
|
var InputSourceIndicatorContainer = GObject.registerClass(
|
||||||
class InputSourceIndicatorContainer extends St.Widget {
|
class InputSourceIndicatorContainer extends St.Widget {
|
||||||
|
|
||||||
vfunc_get_preferred_width(forHeight) {
|
vfunc_get_preferred_width(forHeight) {
|
||||||
// Here, and in vfunc_get_preferred_height, we need to query
|
// Here, and in vfunc_get_preferred_height, we need to query
|
||||||
// for the height of all children, but we ignore the results
|
// for the height of all children, but we ignore the results
|
||||||
|
@ -1588,7 +1588,6 @@ var DeviceCategory = class extends PopupMenu.PopupMenuSection {
|
|||||||
this._summaryItem.menu.addSettingsAction(_('Network Settings'),
|
this._summaryItem.menu.addSettingsAction(_('Network Settings'),
|
||||||
'gnome-network-panel.desktop');
|
'gnome-network-panel.desktop');
|
||||||
this._summaryItem.hide();
|
this._summaryItem.hide();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
_sync() {
|
_sync() {
|
||||||
|
@ -77,7 +77,6 @@ var Client = class {
|
|||||||
this.probing = this._proxy.Probing;
|
this.probing = this._proxy.Probing;
|
||||||
if (this.probing)
|
if (this.probing)
|
||||||
this.emit('probing-changed', this.probing);
|
this.emit('probing-changed', this.probing);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
_onPropertiesChanged(proxy, properties) {
|
_onPropertiesChanged(proxy, properties) {
|
||||||
|
@ -487,7 +487,6 @@ var SwitcherList = GObject.registerClass({
|
|||||||
this._scrollToRight(index);
|
this._scrollToRight(index);
|
||||||
else if (this._items[index].allocation.x1 - value < 0)
|
else if (this._items[index].allocation.x1 - value < 0)
|
||||||
this._scrollToLeft(index);
|
this._scrollToLeft(index);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
_scrollToLeft(index) {
|
_scrollToLeft(index) {
|
||||||
|
@ -222,7 +222,6 @@ class UserWidget extends St.BoxLayout {
|
|||||||
opacity: 0,
|
opacity: 0,
|
||||||
});
|
});
|
||||||
this.add_child(this._label);
|
this.add_child(this._label);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
this._updateUser();
|
this._updateUser();
|
||||||
|
@ -357,7 +357,6 @@ var WorkspaceTracker = class {
|
|||||||
workspace._windowAddedId = workspace.connect('window-added', this._queueCheckWorkspaces.bind(this));
|
workspace._windowAddedId = workspace.connect('window-added', this._queueCheckWorkspaces.bind(this));
|
||||||
workspace._windowRemovedId = workspace.connect('window-removed', this._windowRemoved.bind(this));
|
workspace._windowRemovedId = workspace.connect('window-removed', this._windowRemoved.bind(this));
|
||||||
}
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
// Assume workspaces are only removed sequentially
|
// Assume workspaces are only removed sequentially
|
||||||
// (e.g. 2,3,4 - not 2,4,7)
|
// (e.g. 2,3,4 - not 2,4,7)
|
||||||
@ -516,7 +515,6 @@ var AppSwitchAction = GObject.registerClass({
|
|||||||
}
|
}
|
||||||
|
|
||||||
vfunc_gesture_progress(_actor) {
|
vfunc_gesture_progress(_actor) {
|
||||||
|
|
||||||
if (this.get_n_current_points() == 3) {
|
if (this.get_n_current_points() == 3) {
|
||||||
for (let i = 0; i < this.get_n_current_points(); i++) {
|
for (let i = 0; i < this.get_n_current_points(); i++) {
|
||||||
let [startX, startY] = this.get_press_coords(i);
|
let [startX, startY] = this.get_press_coords(i);
|
||||||
@ -526,7 +524,6 @@ var AppSwitchAction = GObject.registerClass({
|
|||||||
Math.abs(y - startY) > APP_MOTION_THRESHOLD)
|
Math.abs(y - startY) > APP_MOTION_THRESHOLD)
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
@ -172,7 +172,6 @@ class WorkspaceSwitcherPopup extends St.Widget {
|
|||||||
indicator = new St.Bin({ style_class: 'ws-switcher-box' });
|
indicator = new St.Bin({ style_class: 'ws-switcher-box' });
|
||||||
|
|
||||||
this._list.add_actor(indicator);
|
this._list.add_actor(indicator);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
let workArea = Main.layoutManager.getWorkAreaForMonitor(Main.layoutManager.primaryIndex);
|
let workArea = Main.layoutManager.getWorkAreaForMonitor(Main.layoutManager.primaryIndex);
|
||||||
|
Loading…
Reference in New Issue
Block a user