mirror of
https://github.com/edu4rdshl/gnome-shell.git
synced 2026-07-17 23:24:51 +00:00
js: Port to modules
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1499>
This commit is contained in:
parent
d9198317ae
commit
a751e213f6
162 changed files with 2183 additions and 2336 deletions
|
|
@ -1,16 +1,15 @@
|
|||
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
|
||||
/* exported Button, SystemIndicator */
|
||||
|
||||
const Atk = imports.gi.Atk;
|
||||
const Clutter = imports.gi.Clutter;
|
||||
const GObject = imports.gi.GObject;
|
||||
const St = imports.gi.St;
|
||||
import Atk from 'gi://Atk';
|
||||
import Clutter from 'gi://Clutter';
|
||||
import GObject from 'gi://GObject';
|
||||
import St from 'gi://St';
|
||||
|
||||
const Main = imports.ui.main;
|
||||
const Params = imports.misc.params;
|
||||
const PopupMenu = imports.ui.popupMenu;
|
||||
import * as Main from './main.js';
|
||||
import * as Params from '../misc/params.js';
|
||||
import * as PopupMenu from './popupMenu.js';
|
||||
|
||||
var ButtonBox = GObject.registerClass(
|
||||
export const ButtonBox = GObject.registerClass(
|
||||
class ButtonBox extends St.Widget {
|
||||
_init(params) {
|
||||
params = Params.parse(params, {
|
||||
|
|
@ -95,7 +94,7 @@ class ButtonBox extends St.Widget {
|
|||
}
|
||||
});
|
||||
|
||||
var Button = GObject.registerClass({
|
||||
export const Button = GObject.registerClass({
|
||||
Signals: { 'menu-set': {} },
|
||||
}, class PanelMenuButton extends ButtonBox {
|
||||
_init(menuAlignment, nameText, dontCreateMenu) {
|
||||
|
|
@ -204,7 +203,7 @@ var Button = GObject.registerClass({
|
|||
* of an icon and a menu section, which will be composed into the
|
||||
* aggregate menu.
|
||||
*/
|
||||
var SystemIndicator = GObject.registerClass(
|
||||
export const SystemIndicator = GObject.registerClass(
|
||||
class SystemIndicator extends St.BoxLayout {
|
||||
_init() {
|
||||
super._init({
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue