mirror of
https://gitlab.gnome.org/julianschacher/top-bar-organizer.git
synced 2025-10-27 15:19:09 +00:00
Refactor: Use constructor instead of _init
This commit is contained in:
parent
cda099be24
commit
2f9f4d1a3f
@ -18,8 +18,8 @@ var PrefsBoxOrderItemRow = GObject.registerClass({
|
|||||||
"menu-button"
|
"menu-button"
|
||||||
]
|
]
|
||||||
}, class PrefsBoxOrderItemRow extends Adw.ActionRow {
|
}, class PrefsBoxOrderItemRow extends Adw.ActionRow {
|
||||||
_init(params = {}, scrollManager, item) {
|
constructor(params = {}, scrollManager, item) {
|
||||||
super._init(params);
|
super(params);
|
||||||
|
|
||||||
this._associateItem(item);
|
this._associateItem(item);
|
||||||
this._configureMenu();
|
this._configureMenu();
|
||||||
|
|||||||
@ -16,8 +16,8 @@ var PrefsBoxOrderListBox = GObject.registerClass({
|
|||||||
* @param {String} boxOrder - The box order this PrefsBoxOrderListBox is
|
* @param {String} boxOrder - The box order this PrefsBoxOrderListBox is
|
||||||
* associated with.
|
* associated with.
|
||||||
*/
|
*/
|
||||||
_init(params = {}, boxOrder) {
|
constructor(params = {}, boxOrder) {
|
||||||
super._init(params);
|
super(params);
|
||||||
|
|
||||||
this._settings = ExtensionUtils.getSettings();
|
this._settings = ExtensionUtils.getSettings();
|
||||||
|
|
||||||
|
|||||||
@ -12,8 +12,8 @@ var PrefsBoxOrderListEmptyPlaceholder = GObject.registerClass({
|
|||||||
GTypeName: "PrefsBoxOrderListEmptyPlaceholder",
|
GTypeName: "PrefsBoxOrderListEmptyPlaceholder",
|
||||||
Template: Me.dir.get_child("ui").get_child("prefs-box-order-list-empty-placeholder.ui").get_uri()
|
Template: Me.dir.get_child("ui").get_child("prefs-box-order-list-empty-placeholder.ui").get_uri()
|
||||||
}, class PrefsBoxOrderListEmptyPlaceholder extends Gtk.Box {
|
}, class PrefsBoxOrderListEmptyPlaceholder extends Gtk.Box {
|
||||||
_init(params = {}) {
|
constructor(params = {}) {
|
||||||
super._init(params);
|
super(params);
|
||||||
|
|
||||||
/// Make `this` accept drops by creating a drop target and adding it to
|
/// Make `this` accept drops by creating a drop target and adding it to
|
||||||
/// `this`.
|
/// `this`.
|
||||||
|
|||||||
@ -22,8 +22,8 @@ var PrefsPage = GObject.registerClass({
|
|||||||
"right-box"
|
"right-box"
|
||||||
]
|
]
|
||||||
}, class PrefsPage extends Adw.PreferencesPage {
|
}, class PrefsPage extends Adw.PreferencesPage {
|
||||||
_init(params = {}) {
|
constructor(params = {}) {
|
||||||
super._init(params);
|
super(params);
|
||||||
|
|
||||||
this._settings = ExtensionUtils.getSettings();
|
this._settings = ExtensionUtils.getSettings();
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user