forked from Schneegans/Fly-Pie
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathprefs.js
27 lines (23 loc) · 1.36 KB
/
prefs.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
//////////////////////////////////////////////////////////////////////////////////////////
// ___ _ ___ //
// | | \/ | ) | | This software may be modified and distri- //
// O- |- | | - | | |- -O buted under the terms of the MIT license. //
// | |_ | | | |_ See the LICENSE file for details. //
// //
//////////////////////////////////////////////////////////////////////////////////////////
'use strict';
const ExtensionUtils = imports.misc.extensionUtils;
const Me = imports.misc.extensionUtils.getCurrentExtension();
const PreferencesDialog = Me.imports.src.prefs.PreferencesDialog.PreferencesDialog;
// Like in 'extension.js' this is used for setting up the translations.
function init() {
ExtensionUtils.initTranslations();
}
// This function is called when the preferences window is created to build and return a
// Gtk widget. We create a new instance of the PreferencesDialog class each time this
// method is called. This way we can actually open multiple settings windows and interact
// with all of them properly.
function buildPrefsWidget() {
var dialog = new PreferencesDialog();
return dialog.getWidget();
}