Commit Graph

2204 Commits

Author SHA1 Message Date
Martin
8b6835c3d6 Update Slovenian translation 2024-05-01 22:12:17 +00:00
Florian Müllner
bb5bb70ac5 Update POTFILES.in
The file is now copied at build time from the workspace-indicator
extension.

Fixes: 0c42f162 ("window-list: Use actual copy of workspace-indicator")
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/321>
2024-04-29 16:49:30 +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
02ff72b2f0 apps-menu: Set label_actor of Category items
Category items are based on BaseMenuItem rather than MenuItem,
so the accessible relationship isn't set up automatically for us.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/319>
2024-04-25 14:42:53 +00:00
Jordi Mas i Hernandez
9c7a086870 Update Catalan translation 2024-04-25 11:53:01 +00: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
d495a2eed8 workspace-indicator: Also show previews in menu
Since the regular session also switched to horizontal workspaces,
using a vertical menu has been a bit awkward.

Now that our previews have become more flexible, we can use them
in the collapsed state as well as when embedded into the top bar.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/316>
2024-04-24 14:23:22 +00:00
Florian Müllner
6b3990457e workspace-indicator: Stop handling vertical layouts
Both the regular session and GNOME classic use a horizontal layout
nowadays, so it doesn't seem worth to specifically handle vertical
layouts anymore.

The extension will still work when the layout is changed (by some
other extension), there will simply be a mismatch between horizontal
previews and the actual layout.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/316>
2024-04-24 14:23:22 +00:00
Florian Müllner
099cff0b95 workspace-indicator: Support labels in previews
The space in the top bar is too limited to include the workspace
names. However we'll soon replace the textual menu with a preview
popover. We can use bigger previews there, so we can include the
names to not lose functionality with regards to the current menu.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/316>
2024-04-24 14:23:22 +00:00
Florian Müllner
fac7fedfd3 workspace-indicator: Handle preview overflow
We currently avoid previews from overflowing in most setups by
artificially limiting them to a maximum of six workspaces.

Add some proper handling to also cover cases where space is more
limited, and to allow removing the restriction in the future.

For that, wrap the previews in an auto-scrolling scroll view
and add overflow indicators on each side.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/316>
2024-04-24 14:23:22 +00:00
Florian Müllner
6ed1b56526 workspace-indicator: Split out WorkspacePreviews
The previews will become a bit more complex soon, so spit them out
into a dedicated class.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/316>
2024-04-24 14:23:22 +00:00
Florian Müllner
a2ffb1238f workspace-indicator: Handle active indication in thumbnail
Meta.Workspace has had an `active` property for a while now, so
we can use a property binding instead of tracking the active
workspace ourselves.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/316>
2024-04-24 14:23:22 +00:00
Florian Müllner
b55e7a4dc8 workspace-indicator: Simplify scroll handling
gnome-shell already includes a method for switching workspaces
via scroll events. Use that instead of implementing our own.

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
01a37c8f26 export-zips: Pick up non-default stylesheets
The window-list extension is about to import the workspace-indicator
stylesheet. Explicitly pack css files, so the stylesheet is included
in the bundle.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/307>
2024-04-24 14:19:51 +00:00
Florian Müllner
5e88c7d891 workspace-indicator: Support light style
The window-list extension already includes light styling for
its copy of the workspace indicator. Just copy that over to
support the light variant here as well.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/307>
2024-04-24 14:19:51 +00:00
Florian Müllner
af23a8491c workspace-indicator: Tweak preview style
Sync sizes and padding with the window-list previews.

Tone down the colors a bit, but less then the current window-list
style where workspaces blend too much into the background and
the selection is unclear.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/307>
2024-04-24 14:19:51 +00:00
Florian Müllner
32a454f917 workspace-indicator: Include n-workspaces in status label
The two extensions currently use a slightly different label
in menu mode:
The workspace indicator uses the plain workspace number ("2"),
while the window list includes the number of workspaces ("2 / 4").

The additional information seem useful, as well as the slightly
bigger click/touch target, so copy the window-list behavior.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/307>
2024-04-24 14:19:51 +00:00
Florian Müllner
63ff5b2ac1 workspace-indicator: Simplify getting status text
Currently the same method is used to get the label text for the
indicator itself and for the menu items.

