-
Notifications
You must be signed in to change notification settings - Fork 37
/
Copy pathextension.js
50 lines (43 loc) · 1.58 KB
/
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
/**
/*
This file is part of Apt Update Indicator
Apt Update Indicator is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Apt Update Indicator is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Apt Update Indicator. If not, see <http://www.gnu.org/licenses/>.
Copyright 2013 Amy Chan, [email protected]
Copyright 2013-7 Amaury Sechet, [email protected]
Copyright 2017 Fran Glais, [email protected]
*/
const ExtensionUtils = imports.misc.extensionUtils;
const Me = ExtensionUtils.getCurrentExtension();
const Decoration = Me.imports.decoration;
const Buttons = Me.imports.buttons;
const AppMenu = Me.imports.app_menu;
const Utils = Me.imports.utils;
let decoration = null;
let buttons = null;
let appMenu = null;
function init() {
}
function enable() {
let settings = Utils.enable();
buttons = new Buttons.Buttons(settings);
decoration = new Decoration.Decoration(settings);
appMenu = new AppMenu.AppMenu(settings);
}
function disable() {
appMenu.destroy();
appMenu = null;
decoration.destroy();
decoration = null;
buttons.destroy();
buttons = null;
Utils.disable();
}