Florian Müllner
099b2eeb49
cleanup: Use null for nick/blurb in ParamSpecs
...
As they are only used by gstreamer for gst-inspect & other tools.
Projects like mutter and gtk have already completely dropped them,
so follow their lead.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/347 >
(cherry picked from commit 46a4fa0976 )
2024-10-18 19:15:02 +02:00
Florian Müllner
67cdd0bea2
window-list: Remove outdated style
...
A long time ago, the window list used to embed the bottom message
tray, which caused notifications to inherit the window-list's
font style.
Since that's no longer the case, we have no business in messing
with notification styling, so stop doing that.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/338 >
(cherry picked from commit f1671bc206 )
2024-10-17 20:56:38 +02:00
Florian Müllner
87a849c5af
window-list: Switch to Adw.SwitchRow
...
libadwaita fixed the actionable implementation of Adw.SwitchRow,
so can use the convenience widget instead of composing our own.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/341 >
(cherry picked from commit 548d7659e1 )
2024-10-17 20:56:26 +02:00
Florian Müllner
f0bff952be
window-list: Remove superfluous bindings
...
The setting is already bound to the switch via the corresponding action,
no need to also set up a binding.
In fact, the second binding is actively harmful, as it keeps the
connection alive until dispose, so the setting is reset on
garbage collection.
Closes https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/issues/511
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/341 >
(cherry picked from commit 0162644041 )
2024-10-17 20:56:18 +02:00
Florian Müllner
b3ff771a1d
window-list: Add missing action
...
Commit 24ba03fe9 added a new setting, but forgot to create the
corresponding action.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/341 >
(cherry picked from commit 062a3d21ab )
2024-10-17 20:56:09 +02:00
Florian Müllner
3ef718d34c
window-list: Fix active state
...
Commit c72b8b21 fixed the styling of the active window's button,
but missed that the `active` property uses the style information
as well.
Adjust it to use the correct actor when checking for the style class.
Closes https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/issues/529
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/342 >
(cherry picked from commit a5a92026ac )
2024-10-17 20:55:59 +02:00
Florian Müllner
fb2d87c1da
window-list: Fix minimized styling
...
Commit 039c66e7b7 wrapped the button in a container to
animate transitions, but didn't adjust the `.minimized`
styling to still apply to the button (where it is
expected) rather than the wrapper.
Fix this just like commit c72b8b21 did for the
`.focused` styling.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/342 >
(cherry picked from commit 28fd210f28 )
2024-10-17 20:55:52 +02:00
Florian Müllner
4da312040b
window-list: Don't recreate icons on theme changes
...
All icons use `StIcon`, which already updates itself correctly
on icon theme changes.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/337 >
(cherry picked from commit d43abe0869 )
2024-10-17 20:55:22 +02:00
Florian Müllner
89276cc184
window-list: Small stylesheet cleanup
...
The light stylesheet duplicates some declarations, and the
last occurrence matches what we already inherit from the
dark stylesheet.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/337 >
(cherry picked from commit 860c56f83e )
2024-10-17 20:55:07 +02:00
Jakub Steiner
e28215f38f
window-list: Update styling
...
- Contemporary look. Fewer borders, thinner outlines for workspace indicators
- Lacks the designed unfocused window separators.
- Relies on https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/328
Fixes https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/issues/421
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/330 >
2024-07-31 14:37:31 +00:00
Florian Müllner
c72b8b2122
window-list: Fix .focused styling
...
Commit 039c66e7b7 wrapped the button in a container to
animate transitions, but didn't adjust the `.focused`
styling to still apply to the button (where it is
expected) rather than the wrapper.
Fix that.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/328 >
2024-07-13 00:11:19 +02:00
Florian Müllner
0554a8e97d
window-list: Replace custom tooltip implementation
...
DashItemContainer already has support for showing a tooltip-like
label, so now that we use that for animating items, we can use
it for tooltips as well.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/325 >
2024-06-29 13:43:55 +02:00
Florian Müllner
039c66e7b7
window-list: Animate buttons in and out
...
Buttons are currently added and removed from the list without
any transitions, which gives the list a "jumpy" feel. Instead,
do what we do elsewhere and smoothly animate additions and
removals by re-using the dash's ItemContainer class.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/325 >
2024-06-29 13:43:55 +02:00
Florian Müllner
7eb00e350e
window-list: Don't hide window button while unmanaging
...
This will allow to animate the transition.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/325 >
2024-06-29 13:43:55 +02:00
Florian Müllner
f76f9e8220
window-list: Don't use homogeneous layout
...
We want all buttons in the window list to have the same size,
but that's already achieved via max/natural-width in the CSS.
Not enforcing the equal size via the layout manager will allow
buttons to temporarily have a different size when we start
animating additions and removals.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/325 >
2024-06-29 13:13:12 +02:00
Florian Müllner
da90d365ec
window-list: Use getter methods for events
...
The underlying structs were made opaque a while ago, so direct
access to the struct fields is no longer possible.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/320 >
2024-04-26 15:22:16 +02:00
Florian Müllner
24ba03fe96
window-list: Expose workspace preview option
...
Now that we have the option, the window-list should expose it
in its preference window like the workspace-indicator.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/316 >
2024-04-24 14:23:22 +00:00
Florian Müllner
69d8d1a335
workspace-indicator: Make previews configurable
...
Now that previews scroll when there are too many workspaces,
there is no longer a reason for the 6-workspace limit.
However some users do prefer the menu, so rather than drop it,
turn it into a proper preference.
Closes
https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/issues/336
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/316 >
2024-04-24 14:23:22 +00:00
Florian Müllner
0c42f162d3
window-list: Use actual copy of workspace-indicator
...
We are now at a point where the code from the workspace-indicator
extension is usable from the window-list.
However instead of updating the copy, go one step further and
remove it altogether, and copy the required files at build time.
This ensures that future changes are picked up by both extensions
without duplicating any work.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/307 >
2024-04-24 14:19:51 +00:00
Florian Müllner
9c97f01bc2
window-list: Handle changes to workspace menu
...
For now the menu is always set at construction time, however this
will change in the future. Prepare for that by handling the
`menu-set` signal, similar to the top bar.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/307 >
2024-04-24 14:19:51 +00:00
Florian Müllner
8693a8a74c
window-list: Externally adjust workspace menu
...
In order to use a PanelMenu.Button in the bottom bar, we have
to tweak its menu a bit.
We currently handle this inside the indicator, but that means the
code diverges from the original code in the workspace-indicator
extension.
Avoid this by using a small subclass that handles the adjustments.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/307 >
2024-04-24 14:19:51 +00:00
Florian Müllner
47c12c6279
window-list: Override base style class
...
Apply the changes from the last commit to the workspace-indicator
copy, and override the base style class from the extension.
This will eventually allow us to share the exact same code between
the two extensions, but still use individual styling if necessary.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/307 >
2024-04-24 14:19:51 +00:00
Florian Müllner
d3debab713
window-list: Use consistent style class prefix
...
This will eventually allow us to re-use the workspace-indicator
extension without changing anything but the used prefix.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/307 >
2024-04-24 14:19:51 +00:00
Florian Müllner
56a74abb8a
window-list: Use more appropriate fallback icon
...
'icon-missing' is not an actual icon name. It somewhat works
because an invalid icon name will fallback to the correct
'image-missing', however for apps the generic app icon is
a better fallback.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/315 >
2024-04-24 14:10:41 +00:00
Florian Müllner
f6c74e93b7
window-list: Replace Meta.Rectangle
...
It's deprecated in favor of Mtk.Rectangle, which is a drop-in
replacement.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/306 >
2024-02-22 00:02:40 +00:00
Florian Müllner
f53984670c
window-list: Fix menu ornament in workspace indicator
...
The default ornament is now HIDDEN, so in order to align items,
we always have set an initial ornament.
In gnome-shell 46, the expected "counter ornament" to DOT is NO_DOT
rather than NONE, so use that.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/305 >
2024-02-21 00:07:15 +01:00
Florian Müllner
b00f5c4604
window-list: Fix window previews
...
St.Bin no longer expands its child automatically. Unless do we do
explicitly, the preview actor will be allocated with a size of 0x0.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/304 >
2024-02-19 19:59:54 +01:00
Florian Müllner
071584621e
window-list: Update visibility on window-type changes
...
The visibility depends on the type, so we should listen for
changes (even if the property is unlikely to change).
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/292 >
2023-12-01 19:10:08 +01:00
Florian Müllner
5c57f44838
window-list: Don't hide previews on other monitors
...
Workspace thumbnails are clipped, so there's no major benefit
of hiding the actors explicitly.
On the other hand, the check is useful on size/position changes
to avoid unnecessary relayouts.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/292 >
2023-12-01 19:09:30 +01:00
Florian Müllner
93741e9e1c
Revert "window-list: Only initialize preview visibility on map"
...
It is not possible to unmap an actor from within the map vfunc,
so the fix broke the initial visibility again.
This reverts commit 8b7cfff558 .
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/292 >
2023-12-01 19:09:30 +01:00
Florian Müllner
836f81f2e2
window-list: Move additional padding into buttons
...
Commit ca1c4b0f9e added additional padding, which means that the
interactive area of buttons no longer extends to the bottom of
the screen.
Address this by moving the new padding into the buttons themselves.
That restores the Fittsability of the bottom bar, without affecting
the cleaner visual appearance.
Close https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/issues/453
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/291 >
2023-12-01 12:34:20 +00:00
Florian Müllner
574638328e
window-list: Clean up stylesheet indent
...
Replaces tabs with spaces.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/291 >
2023-12-01 12:34:20 +00:00
Florian Müllner
d10b98c4fc
extensions: Stop using ClutterContainer API
...
The methods have long been deprecated in favor of the equivalent
ClutterActor methods, so use the latter instead.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/288 >
2023-11-14 16:26:06 +00:00
Florian Müllner
8b7cfff558
window-list: Only initialize preview visibility on map
...
The check whether the window overlaps with the monitor the actor
is on requires the actor to be added to the stage first, so delay
the initial visibility update that was added in commit f576f1b1b6 .
Fixes: f576f1b1 ("window-list: Initialize preview visibility")
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/286 >
2023-11-08 16:36:59 +00:00
Florian Müllner
91a1b8245b
window-list: Remove window picker
...
Now that the overview is available again in the classic session,
the window picker that used to replace it is unused.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/287 >
2023-11-07 17:43:18 +01:00
Florian Müllner
fb858ed0e4
window-list: Complete move to connectObject()
...
Commit 3bfaf6f88a removed the explicit disconnect, but forgot
to use connectObject() to connect the handler.
Closes: https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/issues/459
Fixes: 3bfaf6f8 ("js: Use connectObject()")
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/281 >
2023-10-09 15:36:39 +02:00
Florian Müllner
f576f1b1b6
window-list: Initialize preview visibility
...
Otherwise we can end up showing window previews in the workspace
thumbnail that shouldn't be visible, if none of the properties we
track for updates changes.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/280 >
2023-09-29 21:35:33 +02:00
Florian Müllner
2510bb3625
extensions: Stop using run_dispose()
...
It is considered bad practice, and mainly a lazy way of disconnecting
signal handlers without tracking individual handler IDs.
We can do better by using connectObject(), which provides the same
level of convenience without the dodginess of getting behind the
garbage collector's back.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/275 >
2023-09-26 15:21:41 +00:00
Florian Müllner
b7f285d733
Make project compatible with Reuse Software spec
...
Provide all licenses used in the project in a LICENSES folder and
add SPDX license and copyright information for all files in
accordance with the Reuse Software[0] specification.
The copyright information is based on the file's git history,
using a fairly generous definition of "non-trivial".
As of the spec recommendation, the information is generally added
as comments in the files themselves, except for
- NEWS, README and similar top-level standard files, so that
a SPDX code isn't the first thing people encounter
- files that don't support comments (json) or where they'd
be a bit awkward (.desktop, .service)
- anything under po/, to not interfere with translation teams
Those are covered by a .reuse/dep5 files, except for image assets,
where separate .license files are used (It would be possible to
add comments to SVG files, but I don't trust image editors to
preserve them).
[0] https://reuse.software/
Part-of:
<https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/224 >
2023-08-17 11:51:48 +00:00
Florian Müllner
a911447375
js: Port to ESM
...
The shell pulled the trigger and switched to ESM for all its
imports, follow suit.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/269 >
2023-08-06 15:59:35 +02:00
Florian Müllner
2d3307c657
window-list: Use InjectionManager instead of custom classes
...
Once the shell is ported to ESM, it will no longer be possible
to replace entire classes (even when imported). Prepare for that
by overriding methods of the regular WorkspaceBackground class
instead.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/268 >
2023-08-06 13:45:56 +02:00
Florian Müllner
d59bc0b7f0
window-list: Do not inject WindowPicker into Main
...
This will become impossible once Main is converted to ESM. Instead,
use the Extension class itself to hold the window picker.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/268 >
2023-08-06 13:45:56 +02:00
Florian Müllner
f2c73329be
extensions: Use new convenience classes
...
Convenience APIs for extensions are now provided as Extension/Prefs
base classes.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/268 >
2023-08-05 18:53:41 +02:00
Florian Müllner
e75a1a15ac
extensions: Import ExtensionUtils as module
...
ExtensionUtils has been converted to ESM and split into two modules,
for extensions and prefs respectively.
Adjust to those changes.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/266 >
2023-07-15 14:13:25 +02:00
Florian Müllner
1155170c7c
window-list: Stop using getCurrentExtension()
...
The method is no longer exported. There will be a nicer alternative
soon, in the meantime we can just keep track of our main Extension
object ourselves.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/266 >
2023-07-15 14:10:27 +02:00
Florian Müllner
3bfaf6f88a
js: Use connectObject()
...
gnome-shell added (dis)connectObject() methods to partially automate
signal handling. It doesn't only save a significant amount of code,
but also makes it harder to miss cleaning up on destroy.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/263 >
2023-07-09 18:45:07 +02:00
Florian Müllner
37baccd9fc
window-list: Remove some dead code
...
The code that connected the signal was removed in 9fa522c29a .
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/263 >
2023-07-09 18:33:52 +02:00
Florian Müllner
cf007dd472
extensions: Turn extensions into modules
...
As gnome-shell is moving to ESM, it will now load extensions as
standard modules instead of using legacy imports. The change boils
down to exporting the Extension class as default, but we can also
start using standard imports for introspected modules now, so do
that at the same time.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/259 >
2023-07-07 00:35:08 +02:00
Arik W
22b9f888fb
window-list: Add tooltip for long window titles
...
Adds a tooltip feature to the window buttons.
If a button’s label is too long to fit, a tooltip will show the complete content when the user hovers over the button.
Fixes https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/issues/170
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/251 >
2023-06-18 19:08:53 +00:00
Florian Müllner
904ead1fb1
window-list: Replace classic- with light style
...
Now that classic styling is based on color scheme instead of
a dedicated "classic" stylesheet, we should do the same for
extension styling, with the bonus that it also works with the
regular appearance setting outside the classic session.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/254 >
2023-05-26 20:26:43 +02:00