mirror of
https://github.com/edu4rdshl/gnome-shell.git
synced 2026-07-17 23:24:51 +00:00
cleanup: Use method syntax
Modern javascript has a short-hand for function properties, embrace it for better readability and to prepare for an eventual port to ES6 classes. https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/23
This commit is contained in:
parent
cff0b81f32
commit
76f09b1e49
116 changed files with 3140 additions and 3140 deletions
|
|
@ -161,7 +161,7 @@ function installImporter(extension) {
|
|||
var ExtensionFinder = new Lang.Class({
|
||||
Name: 'ExtensionFinder',
|
||||
|
||||
_loadExtension: function(extensionDir, info, perUserDir) {
|
||||
_loadExtension(extensionDir, info, perUserDir) {
|
||||
let fileType = info.get_file_type();
|
||||
if (fileType != Gio.FileType.DIRECTORY)
|
||||
return;
|
||||
|
|
@ -184,7 +184,7 @@ var ExtensionFinder = new Lang.Class({
|
|||
this.emit('extension-found', extension);
|
||||
},
|
||||
|
||||
scanExtensions: function() {
|
||||
scanExtensions() {
|
||||
let perUserDir = Gio.File.new_for_path(global.userdatadir);
|
||||
FileUtils.collectFromDatadirs('extensions', true, Lang.bind(this, this._loadExtension, perUserDir));
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue