-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy pathextension.js
29 lines (24 loc) · 871 Bytes
/
extension.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import { panel } from 'resource:///org/gnome/shell/ui/main.js';
import { SSHQuickConnect } from './SSHQuickConnect.js';
import { Extension } from 'resource:///org/gnome/shell/extensions/extension.js';
import GObject from 'gi://GObject';
export const getExtensionObject = () => Extension.lookupByUUID('[email protected]');
export default class SSHQuickConnectExtension extends Extension {
_indicator;
_settings;
enable() {
this._settings = this.getSettings();
this._indicator = new SSHQuickConnect();
panel.addToStatusArea('ssh-quick-connect', this._indicator);
}
disable() {
this._indicator.stop();
this._indicator.destroy();
this._indicator = undefined;
this._settings = undefined;
}
}
GObject.registerClass(
{GTypeName: 'SSHQuickConnect'},
SSHQuickConnect
);