extensions: Stop setting GTypeName
The type name generated by gjs now includes the filename, so we don't have to set it ourselves to make sure it's unique. https://gitlab.gnome.org/GNOME/gnome-shell-extensions/merge_requests/95
This commit is contained in:
@@ -22,9 +22,8 @@ const Columns = {
|
||||
ADJUSTMENT: 4,
|
||||
};
|
||||
|
||||
const Widget = GObject.registerClass({
|
||||
GTypeName: 'AutoMoveWindowsPrefsWidget',
|
||||
}, class Widget extends Gtk.Grid {
|
||||
const Widget = GObject.registerClass(
|
||||
class Widget extends Gtk.Grid {
|
||||
_init(params) {
|
||||
super._init(params);
|
||||
this.set_orientation(Gtk.Orientation.VERTICAL);
|
||||
|
||||
@@ -132,9 +132,8 @@ class WindowContextMenu extends PopupMenu.PopupMenu {
|
||||
}
|
||||
}
|
||||
|
||||
const WindowTitle = GObject.registerClass({
|
||||
GTypeName: 'WindowListWindowTitle',
|
||||
}, class WindowTitle extends St.BoxLayout {
|
||||
const WindowTitle = GObject.registerClass(
|
||||
class WindowTitle extends St.BoxLayout {
|
||||
_init(metaWindow) {
|
||||
this._metaWindow = metaWindow;
|
||||
|
||||
@@ -205,7 +204,6 @@ const WindowTitle = GObject.registerClass({
|
||||
|
||||
|
||||
const BaseButton = GObject.registerClass({
|
||||
GTypeName: 'WindowListBaseButton',
|
||||
GTypeFlags: GObject.TypeFlags.ABSTRACT,
|
||||
Properties: {
|
||||
'ignore-workspace': GObject.ParamSpec.boolean(
|
||||
@@ -348,9 +346,8 @@ const BaseButton = GObject.registerClass({
|
||||
});
|
||||
|
||||
|
||||
const WindowButton = GObject.registerClass({
|
||||
GTypeName: 'WindowListWindowButton',
|
||||
}, class WindowButton extends BaseButton {
|
||||
const WindowButton = GObject.registerClass(
|
||||
class WindowButton extends BaseButton {
|
||||
_init(metaWindow, perMonitor, monitorIndex) {
|
||||
super._init(perMonitor, monitorIndex);
|
||||
|
||||
@@ -480,9 +477,8 @@ class AppContextMenu extends PopupMenu.PopupMenu {
|
||||
}
|
||||
}
|
||||
|
||||
const AppButton = GObject.registerClass({
|
||||
GTypeName: 'WindowListAppButton',
|
||||
}, class AppButton extends BaseButton {
|
||||
const AppButton = GObject.registerClass(
|
||||
class AppButton extends BaseButton {
|
||||
_init(app, perMonitor, monitorIndex) {
|
||||
super._init(perMonitor, monitorIndex);
|
||||
|
||||
@@ -672,9 +668,8 @@ const AppButton = GObject.registerClass({
|
||||
});
|
||||
|
||||
|
||||
const WindowList = GObject.registerClass({
|
||||
GTypeName: 'WindowListWindowList',
|
||||
}, class WindowList extends St.Widget {
|
||||
const WindowList = GObject.registerClass(
|
||||
class WindowList extends St.Widget {
|
||||
_init(perMonitor, monitor) {
|
||||
this._perMonitor = perMonitor;
|
||||
this._monitor = monitor;
|
||||
|
||||
@@ -6,9 +6,8 @@ const Main = imports.ui.main;
|
||||
const Overview = imports.ui.overview;
|
||||
const { WorkspacesDisplay } = imports.ui.workspacesView;
|
||||
|
||||
let MyWorkspacesDisplay = GObject.registerClass({
|
||||
GTypeName: 'WindowList_MyWorkspacesDisplay'
|
||||
}, class MyWorkspacesDisplay extends WorkspacesDisplay {
|
||||
let MyWorkspacesDisplay = GObject.registerClass(
|
||||
class MyWorkspacesDisplay extends WorkspacesDisplay {
|
||||
_init() {
|
||||
super._init();
|
||||
|
||||
@@ -65,7 +64,6 @@ let MyWorkspacesDisplay = GObject.registerClass({
|
||||
});
|
||||
|
||||
var WindowPicker = GObject.registerClass({
|
||||
GTypeName: 'WindowListWindowPicker',
|
||||
Signals: {
|
||||
'open-state-changed': { param_types: [GObject.TYPE_BOOLEAN] },
|
||||
},
|
||||
|
||||
@@ -9,9 +9,8 @@ const PopupMenu = imports.ui.popupMenu;
|
||||
const Gettext = imports.gettext.domain('gnome-shell-extensions');
|
||||
const _ = Gettext.gettext;
|
||||
|
||||
let WindowPreview = GObject.registerClass({
|
||||
GTypeName: 'WindowListWindowPreview',
|
||||
}, class WindowPreview extends St.Button {
|
||||
let WindowPreview = GObject.registerClass(
|
||||
class WindowPreview extends St.Button {
|
||||
_init(window) {
|
||||
super._init({
|
||||
style_class: 'window-list-window-preview',
|
||||
@@ -97,9 +96,8 @@ let WindowPreview = GObject.registerClass({
|
||||
}
|
||||
});
|
||||
|
||||
let WorkspaceThumbnail = GObject.registerClass({
|
||||
GTypeName: 'WindowListWorkspaceThumbnail',
|
||||
}, class WorkspaceThumbnail extends St.Button {
|
||||
let WorkspaceThumbnail = GObject.registerClass(
|
||||
class WorkspaceThumbnail extends St.Button {
|
||||
_init(index) {
|
||||
super._init({
|
||||
style_class: 'workspace',
|
||||
@@ -204,9 +202,8 @@ let WorkspaceThumbnail = GObject.registerClass({
|
||||
}
|
||||
});
|
||||
|
||||
var WorkspaceIndicator = GObject.registerClass({
|
||||
GTypeName: 'WindowListWorkspaceIndicator',
|
||||
}, class WorkspaceIndicator extends PanelMenu.Button {
|
||||
var WorkspaceIndicator = GObject.registerClass(
|
||||
class WorkspaceIndicator extends PanelMenu.Button {
|
||||
_init() {
|
||||
super._init(0.0, _('Workspace Indicator'), true);
|
||||
this.setMenu(new PopupMenu.PopupMenu(this, 0.0, St.Side.BOTTOM));
|
||||
|
||||
@@ -6,9 +6,8 @@ const Main = imports.ui.main;
|
||||
const Workspace = imports.ui.workspace;
|
||||
const WorkspacesView = imports.ui.workspacesView;
|
||||
|
||||
var MyWindowOverlay = GObject.registerClass({
|
||||
GTypeName: 'WindowsNavigator_MyWindowOverlay'
|
||||
}, class MyWindowOverlay extends Workspace.WindowOverlay {
|
||||
var MyWindowOverlay = GObject.registerClass(
|
||||
class MyWindowOverlay extends Workspace.WindowOverlay {
|
||||
_init(windowClone, parentActor) {
|
||||
super._init(windowClone, parentActor);
|
||||
|
||||
@@ -43,9 +42,8 @@ var MyWindowOverlay = GObject.registerClass({
|
||||
}
|
||||
});
|
||||
|
||||
var MyWorkspace = GObject.registerClass({
|
||||
GTypeName: 'WindowsNavigator_MyWorkspace'
|
||||
}, class MyWorkspace extends Workspace.Workspace {
|
||||
var MyWorkspace = GObject.registerClass(
|
||||
class MyWorkspace extends Workspace.Workspace {
|
||||
_init(metaWorkspace, monitorIndex) {
|
||||
super._init(metaWorkspace, monitorIndex);
|
||||
|
||||
@@ -117,9 +115,8 @@ var MyWorkspace = GObject.registerClass({
|
||||
}
|
||||
});
|
||||
|
||||
var MyWorkspacesView = GObject.registerClass({
|
||||
GTypeName: 'WindowsNavigator_MyWorkspacesView'
|
||||
}, class MyWorkspacesView extends WorkspacesView.WorkspacesView {
|
||||
var MyWorkspacesView = GObject.registerClass(
|
||||
class MyWorkspacesView extends WorkspacesView.WorkspacesView {
|
||||
_init(width, height, x, y, workspaces) {
|
||||
super._init(width, height, x, y, workspaces);
|
||||
|
||||
|
||||
@@ -15,9 +15,8 @@ const _ = Gettext.gettext;
|
||||
const WORKSPACE_SCHEMA = 'org.gnome.desktop.wm.preferences';
|
||||
const WORKSPACE_KEY = 'workspace-names';
|
||||
|
||||
let WindowPreview = GObject.registerClass({
|
||||
GTypeName: 'WorkspaceIndicatorWindowPreview',
|
||||
}, class WindowPreview extends St.Button {
|
||||
let WindowPreview = GObject.registerClass(
|
||||
class WindowPreview extends St.Button {
|
||||
_init(window) {
|
||||
super._init({
|
||||
style_class: 'workspace-indicator-window-preview',
|
||||
@@ -103,9 +102,8 @@ let WindowPreview = GObject.registerClass({
|
||||
}
|
||||
});
|
||||
|
||||
let WorkspaceThumbnail = GObject.registerClass({
|
||||
GTypeName: 'WorkspaceIndicatorWorkspaceThumbnail',
|
||||
}, class WorkspaceThumbnail extends St.Button {
|
||||
let WorkspaceThumbnail = GObject.registerClass(
|
||||
class WorkspaceThumbnail extends St.Button {
|
||||
_init(index) {
|
||||
super._init({
|
||||
style_class: 'workspace',
|
||||
|
||||
Reference in New Issue
Block a user