Review of "Unity Buttons" version 10

Details Page Preview

macOS-style close and restore buttons in the top panel with window title. Hides the titlebar when maximized to save vertical space. Automatically centers and resizes windows on unmaximize. Uses 100% native GNOME Shell animations. Supports Wayland only.

Extension Homepage
https://github.com/Lokoyote/unity-buttons-extension

No comments.

Diff Against

Files

Note: Binary files aren't shown on the web site. To see all files, please download the extension zipfile.

Shexli (experimental) error 1 warning 3

Shexli found 4 issues that may need reviewer attention.

EGO-X-004 warning

extensions should avoid synchronous file IO in shell code

Shell code should avoid synchronous file IO APIs like `GLib.file_get_contents()` and `Gio.File.load_contents()`.

File Operations

  • extension.js:921
    this._cache.load_contents(null)
  • extension.js:935
    file.load_contents(null)

EGO-P-003 error

GSettings schema XML must be present in package

Extension appears to use GSettings but no `.gschema.xml` file is included in the package.

GSettings Schemas

EGO-L-005 warning

owned object references should be released in disable()

Owned references that are cleaned up in `disable()` should also be released with `null` or `undefined`.

Destroy all objects

  • extension.js:659
    this._settings       = this.getSettings()
  • extension.js:660
    this._wmSettings     = new Gio.Settings({ schema_id: 'org.gnome.desktop.wm.preferences' })

EGO-L-004 warning

main loop sources should be removed in disable()

Main loop sources assigned in `enable()` are missing matching removals in `disable()` or its helper methods.

Remove main loop sources

  • extension.js:898
                    GLib.idle_add(GLib.PRIORITY_DEFAULT_IDLE, () => {
                        if (!win || win.get_maximized()) return GLib.SOURCE_REMOVE;
                        _safe(() => {
                            const r = win.get_frame_rect();
                            win.move_resize_frame(true, r.x, r.y, r.
  • extension.js:384
                    GLib.idle_add(GLib.PRIORITY_DEFAULT_IDLE, () => {
                        if (!win || win.get_maximized()) return GLib.SOURCE_REMOVE;
                        _safe(() => {
                            const r = win.get_frame_rect();
                            win.move_resize_frame(true, r.x, r.y, r.
  • extension.js:573
    GLib.idle_add(GLib.PRIORITY_HIGH, () => { poll(); return GLib.SOURCE_REMOVE; })

All Versions

Version Status
10 Unreviewed
9 Active
8 Rejected
7 Rejected
6 Active
5 Rejected
4 Rejected
3 Rejected
2 Rejected
1 Rejected