Commit Graph

18394 Commits

Author SHA1 Message Date
Florian Müllner
198c7bbd9c extensions-app: Turn Extension into a GObject
This makes the Extension class usable as item-type in models,
and allows us to use property bindings.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3067>
2023-12-21 15:24:23 +00:00
Florian Müllner
f7ded3e509 extensions-app: Split out ExtensionManager
The extension handling is currently intertwined with the UI.

Splitting it out provides a clearer separation, and will allow
us to switch to a model-based UI later.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3067>
2023-12-21 15:24:23 +00:00
Florian Müllner
3d070fdc6b extensions-app: Move classes to their own files
Using a single source file is getting unwieldy, so start
splitting it up.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3067>
2023-12-21 15:24:23 +00:00
Florian Müllner
ee5b428232 extensions-app: Stop simulating Shell.global
ExtensionUtils no longer relies on the global object, so we don't
have to simulate it.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3067>
2023-12-21 15:24:23 +00:00
Florian Müllner
fa587b4b9e extensions-app: Use console for logging
This allows us to use different log levels, and an appropriate
log domain.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3067>
2023-12-21 15:24:23 +00:00
Julian Sparber
b66dee80f6 panel: Ensure signal is disconnected when the panel is destroyed
This fixes a warning when terminating GNOME Shell

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3064>
2023-12-21 15:17:28 +00:00
Florian Müllner
070e712508 extensionSystem: Add debug logging
Now that we can use console.debug() to log messages that aren't
shown by default, we can be a lot more verbose without spamming
the system log.

Use that to all extension state changes, which can be useful for
debugging.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3058>
2023-12-21 15:12:14 +00:00
Florian Müllner
f7c739ae4e extensions-app: Stop setting description tooltip
We no longer ellipsize the description label, so the tooltip
no longer has a purpose.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3051>
2023-12-21 15:06:11 +00:00
Florian Müllner
628e41890f extensions-app: Use details popover
Showing all the extension info and possible actions in every
row is fairly noisy, and doesn't match the usual list patterns.

Streamline the UI by moving the actions and most of the info into
a details popover, so the rows themselves get closer to the
standard pattern.

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

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3051>
2023-12-21 15:06:11 +00:00
Florian Müllner
82d3e55b68 extension-app: Remove tooltips from row suffixes
The updates/error icons are now interactive, and have more information
in the corresponding popover than could be covered
by a tooltip.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3051>
2023-12-21 15:06:11 +00:00
Florian Müllner
e252887731 extensions-app: Use less concise error strings
Now that the error information is displayed in a separate popover,
we can afford to be more verbose.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3051>
2023-12-21 15:06:11 +00:00
Florian Müllner
ed3394a953 extensions-app: Make error/update icon interactive
Both icons are not immediately obvious, and the context provided
by the tooltip can be hard to discover.

Address this by making the icons interactive, and provide further
information in a popover.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3051>
2023-12-21 15:06:11 +00:00
Florian Müllner
b2040b20c7 extensions-app: Set labelled-by relation for lists
We use our own lists so we can do filtering, but that means we
lose the built-in relation with the group's title.

Set the relation ourselves, so the two lists are described correctly
in screen readers.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3051>
2023-12-21 15:06:11 +00:00
Florian Müllner
a6d991b8f2 extensions-app: Update group headers
Change titles to the clearer "User/System Extensions" and drop the
description.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3051>
2023-12-21 15:06:11 +00:00
Florian Müllner
e064c2a785 extensions-app: Make kill switch more compact
Instead of using a subtitle, move the stability warning into an
information popover.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3051>
2023-12-21 15:06:11 +00:00
Florian Müllner
592ad186c6 extension-app: Use mnemonics in confirmation dialog
Mnemonics (aka "access keys") should be used whenever possible:

https://developer.gnome.org/hig/guidelines/keyboard.html#access-keys

They are currently missing from the confirmation dialog, add them.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3051>
2023-12-21 15:06:11 +00:00
Florian Müllner
05c4db4372 extensions-app: Add shortcuts window
There aren't many shortcuts and all of them are standard, but
documenting them is still good practice, and our main menu is
a tad bit less empty.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3051>
2023-12-21 15:06:11 +00:00
Florian Müllner
fdb7700535 extensions-app: Remove Help menu item
The app has been around for quite a while now, but there still
isn't any user documentation. Time to remove a menu item that
doesn't do anything.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3051>
2023-12-21 15:06:11 +00:00
Florian Müllner
3351cd2f07 panelMenu: Remove SystemIndicator class
It was used by components in the aggregate menu. That menu no
longer exists, and the class has been superseded by the class of
the same name in quick settings.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3068>
2023-12-21 13:35:50 +00:00
Sam Hewitt
b4c15d5a7b style: Fix missing light theme color definitions
- Closes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/7267

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3062>
2023-12-19 12:37:54 +00:00
Carlos Garnacho
71164a544f shell: Drop X11-specific code to handle stage focus
This code is being adopted by Mutter, so remove this handling
from ShellGlobal.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2950>
2023-12-18 16:23:04 +00:00
Florian Müllner
9c2da01a95 userWidget: Expand child
More fallout from commit c290a38730 …

