Skip to content
This repository has been archived by the owner on Apr 22, 2024. It is now read-only.

Commit

Permalink
refactor: remove signals
Browse files Browse the repository at this point in the history
  • Loading branch information
oae committed Apr 1, 2019
1 parent ed1439b commit 140c1b8
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 13 deletions.
3 changes: 1 addition & 2 deletions settings.js
Expand Up @@ -90,9 +90,8 @@ var Settings = class Settings {
}

_onSettingsChanged(schema) {
debug(`extension ${this.extension.metadata.name} is modified. emitting sync event`);
debug(`extension ${this.extension.metadata.name} is modified.`);
schema.data = this._getSchemaDataFromDconf(schema.gSettings);
extensionsSync.sync.emit('extensions-sync');
}

_initSchemaList() {
Expand Down
11 changes: 0 additions & 11 deletions sync.js
Expand Up @@ -20,8 +20,6 @@ const ExtensionSystem = imports.ui.extensionSystem;
const ExtensionDownloader = imports.ui.extensionDownloader;
const ExtensionUtils = imports.misc.extensionUtils;

const Signals = imports.signals;

const { Settings } = extensionsSync.imports.settings;
const { getSettings } = extensionsSync.imports.convenience;
const { Request } = extensionsSync.imports.request;
Expand Down Expand Up @@ -73,7 +71,6 @@ var Sync = class Sync {
}

async updateGist() {
debug('emitted sync event');
debug(`syncing ${Object.keys(this.syncedExtensions).length} extensions`);

const syncData = this.getSyncData();
Expand Down Expand Up @@ -186,8 +183,6 @@ var Sync = class Sync {
});

},{});

this.emit('extensions-sync');
}

_startWatching(extension) {
Expand All @@ -200,8 +195,6 @@ var Sync = class Sync {
extension,
settings,
};

this.emit('extensions-sync');
}

_stopWatching(extension) {
Expand All @@ -211,8 +204,6 @@ var Sync = class Sync {
delete this.syncedExtensions[extension.metadata.uuid];

syncedExtension.settings.stopWatching();

this.emit('extensions-sync');
}

_onExtensionStateChanged(extension) {
Expand Down Expand Up @@ -306,5 +297,3 @@ var Sync = class Sync {
}
};
}

Signals.addSignalMethods(Sync.prototype);

0 comments on commit 140c1b8

Please sign in to comment.