A method that behaves significantly different depending on whether
a parameter is passed is confusing, so only deal with the indicator
label and directly use the mutter API to get the workspace names
for menu items.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/307>
2024-04-24 14:19:51 +00:00
Florian Müllner
a9fff9861b workspace-indicator: Small cleanup
The code to update the menu labels is a bit cleaner in the
window-list extension, so use that.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/307>
2024-04-24 14:19:51 +00:00
Florian Müllner
89a3daf9fe workspace-indicator: Only change top bar redirect when in top bar
While this is always the case for the workspace indicator, adding
the check will allow to use the same code in the window list.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/307>
2024-04-24 14:19:51 +00:00
Florian Müllner
078a5a01ae workspace-indicator: Support showing tooltips above
The indicator is located in the top bar, so tooltips are always
shown below the previews. However supporting showing tooltips
above previews when space permits allows the same code to be
used in the copy that is included with the window-list extension.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/307>
2024-04-24 14:19:51 +00:00
Florian Müllner
9c8c3495b6 workspace-indicator: Don't use menu section
We never added anything else to the menu, so we can just operate
on the entire menu instead of an intermediate section.

This removes another difference with the window-list copy.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/307>
2024-04-24 14:19:51 +00:00
Florian Müllner
25e854dde8 workspace-indicator: Use existing property
We already track the current workspace index, use that
instead of getting it from the workspace manager again.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/307>
2024-04-24 14:19:51 +00:00
Florian Müllner
64060ef4c5 workspace-indicator: Don't use SCHEMA/KEY constants
Each constant is only used once, so all they do is disconnect
the actual value from the code that uses it.

The copy in the window-list extension just uses the strings directly,
do the same here.

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
e96015b9ea workspace-indicator: Allow overriding base style class
This will allow reusing the code from the window-list extension
without limiting the ability to specify styling that only applies
to one of the extensions.

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
00045b7396 workspace-indicator: Use descendant style selectors
Add a style class to the indicator itself, and only select
descendant elements. This allows using the briefer class names
from the window-list extension without too much risk of conflicts.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/307>
2024-04-24 14:19:51 +00:00
Florian Müllner
19877302a6 workspace-indicator: Move indicator code into separate file
Shortly after the window-list extension was added, it gained a
workspace switcher based on the workspace indicator extension.

Duplicating the code wasn't a big issue while the switcher was
a simple menu, but since it gained previews with a fair bit of
custom styling, syncing changes between the two extensions has
become tedious, in particular as the two copies have slightly
diverged over time.

In order to allow the two copies to converge again, the indicator
code needs to be separate from the extension boilerplate, so
split out the code into a separate module.

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
78c3957f64 Bump version to 46.1
Update NEWS.
46.1
2024-04-21 16:34:14 +02:00
Florian Müllner
38e267ae64 screenshot-window-sizer: Add additional size
1000x700 is the maximum recommended screenshot size on flathub[0]. As
that's a primary use case of the extension, it makes sense to include
the size.

[0] https://docs.flathub.org/docs/for-app-authors/metainfo-guidelines/quality-guidelines/#reasonable-window-size

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/317>
2024-04-20 14:33:40 +00:00
Fabio Tomat
59899a211d Update Friulian translation 2024-04-16 19:03:09 +00:00
Matheus Polkorny
d3348761c3 Update Brazilian Portuguese translation 2024-03-29 11:13:45 +00:00
Rachida SACI
79a01c62bc Update Kabyle translation 2024-03-23 09:11:17 +00:00
Florian Müllner
e65c561e6f Bump version to 46.0
Update NEWS.
46.0
2024-03-16 01:58:46 +01:00
Florian Müllner
6d36da1ce6 system-monitor: Fix net speed
We use different formats for values above and below 10, to only
include a fraction for the latter.

However we use the same factor to determine the format and to
compute the number to format, with the result that values above
10 are off by a factor of 10.

Address this by adding a separate "unitFactor" value for computing
the value.

Spotted by Yannick Daveluy.

Closes https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/issues/494

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/313>
2024-03-16 00:50:59 +00:00
Ask Hjorth Larsen
cd9341adf1 Update Danish translation 2024-03-13 17:11:10 +00:00
Changwoo Ryu
13842a012b Update Korean translation 2024-03-13 10:15:22 +00:00
Athmane MOKRAOUI
f4f7d2dffb Update Kabyle translation 2024-03-12 11:27:34 +00:00
Quentin PAGÈS
87a5fc42b8 Update Occitan translation 2024-03-12 09:12:03 +00:00
Milo Casagrande
f1456002d4 Update Italian translation 2024-03-08 13:39:43 +00:00
Aral Balkan
30266011bf screenshow-window-sizer: Document keyboard shortcuts
Close https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/issues/492

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/311>
2024-03-06 13:53:50 +01:00
Balázs Úr
5a76dedb50 Update Hungarian translation 2024-03-04 11:35:06 +00:00
Piotr Drąg
dc8ab6cf77 Update Polish translation 2024-03-03 19:05:37 +00:00
Anders Jonsson
b97efdb584 Update Swedish translation 2024-03-03 15:56:53 +00:00