Close https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/7264

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3061>
2023-12-16 23:57:48 +01:00
Sundeep Mediratta
3b4e3af6fa extensionSystem: Sort extensions before loading
When an extension is disabled, we "rebase" all extensions that
were enabled afterwards, in case they override the same method.

This can be fairly expensive, in particular when disabling many
extensions at once, for instance when locking the screen.

Help with that by sorting extensions by the number of session-modes,
as extensions that support multiple modes are less likely to be
disabled on session mode changes.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2851>
2023-12-16 17:33:47 +00:00
Florian Müllner
38d9026bc7 lookingGlass: Set expand of DebugFlags children
Since commit c290a38730, St.Bin respects the child's
expand properties instead of basing expansion on the
alignment.

Commit b02800f8 updated a number of callers to prepare for the
change, but the "Flags" tab in looking glass was missed.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3060>
2023-12-15 20:58:38 +01:00
Florian Müllner
c290a38730 st/bin: Delegate child allocation to layout manager
Since commit ed3b8d093e, the actor's single-child policy is
enforced even when using the generic add/remove_child() methods.

This makes it possible to follow GTK/AdwBin's lead and replace
out custom child allocation with a BinLayout, without changing
the actor's semantics in a fundamental way.

However this does change slightly how the child is allocated, as
it now only expands according to its expand properties, not when
the alignment is set to FILL.

Even after the preparations in the previous commit, some fallout
is still likely, but it will be easy to address, and the cleanup
is significant enough to justify it.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3046>
2023-12-15 14:45:38 +00:00
Florian Müllner
b02800f8b5 js: Explicitly set expand of St.Bin children
Right now, St.Bin ignores the child's expand properties, and
instead expands the child if its alignment is set to FILL.

This will change when we replace the custom allocation code
with a layout manager, so to prepare for that, set the expand
property where needed to keep the expected behavior.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3046>
2023-12-15 14:45:37 +00:00
Florian Müllner
ef2e96bb32 st/box-layout: Set layout manager type
Now that ClutterActor itself provides API to use a particular
layout manager type, we can use that instead of our own mechanism.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3046>
2023-12-15 14:45:37 +00:00
Florian Müllner
e746b038ef st/texture-cache: Drop bind_surface_property() method
It was only used for the fallback icon of X11 windows.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3056>
2023-12-15 14:10:53 +00:00
Florian Müllner
069a12b6d0 shell/app: Remove X11-specific icon fallback
We have considered .desktop files a required app component for
more than 10 years now. It also has been several years that the
default session switched to wayland, which doesn't have protocol
for window icons.

So stop using an elaborate fallback path just for legacy clients,
and just fall back to the same generic icon we use for wayland
clients.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3056>
2023-12-15 14:10:53 +00:00
Scott Buchanan
95daa577cf screenshot: Allow any enter key activate capture
We currently only consider enter/return on the main keyboard
area, but not on the numpad.

Fix that.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/6128

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2777>
2023-12-14 23:39:11 +01:00
Sam Hewitt
745667a825 style: Rewrote app grid tile drawing functions
- updated mixin for tile_button
- dropped the overview_button mixin
- minor changes to dash, appDisplay and switcherPopup JS to accommodate new stylesheet
- new focus style for all tile buttons
- improved high contrast style support for app grid and dash
- renamed some style-classes
- tidied up dash stylesheet

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3017>
2023-12-14 18:30:52 +00:00
Daniel van Vugt
76dfff1012 Pass 'radius' to blur APIs instead of 'sigma'
Requires mutter!1908 first.

So now consumers of the clutter blur code don't have to know the
implementation is Gaussian and no longer need to convert the intended
blur radius to a sigma value.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1905>
2023-12-14 18:20:59 +00:00
Florian Müllner
8c93d30531 docs: Fix st reference in urlmap
Whoops, no idea how that happened.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3055>
2023-12-14 18:12:22 +01:00
Florian Müllner
c0db83672e ci: Fix publishing docs
The originally merge request predates the switch to `main` as
the default branch name (by a mere week!).

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3054>
2023-12-14 17:53:38 +01:00
Cassidy James Blaede
a0a3bf8bf1 schema: Better describe always-show-log-out key
- The "user menu" was replaced with "system menu" years ago, so
  update the terminology in the summary and description
