projecthamster / hamster-shell-extension

Shell extension for hamster
http://projecthamster.org
GNU General Public License v3.0
217 stars 92 forks source link

Gnome 40 Support #340

Closed hedayat closed 3 years ago

hedayat commented 3 years ago

The extension doesn't work under Gnome 40.

At least. when you try to open the preferences you receive:


TypeError: class heritage Gtk.VBox is not an object or null

Stack trace:
  @/home/hedayat/.local/share/gnome-shell/extensions/contact@projecthamster.org/prefs.js:34:1
  _init@resource:///org/gnome/Shell/Extensions/js/extensionsService.js:206:33
  OpenExtensionPrefsAsync/<@resource:///org/gnome/Shell/Extensions/js/extensionsService.js:122:28
  asyncCallback@resource:///org/gnome/gjs/modules/core/overrides/Gio.js:115:22
  run@resource:///org/gnome/Shell/Extensions/js/dbusService.js:177:20
  main@resource:///org/gnome/Shell/Extensions/js/main.js:19:13
  run@resource:///org/gnome/gjs/modules/script/package.js:206:19
  start@resource:///org/gnome/gjs/modules/script/package.js:190:8
  @/usr/share/gnome-shell/org.gnome.Shell.Extensions:1:17

Well, it seems that it is because of the move to Gtk 4.

You also need to explicitly add version 40 to extension supported gnome shell versions.

~Update: the extension itself seems to also need changes to become compatible with gnome 40~ Update 2: well, while it didn't work before, it works fine now. So, it seems that fixing the preferences window is enough to support gnome shell 40.

faebser commented 3 years ago

As this extension is part of my daily workflow I would really like to know how you got it to run in Gnome 40.

hedayat commented 3 years ago

@faebser Edit metadata.json (~/.local/share/gnome-shell/extensions/contact@projecthamster.org/metadata.json) and add "40" to shell-version array. Save the file and reload the extension or gnome-shell. It should work. Although, the preferences window won't work in its current state.

hedayat commented 3 years ago

Closed by #341