- Remove the full stop from the end of the summary for consistency
- More verbosely describe the behavior that's being overridden to
  reduce confusion

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3050>
2023-12-13 14:03:14 +00:00
Zander Brown
12eb7aa506 ci: Build docs in CI
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1873>
2023-12-13 14:52:48 +01:00
Zander Brown
4373a91911 doc: Switch documentation to gi-docgen
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1873>
2023-12-13 14:52:48 +01:00
Florian Müllner
ebe1a4d303 dbusService: Exempt org.gnome.Shell from sender tracking
If an interface has any signals, we don't want to auto-shutdown
while a caller is still connected to a signal.

Unfortunately we can't tell whether there are any signal connections,
so we track all callers instead, and keep the service alive while
any of them is still on the bus.

For services that we call from gnome-shell itself - like screencasts
or extensions - this has the unintended side effect of effectively
disabling auto-shutdown.

Address this by exempting the org.gnome.Shell name from sender
tracking.

Services that we expect to keep running for the lifetime of the
shell already disable auto-shutdown, so the only downside is a
small startup delay to resolve the well-known shell name.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/7250

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3052>
2023-12-13 01:27:51 +01:00
Automeris naranja
8bf52109b0 extensions-window: Add placeholder text to the search entry
"Text fields should have placeholder text or a label".

https://developer.gnome.org/hig/patterns/controls/text-fields.html

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2653>
2023-12-12 16:53:48 +00:00
Automeris naranja
ee5a26593e extensions-window: Add tooltips to headerbar buttons
"Controls in the header bars of primary windows should all have tooltips".

https://developer.gnome.org/hig/patterns/feedback/tooltips.html

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2653>
2023-12-12 16:53:48 +00:00
Automeris naranja
c925446723 extensions-window: Allow opening Main Menu with F10
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2653>
2023-12-12 16:53:48 +00:00
Florian Müllner
39d2988865 windowPreview: Don't hide overlay while hovering icon
We should treat the icon like we do the caption or close button,
and still consider the preview hovered when the pointer is over
the icon.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3049>
2023-12-11 15:10:59 +00:00
Florian Müllner
2d34fbe2e7 extensions-app: Use banner instead of action bar
Action bars have largely gone out of fashion, and Banner is an
appropriate replacement in our case, so switch to that.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3048>
2023-12-11 14:24:01 +00:00
Julian Sparber
33c074c738 st/scroll-view: Allow removing edge fade
Remove the fade effect when the css property `-st-vfade-offset` is removed
from a widget. The effect isn't added when the property never existed.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3047>
2023-12-07 18:15:51 +01:00
Sebastian Keller
9f7a7ed202 st/widget: Adjust to changes to get_transformed_paint_volume() in mutter
This method is now transfer full.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3045>
2023-12-06 14:19:12 +00:00
Sebastian Keller
dc931e82cd st/widget: Don't allow adding/removing "" style class
strstr() in find_class_name() will always consider "" a match so the
loop was not stopping at the end of the class_list. None of the matches
within the class_list would satisfy the return conditions, unless the
class_list was either an empty string as well or has a trailing space.
So this ends up with a match outside of the allocated string that
happens to satisfy these conditions by chance which then leads to the
class string containing some of this unrelated memory. Or it might lead
to a segfault.

This adds checks to the public API that uses find_class_name() to
prevent extensions from accidentally triggering a crash this way or
having some otherwise unexpected results.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/7152
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3006>
2023-12-05 23:31:40 +00:00
Florian Müllner
c8dae24645 st/bin: Fix height request
The request currently mixes up y-align and x-align.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3043>
2023-12-05 18:11:44 +01:00
Sam Hewitt
49c0b849c4 style: Improve text scaling support
- new drawing function to convert px to em, for select instances
- updated fontsize function to convert fonts in pt to em
- replace instances of discrete sizes with defined values
- fix instances where assets or icons did not scale along with text
- rework panel buttons to accommodate the scaling padding and icons
- new 'scalable' definitions for elements that follow text scaling

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3033>
2023-12-05 12:14:53 +00:00
Florian Müllner
bb78a0083a doc: Add README for toolbox tooling
Now that we have a collection of scripts around the toolbox
workflow, it makes sense to add a brief overview over the
available tools.

For now it's just located in the corresponding tools folder,
but it gives us something to point to once we overhaul the
toplevel documentation as part of the wiki migration.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3040>
2023-12-04 16:30:14 +00:00
Florian Müllner
7b5821251f tools: Remove outdated jhbuild setup script
As useful as the custom jhbuild setup was at the time, it has been
superseded by jhbuild proper (which gained the ability to install
system dependencies since) or alternatives like containers.

Given that the script hasn't been meaningfully updated for almost
10 years, its list of dependencies is hopelessly outdated, and it's
therefore more likely to confuse newcomers than being of actual
help.

As much as I have fond memories of the script when starting out,
it's finally time to retire.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3040>
2023-12-04 16:30:14 +00:00